I've recently installed Java SE 7 on my Ubuntu and tried to compile code with switch on string but couldn't do that. I compiled from command-line. Why?
java -version
java version "1.7.0"
Java(TM) SE Runtime Environment (build 1.7.0-b146)
Java HotSpot(TM) Server VM (build 21.0-b16, mixed mode)
incompatible types
found : java.lang.String
required: int
switch(attributes.getValue("tod")){
^
1 error