Java Reference
In-Depth Information
disappear. It's important to note already that the proposed solution will not always be the correct one,
so be careful that you read and understand both the error and the solution before applying it.
figure 6-3  
Following this approach, you can resolve all of the syntax errors in this code.
Line 3: Rename type to Errors (class name must match .java filename).
Line 5: Change to void ( main method return type is always void ).
Line 9: Change the comma to a semicolon.
Line 10: Change the for loop to for (int i = age; i <= 65; i++) .
figure 6-4  
Search WWH ::




Custom Search