title: error: illegal start of type
body: <p>why this little piece of code is giving illegal start of type error in line 6 and 10(for loops).... i can't find any unmatched braces...</p>
  
  <pre><code>class StackDemo{
      final int size = 10;
      Stack s = new Stack(size);
  
      //Push charecters into the stack
      for(int i=0; i&lt;size; i++){
          s.push((char)'A'+i);
      }
      //pop the stack untill its empty
      for(int i=0; i&lt;size; i++){
          System.out.println("Pooped element "+i+" is "+ s.pop());
      }
  }
  </code></pre>
  
  <p>I have the class Stack implemented,</p>