1
$\begingroup$

Question: In how many ways we can select two numbers between $1$ and $100$ so that the two selected numbers have a difference of at most $10$.

My Approach: I calculated the answer to be $925$ but I am not really sure if it is the correct answer.

This how I approached it, As the question says "between" so it means numbers ranging from $2$ to $99$, so $(2,3), (2,4), (2,5), (2,6),\dots,(2,12)$ so $10$ ways like this proceeding similarly till $(89,99)$ we will get $880$ numbers. From here onwards, $(90,99)$—$9$ ways; $(91,99)$ &mdash $8$ ways; … $(98,99)$ — $1$ way, so $45$ ways like this. Adding up all: $880+45 = 925$ ways in all

Can someone please help me with this question? Thanks in advance.

$\endgroup$
  • $\begingroup$ What help do you need? You have solved it correctly. I might have recognized the triangular number at the top end more quickly than you express in your post, but that is the only simplification that I see. $\endgroup$ – Ross Millikan Nov 1 '13 at 4:24
  • $\begingroup$ I am not really sure about the answer, hence I wanted to ask the community if it is right or wrong, if it is wrong then how to proceed correctly. $\endgroup$ – Walter White Nov 1 '13 at 4:28
  • 1
    $\begingroup$ Between $1$ and $100$ is more likely to be intended as including the endpoints. $\endgroup$ – André Nicolas Nov 1 '13 at 4:36
  • $\begingroup$ I agree with Andre' Nicolas. However, if the problem does exclude the endpoints, then you have a nice solution. Well done! :) $\endgroup$ – 1233dfv Nov 1 '13 at 4:41
  • $\begingroup$ Is "between 1 to 100" the exact wording of the question? The normal English expression is "between 1 and 100". $\endgroup$ – bof Nov 1 '13 at 4:42
1
$\begingroup$

90*10+10C2=945

explanation: let the smaller number is chosen from 1 to 90 any number. if the chosen number is n then another number can be any number from (n+1) to (n+10). the number of pair is 90*10 if the smaller number belongs to 1 from 90. then if if the samller number is greater than 90 then number of pair is 10C2=45

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.