False max 10 true false wear parka wear shirt display

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview:  Why does this loop stop?   As we increase count, it eventually becomes larger than N •  At that point, the Boolean expression count <= N becomes False 8 While loops work for any repe$$ve task • Example: recommend what to wear for as long as the user wants: Start Start TRUE Ask for Forecast want a suggestion? FALSE Max < -10? TRUE FALSE Wear Parka Wear Shirt Display result procedure or sub-routine recommend what to wear Stop Stop 9 3 13 ­09 ­19 While loops work for any repe$$ve task Start TRUE want a suggestion? FALSE recommend what to wear Stop 10 Finding the maximum of several values...
View Full Document

This document was uploaded on 03/02/2014.

Ask a homework question - tutors are online