title: Java calling variable in another method
body: <p>I'm new to Java programming, I just have a easy question but I can't do it because I didnt know how to write it on Java. Thanks in Advance.</p>
  
  <p>I want to call variable values in another method.    </p>
  
  <pre><code>public static void ReadIN() throws Exception{
          BufferedReader br = new BufferedReader(new FileReader("test.txt"));
          String line = null;
  
          while ((line = br.readLine()) != null) {
            String[] values = line.split(","); // want to be call
            for (String inputIN : values) {
            inputIN = values[2];
            }
          }
  
  
          br.close(); 
        }
  
  
        public static void checkStatus() {
  
          // call variable 'values' here
  
        }
  </code></pre>