Hello Guys!

I am a programmer and I need some help! I need to know the following formula in order to add some Artificial Intelligence to some robots I am making, I need the following:

I have for example the numbers: 0,1,2,3,4,5,6,7,8,9

And I have 3 cases: case 1, case 2, case 3.

I need for example:

0 = case 1

1 = case 2

2 = case 3

3 = case 1

4 = case 2

5 = case 3

etc...

I apologize if this is not the correct forum to ask this question but I really have no idea where this should go.

Does anyone know any kind of formula for this?

Thanks a lot in advance!