Question: Write a C++ program that allows the user to input an integer value n and prints the sum of the five consecutive integers starting with

 Write a C++ program that allows the user to input an

Write a C++ program that allows the user to input an integer value n and prints the sum of the five consecutive integers starting with n. For example if the user enters 2 then the program prints the sum = 20 since 2 + 3 + 4 + 5 + 6 = 20. Enter the first integer value: 2 The sum is: 20

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!