Next: Code blocks (II), Previous: Creating subclasses, Up: Tutorial
The Account/Saving/Checking example from the last chapter has several deficiencies. It has no record of the checks and their values. Worse, it allows you to write a check when there are no more checks—the Integer value for the number of checks will just calmly go negative! To fix these problems we will need to introduce more sophisticated control structures.
• Conditions: | Making some decisions | |
• Iteration: | Making some loops |