title: Curly brackets in JSP code
body: <p>I have a JSP page I am working on and I am confused by some of the formatting/coding.</p>
  
  <p>There are sections where it's obvious what's going on:</p>
  
  <pre><code>&lt;%
          if (.....)
          {
  %&gt;
        &lt;input type=hidden name="blahblah" value="moreblah"&gt;
  &lt;%
          }
  %&gt;
  </code></pre>
  
  <p>But now I see sections where I have no idea how or why it works/compiles:</p>
  
  <pre><code>&lt;%
      {
          // do stuff here
          String sClass = "blahblah"
          if ( sClass.equals("") )
          {
              sClass = "blah";
          }
      }
  %&gt;
  </code></pre>
  
  <p>There's no if or while or for or anything at the start of those curly brackets. Why does that compile and produce a good jsp page?</p>