Operator problems with "switch()"

Hey all.

I will be direct this time.

How do I use relative operators in switch? You probably didn't get what I mean, so I will show a code example:

1
2
3
4
5
6
switch(number){
case %2 = 0:
    //do something and break
case %3 = 0:
    //do something and break
case %4 = 0:


What I wanted to do here is to do an action if the modulus(remainder) of the division of day per 2, or 3, or 4 is 0.

However, it always show I compiler error. How I do that with switch?
Last edited on
switch can't be used for this. Use an if-else cascade instead.
Last edited on
Topic archived. No new replies allowed.