Boolean not inheriting : <p>I created a boolean method in a super class, but when I call on that method to use it in the sub class, it is giving me a type mismatch error saying it can't convert a boolean to A. I'm probably missing something minor, but is there another way to use the method in an inherited class? </p>

<pre><code>public class A{
    public boolean Proper(String expression){
    //body of method that determines if an expression is proper
    return true;
    }
}



public class B extends A {

    static BalancedExpressions Proper = new BalancedExpressions();

    public static void main(String[] args) {
                try {
                Scanner scanner = new Scanner(new File("src/Expressions.txt"));
                FileWriter output = new FileWriter(new File("Output.txt"));

                while (scanner.hasNextLine()) {
                    String nextLine = scanner.nextLine();

                    output.write(nextLine + "\t");

                    //following line is giving the error
                    if(Proper = true) {
                    output.write("proper" + "\n");
                    } else { 
                    output.write("improper" + "\n");
                }
                scanner.close();
                output.close();
                    }
            } 
            catch (FileNotFoundException e) {
                e.printStackTrace();
            }


        }//end main

    }
</code></pre>
