jwang1191
Yeah
In your example:
The first number divisible by 3 in your set would be -39 and the last would be 99
step 1: subtract largest divisible number in set by the smallest: 99 - (-39) = 138
step 2: divide the difference by the divisible number: 138 / 3 = 46
step 3: add 1: 46 + 1 = 47 total numbers between 99 and -39 that are divisible by 3
This is easy to see with small numbers
For example:
set = from 7 to 21, we need to find number of numbers divisible by 7
21- 7 = 14
14 / 7 = 2
2 + 1 = 3
Yeah its called sequence & series :
Lets say u need to know how many numbers are there between 40 to 100 that are multiple of 3.
So start with first multiple of 3 after 40. In this case it is 42
and the last multiple of 3 before 100. Its 99.
So the formula is
nth term = first term + (n-1)*d
where d is the difference between each of the consecutive numbers. In this case it is 3
n= number of terms (which is what you are looking for)
So using above formula :
nth term is 99
first term is 42
and d is 3
So 99 = 42 + (n-1)*3
57 = (n-1)*3
n-1 = 19
n = 20
You can cross check by any other method ..
This topic is called Sequence and series which we (Indians) study in 11th grade maths...
Hit kudos if this helps!!!