¡Hello , programmers and curious friends! This is my fourth program , created using Ubuntu bash and Atom. For this task , my classmates and I were instructed to create a program that asks for a range of integers and then prints the sum of the numbers in that range (inclusive).

For example, the sum from 6 to 10 would be 0 + 6 + 7 + 8 + 9 + 10.

I decided to use a loop to calculate the sum, because my programming teacher Ken Bauer, wanted us to practice repetitive work.

_______________________________________________________________

The resources that helped me were:
-How to think like a computer scientist.

-cpluplus.com

-Programming hub, mobile app.

I added some extra steps, because I wanted to show more information to the users , like:

-Both numbers are the same. Give me a correct range.

– The sum is also executed if the user writes the upper and lower bound in the wrong order.

WSQ04ATOM1

WSQ04ATOM2
Atom code.
WSQ04UBUNTU
Ubuntu commands.

WSQ04MASTERY

Until next time!

Advertisements