Whats wrong-Towers of Hanoi
<p>can some explain to me why this code wont work when i deploy it on the android emulator</p>

<pre><code>public class towers extends Activity {

    /** Called when the activity is first created. */
    private EditText text;
    @Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.main);
        text = (EditText) findViewById(R.id.editText1);   
    }

    static int moves = 0;
    static int totalDisks = 0;

    public void myClickHandler(View view) throws java.io.IOException {
        char fromPole = 'A';
        char withPole = 'B';
        char toPole = 'C';

        switch (view.getId()) {
            case R.id.editText1:

                if (text.getText().length() == 0) {
                    Toast.makeText(this, "Please enter number of disks",
                            Toast.LENGTH_LONG).show();
                    return;
                }
                float disks = Float.parseFloat(text.getText().toString());
                FileOutputStream fos = new FileOutputStream("TowersOfHanoiSolution.txt");
                PrintStream ps = new PrintStream(fos);
                solveHanoi(disks, fromPole, toPole, withPole, ps);
                ps.close();
                System.out.println();
                text.setText("\nAmount of moves: " + moves + "\n");
        }

    }

    static void solveHanoi(float disks, char start, char end, char intermediate, PrintStream ps) {
        if (disks &gt;= 1) {
            solveHanoi(disks-1, start, intermediate, end, ps);
            moveDisk(start, end, ps);
            solveHanoi(disks-1, intermediate, end, start, ps);
        }
    }

    static void moveDisk(char fromPole, char toPole, PrintStream ps) {
        moves++;

        if(totalDisks &lt;= 10){
            System.out.print("Move from " + fromPole + " to " + toPole + ". ");
            ps.print("Move from " + fromPole + " to " + toPole + ". ");
            if (moves%4 == 0){
                System.out.println();
                ps.println();
            }
        }
        else {
            ps.print("Move from " + fromPole + " to " + toPole + ". ");
            if (moves%4 == 0){
                ps.println();
            }
        }
    }
}
</code></pre>
