09-14-09

09-14-09 - Input User will supply 2 numbers, one at a time...

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

View Full Document Right Arrow Icon
Iteration, Repetition, Definite For Loop Description This simple program askes for 2 numbers from the user and computes the product of those numbers. It repeats this activity (loops) 3 times. It illustrates 4 new concepts: 1. for loops (definite loops) 2. using the loop index as a variable in the loop body
Background image of page 1
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: Input User will supply 2 numbers, one at a time when prompted. Output The program will print to the screen the product of the two numbers. It will also print the product multiplied by the loop index. Termination The program will end automatically after doing the activity 3 times....
View Full Document

This note was uploaded on 11/30/2009 for the course COMP 110 taught by Professor Stotts during the Spring '08 term at UNC.

Ask a homework question - tutors are online