Uno2 case statement


Jack Fenton
 
Edited

The Uno2 manual shows this format for the switch/case statement

switch(&variable)
{
case "a":
     .. do stuff
     break
case "b":
      .. do stuff
      break
default:
}

I'm waiting for my Uno chip and starting to program with the editor until it arrives.

If I use the above format, the editor  gives me an error however if I use "$" instead of "&" before variable it no longer complains. Is the manual incorrect? 

Join uno@fcb1010.groups.io to automatically receive all group messages.