chap 4 notes 38 - ) { int num= , sum= ; while...

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

View Full Document Right Arrow Icon
38 Another while Example num sum 3 6 Condition is still true, so the loop continues. #include <iostream> using namespace std; int main( void
Background image of page 1
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: ) { int num= , sum= ; while (sum&lt;= 20 ){ cout&lt;&lt; &quot;SUM= &quot; &lt;&lt; sum&lt;&lt; &quot;NUM= &quot; &lt;&lt; num&lt;&lt;endl&lt;&lt;endl; num++; sum+=num; } return ; }...
View Full Document

Ask a homework question - tutors are online