Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- while(you havenโt gotten 1 in one of the containers yet){
- while(698 is not full){
- Fill 277 container
- Pour as much as possible into 698 container
- }
- When 698 becomes full, empty 698
- Pour the remaining amount in the 277 into the 698
- }
- The idea here is there will be some amount left in the 277 when the 698 gets full. Each iteration of the outer loop will change this value. After the small container is filled 63 times, and the large one is emptied 25 times, you will have 1 fl. oz left.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement