Now, if you are checking the same variable for more than one possible expression, then it yields a greater optimization to do this:
You just have to make sure that you take care of the 0 case first, since this will return a non-zero value if the variable=0
Shouldn't that first one be
Anyways, great guide. I'm definitely printing this out when I can.