The variable j is local to the "if" block and hence is not visible outside it.
Hence when we try to use it later while printing, the compiler reports that it is unable to find the symbol j.
C:\java_practice\src\Scope2.java:12: error: cannot find symbol
System.out.println("i="+i+" , j="+ j);
symbol: variable j
location: class Scope2