Different between declaring static variable before or after static block in java
<p><strong>The code 1:</strong>      </p>

<pre><code>       public class StaticBlockExample1
      {
        static {  value = 20;  }

        static int value = 10;
        public static void main(String[] args) {

              System.out.println(" Value = " + value);
        }
    }
</code></pre>

<p>output of StaticBlockExample1 is 10</p>

<p><strong>The code 2:</strong> </p>

<pre><code>  public class StaticBlockExample2 
      {
        static int value = 10;
        static {    value = 20;     }   

        public static void main(String[] args)
           {
            System.out.println(" Value = " + value);
           }
      }
</code></pre>

<p>output of StaticBlockExample2 is 20.</p>

<p>Am confused with outputs of the above examples. is there any significance to declare static variable before or after static block?</p>
