CS计算机代考程序代写 Asynchronous Practice Activities

Asynchronous Practice Activities

Task 1

Part 1:

Develop a program that prompts the user to 5 numbers

Your program should output the sum of the 5 numbers;

Part 2:

Modify your program to allow the user to enter as many numbers as they want

Your program should output the sum of all the numbers

When asking users for a number, you must use a do-while loop

Part 3:

Repeat Part 2, but use a while loop when asking for input

Part 4:

Modify the program in part 1 to output:

The average of all numbers ( sum of numbers / total numbers )

The product of all numbers (multiply all numbers and output result )

Task 2

Develop a program that will prompt the user to 6 numbers and then print the number of positive numbers and the sum of negative numbers in the set.

For example, if user enters: