title: Non-static method cannot be referenced from a static context error
body: <p>i have class named sagum which has a method name paint</p>
  
  <pre><code>public void paint(Graphics g) {
  
      int[] apw1 = null;
      int n1 = 0;
      for (int j = 1; j &lt;= n1; j++) {
          g.drawRect(50, 50, (apw1[j] * 20), 30);
          String[] p = null;
          g.drawString("p" + p[j - 1], (55 + (apw1[j - 1] * 20)), 70);
          g.drawString("" + apw1[j - 1], 50 + (apw1[j - 1] * 20), 100);
      }
      g.drawString("" + apw1[n1], 50 + (apw1[n1] * 20), 100);
  
  }
  </code></pre>
  
  <p>im trying to call it </p>
  
  <pre><code>n1=count+1; 
  paint(g);
  </code></pre>
  
  <p>and im getting an error</p>
  
  <pre><code>non-static method paint(Graphics) cannot be referenced from a static context
  </code></pre>
  
  <p>im simply trying to call it after a method is executed to do an a graphical app of my method (scheduling algorithm). </p>
  
  <p>please help</p>