Pages

Monday, 27 March 2017

Core Java Assignment 25

Core Java Assignment 25


A10.1-R4: INTRODUCTION TO OBJECT ORIENTED PROGRAMMING THROUGH JAVA.

Assignment 25


Some combined bath-showers have two faucets and a lever for controlling the flow of the
water. The lever controls whether the water flows from the showerhead or directly into the
tub. When the water is first turned on, it flows directly into the tub. When the lever is pulled,
a valve closes and latches, diverting the flow of water to the showerhead. To switch from
shower to bath with the water running, one must push the lever. Shutting off the water
releases the lever so that the next time the water is turned on, it flows directly into the tub.
Write a scenario for a shower that is interrupted by a telephone call.


No comments:

Post a Comment