Question: (Programming language is C) I need to build a program that prompts user to input as many integers as they want (with a maximum of

(Programming language is C) I need to build a program that prompts user to input as many integers as they want (with a maximum of 30). Every integer should be stored in an array. When the user enters any number less than or equal to zero, the input should stop.

I'm not sure whether to use a for loop or a while loop, and how exactly to break out of it if either the user reaches the limit of 30 integers entered or if the user enters a negative number.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!