Why does it gives normal output?Why it does not complain abt tmp not intialized?
class Demo{
String msg="Type is";
public static void main (String args[]){
Demo d =new Demo();
d.showType(1);
}
public void showType(int n){
String tmp;
if (n<0) tmp="positive" ;else tmp="not positive";
System.out.println(msg+tmp);
}
}