Explore Westonci.ca, the top Q&A platform where your questions are answered by professionals and enthusiasts alike. Connect with professionals on our platform to receive accurate answers to your questions quickly and efficiently. Connect with a community of professionals ready to help you find accurate solutions to your questions quickly and efficiently.

Suppose that a and b are integers with a < b How many numbers are in the list a, a+1, a+2.... b?

So I thought about doing a-(a-1) to get the first number to one so the list becomes 1,2,3 but i soon realized that does not work

Sagot :

The count of numbers in the list a, a+1, a+2.... b is b - a + 1

How to determine the count of numbers in the list a, a+1, a+2.... b?

The list of numbers is given as:

a, a+1, a+2.... b

From the above list, we can see that the numbers are consecutive numbers.

This means that, the count of numbers in the list is

Count = Highest - Least + 1

Where

Highest = b

Least = a

Substitute the known values in the above equation

Count = b - a + 1

Hence, the count of numbers in the list a, a+1, a+2.... b is b - a + 1

Read more about consecutive integers at:

https://brainly.com/question/10853762

#SPJ1