Hi kaustubhkohli12,Good instinct to ask where a number comes from - but in this case the
10 to
30 has nothing to do with the 5s. It comes straight from the question stem.
Read the stem again:
"For how many integers x from 10 to 30..." That range is the question's own restriction on x - the pool of candidates you are allowed to count, handed to you before you do any work at all. If the stem had said "from 1 to 100," the entire solution would run the same way, just on a bigger pool.
The two filters are doing different jobsThe 5s do something else entirely. Since x^2 - 3x - 4 factors as (x - 4)(x + 1), and
30 =
2 ×
3 ×
5, one of those two factors has to carry the
5. If x - 4 is a multiple of
5, then x =
4, 9, 14, 19, 24, 29, ...; if x + 1 is a multiple of
5, you land on that same list. Either way the condition reduces to one thing:
x is 4 more than a multiple of 5. And that list runs on forever.
Now the stem's range does its job: keep only the entries that sit between
10 and
30, and you are left with
14, 19, 24, 29. That is where those four candidates came from - the 5-condition supplies the pattern, the stem supplies the window.
What is left to checkTwo factors of
30 remain. The
2 is free: x - 4 and x + 1 always have opposite parity, so their product is always even. The
3 is not free: x must not be a multiple of
3, which knocks out
24.
That leaves
14,
19,
29 -
three values.
Answer: Bkaustubhkohli12
Why between 10 and 30, because we are looking for multiples of 5 ?