Variable not working as desired

What do you think the result should be instead, and why? Please try to trace through your logic carefully, step by step.

Where the code says alto += alto, what effect do you expect this to have, and why? If alto was 0 before that line, what would it be after?

Please read the pinned thread to understand how to post code properly.