Originally posted by vinod balaji:
There wont be error in line 2, because since i is in static block(it means that declaration part is there somewhere).
Originally posted by Sanjeev Kulkarni:
In the above case, you are calling peek() before 'j' is set to 1, that means, j = 0 when you call: