OBJECTIVE: To give practice writing C program that implements the repetition structures.
TASK
Draw a flowchart and write a program that asks user to enter twenty integers and display the sum of these integers. The solution must be provided in three different structures (for, while, do-while).
| |
Flowchart A - Condition is tested before proceed to body of loop |
 |
Code A -Follows a logic of Flowchart A |
 |
Flowchart B - the condition is at the bottom of loop |
 |
Code B -Follows a logic of Flowchart B |
*Please complete the flowchart and a program for a "for structure".
No comments:
Post a Comment