0
$\begingroup$

The number of numbers between $1$ to $10^{10}$ which contain the digit $1$ is

what i try:we have to formed total number between $1$ to $10^{10}$ from $0,1,2,3,4,5,6,7,8,9$

$\bullet\; $ Single digit number which contain $1$ is $1$

$\bullet\; $ Double digit numbers which contain $1$ is $17$

But this is very lengthy ways

How do i solve it Help me please

$\endgroup$
1
  • 6
    $\begingroup$ Consider how many don't contain a $1$ instead, perhaps? And use leading zeros, because that is easier (think $0000000001$ rather than $1$). $\endgroup$
    – Arthur
    Commented Jan 22, 2020 at 8:58

1 Answer 1

2
$\begingroup$

Edited shorter answer : Any number with at most ten digits does not have $1$ as a digit, if and only if , when represented with leading zeros, it contains in ten possible blanks, any digit from $0 \to 9$ except $1$. Depending upon the number of leading zeros you would get the number of digits of course.

Therefore, that means that the answer is $10^{10} - 9^{10}$, realizing that $10^{10}$ contains a $1$ as a digit so does not count.

$\endgroup$
1
  • 2
    $\begingroup$ That seems a bit longwinded. Any number up to $10^{10}-1$ can be represented as a 10-digit number, if necessary with leading zeros. So the number without a 1 is just $9^{10}$. Subtract from $10^{10}$ and then think about whether the OP included $10^{10}$ itself. $\endgroup$
    – almagest
    Commented Jan 22, 2020 at 9:31

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .