The volatile modifier applies only to instance variables.
The volatile modifier tells the JVM that a thread accessing the variable must always reconcile
its own private copy of the variable with the master copy in memory.
The volatile variables might be modified asynchronously
publicclass MainClass{
volatileint i=0;
publicstaticvoid main(String[] argv){
System.out.println();
}
}