Help with the correct parameters to Math.tan
<pre><code>import java.util.Scanner;

public class a {

    /**
    * @param args
    */
    public static void main(String[] args) {
        // TODO Auto-generated method stub

        Scanner in = new Scanner(System.in);
        System.out.println("enter #");
        long a = in.nextLong();

        long b = (long) Math.toRadians(a);
        long c = (long) Math.tan(b);

        System.out.println(c);

    }
}
</code></pre>

<p>Above is my attempt to make Math.tan spit out the correct values of an angle in degrees. I know the method math.tan accepts only angles in radians as a parameter. I can't get correct value for angles of 90, 270... Using a double doesn't yield correct answers.</p>
