title: non static/ static variable error
body: <p>I am making a program that can take judge scores and give an average and one of my variables I think I did wrong.  I get the error message:</p>
  
  <blockquote>
    <p>non-static variable difficulty cannot be referenced from a static context<br>
    difficulty = keyboard.nextDouble;</p>
  </blockquote>
  
  <p>I have tried moving it above the main method as well as also adding "static" to it but it still seems to give me problems.  Is there something else that I can do?  Here is part of the code for it</p>
  
  <pre><code>import java.util.Scanner;
  public class CH6PA
  {
  private double difficulty;
  private int score;
  private double[] average;
  
  public static void main(String[]args)
  {
      Scanner keyboard = new Scanner (System.in);
  
      do
      {
          System.out.println("Enter the level of difficulty (1.2-3.8)");
      difficulty = keyboard.nextDouble;
      }
          while (difficulty&gt;1.2 || difficulty&lt;3.8);
  
  
      int judge = new int[7];
  
  
      for(int i = 0; i&lt;judge.length; i++)
      {
  </code></pre>