Wednesday, April 1, 2020

how to denote if condition that -4,-3,-2,-1,1,2,3,4

I have a variable called week. Its value is integers, and I need to make an if condition that week = -4,-3,-2,-1,1,2,3,4
if ((week >= -4 & week < 0) | (week >0 & week <= 4))
Do you have a better method?

No comments:

Post a Comment