java - cannot find symbol
<p>If i have this in my main method: <code>PrintWriter output = new PrintWriter(new FileWriter(args[1]));</code></p>

<p>and this in another method: <code>output.println(currentLine);</code></p>

<p>and <code>import java.io.*;</code> obviously,</p>

<p>does anyone know why I am getting</p>

<pre><code>cannot find symbol
symbol  : variable output
location: class TestClass
        output.println(currentLine);
</code></pre>
