Skip to content
Prev 105917 / 398506 Next

Switch and integer

David Barron schrieb:
Thank you, I wondered about the
and the example from the help file for(i in c(-1:3,9))  print(switch(i,
1,2,3,4))
No see I  that the 1,2,3,4 is the output not the value, but it's not
very clear for me ho it works.
I will try to find it out ...
The switch for Integer is very different from C++ or Pascal .. maybe
this was the reason for the problem.

Regards Knut