Difference between revisions of "2007 AMC 12A Problems/Problem 22"

m (Solution 2: (blank edit) 2nd solution by Jacob Steinhardt)
m (dup.)
Line 1: Line 1:
 +
{{duplicate|[[2007 AMC 12A Problems|2007 AMC 12A #22]] and [[2007 AMC 10A Problems/Problem 25|2007 AMC 10A #25]]}}
 
== Problem ==
 
== Problem ==
For each positive integer <math>n</math>, let <math>S(n)</math> denote the sum of the digits of <math>n.</math> For how many values of <math>n</math> is <math>\displaystyle n + S(n) + S(S(n)) = 2007?</math>  
+
For each positive integer <math>n</math>, let <math>S(n)</math> denote the sum of the digits of <math>n.</math> For how many values of <math>n</math> is <math>n + S(n) + S(S(n)) = 2007?</math>  
 
 
 
<math>\mathrm{(A)}\ 1 \qquad \mathrm{(B)}\ 2 \qquad \mathrm{(C)}\ 3 \qquad \mathrm{(D)}\ 4 \qquad \mathrm{(E)}\ 5</math>
 
<math>\mathrm{(A)}\ 1 \qquad \mathrm{(B)}\ 2 \qquad \mathrm{(C)}\ 3 \qquad \mathrm{(D)}\ 4 \qquad \mathrm{(E)}\ 5</math>
Line 7: Line 8:
 
== Solution ==
 
== Solution ==
 
=== Solution 1 ===
 
=== Solution 1 ===
For the sake of notation let <math>T(n) = n + S(n) + S(S(n))</math>. Obviously <math>n<2007</math>. Then the maximum value of <math>\displaystyle S(n) + S(S(n))</math> is when <math>n = 1999</math>, and the sum becomes <math>28 + 10 = 38</math>. So the minimum bound is <math>1969</math>. We do [[casework]] upon the tens digit:
+
For the sake of notation let <math>T(n) = n + S(n) + S(S(n))</math>. Obviously <math>n<2007</math>. Then the maximum value of <math>S(n) + S(S(n))</math> is when <math>n = 1999</math>, and the sum becomes <math>28 + 10 = 38</math>. So the minimum bound is <math>1969</math>. We do [[casework]] upon the tens digit:
  
 
Case 1: <math>196u \Longrightarrow u = 9</math>. Easy to directly disprove.
 
Case 1: <math>196u \Longrightarrow u = 9</math>. Easy to directly disprove.
  
Case 2: <math>197u</math>. <math>S(n) = 1 + 9 + 7 + u = 17 + u</math>, and <math>S(S(n)) = 8+u</math> if <math>u \le 2</math> and <math>\displaystyle S(S(n)) = 2 + (u-3) = u-1</math> otherwise.  
+
Case 2: <math>197u</math>. <math>S(n) = 1 + 9 + 7 + u = 17 + u</math>, and <math>S(S(n)) = 8+u</math> if <math>u \le 2</math> and <math>S(S(n)) = 2 + (u-3) = u-1</math> otherwise.  
  
 
:Subcase a: <math>T(n) = 1970 + u + 17 + u + 8 + u = 1995 + 3u = 2007 \Longrightarrow u = 4</math>. This exceeds our bounds, so no solution here.
 
:Subcase a: <math>T(n) = 1970 + u + 17 + u + 8 + u = 1995 + 3u = 2007 \Longrightarrow u = 4</math>. This exceeds our bounds, so no solution here.
:Subcase b: <math>\displaystyle T(n) = 1970 + u + 17 + u + u - 1 = 1986 + 3u = 2007 \Longrightarrow \displaystyle  u = 7</math>. First solution.
+
:Subcase b: <math>T(n) = 1970 + u + 17 + u + u - 1 = 1986 + 3u = 2007 \Longrightarrow u = 7</math>. First solution.
  
Case 3: <math>198u</math>. <math>S(n) = 18 + u</math>, and <math>S(S(n)) = 9 + u</math> if <math>u \le 1</math> and <math>\displaystyle 2 + (u-2) = u</math> otherwise.
+
Case 3: <math>198u</math>. <math>S(n) = 18 + u</math>, and <math>S(S(n)) = 9 + u</math> if <math>u \le 1</math> and <math>2 + (u-2) = u</math> otherwise.
  
:Subcase a: <math>\displaystyle T(n) = 1980 + u + 18 + u + 9 + u = 2007 + 3u = 2007 \Longrightarrow u = 0</math>. Second solution.
+
:Subcase a: <math>T(n) = 1980 + u + 18 + u + 9 + u = 2007 + 3u = 2007 \Longrightarrow u = 0</math>. Second solution.
 
:Subcase b: <math>T(n) = 1980 + u + 18 + u + u = 1998 + 3u = 2007 \Longrightarrow u = 3</math>. Third solution.  
 
:Subcase b: <math>T(n) = 1980 + u + 18 + u + u = 1998 + 3u = 2007 \Longrightarrow u = 3</math>. Third solution.  
  
Case 4: <math>199u</math>. But <math>S(n) > 19</math>, and the these clearly sum to <math>\displaystyle > 2007</math>.
+
Case 4: <math>199u</math>. But <math>S(n) > 19</math>, and the these clearly sum to <math>> 2007</math>.
  
Case 5: <math>200u</math>. So <math>S(n) = 2 + u</math> and <math>S(S(n)) = 2 + u</math>, and <math>\displaystyle 2000 + u + 2 + u + 2 + u = 2004 + 3u = 2007 \Longrightarrow u = 1</math>. Fourth solution.
+
Case 5: <math>200u</math>. So <math>S(n) = 2 + u</math> and <math>S(S(n)) = 2 + u</math>, and <math>2000 + u + 2 + u + 2 + u = 2004 + 3u = 2007 \Longrightarrow u = 1</math>. Fourth solution.
  
 
In total we have <math>4 \mathrm{(D)}</math> solutions, which are <math>1977, 1980, 1983, </math> and <math>2001</math>.
 
In total we have <math>4 \mathrm{(D)}</math> solutions, which are <math>1977, 1980, 1983, </math> and <math>2001</math>.
Line 32: Line 33:
 
Case 1: <math>n \geq 2000</math>
 
Case 1: <math>n \geq 2000</math>
  
:Inspection gives <math>\displaystyle n = 2001</math>.
+
:Inspection gives <math>n = 2001</math>.
  
Case 2: <math>\displaystyle n < 2000 \displaystyle </math>, <math>n = 19xy</math>, <math>x + y < 10 </math>
+
Case 2: <math>n < 2000</math>, <math>n = 19xy</math>, <math>x + y < 10 </math>
  
 
:If you set up an equation, it reduces to
 
:If you set up an equation, it reduces to
Line 42: Line 43:
 
:which has as its only solution satisfying the constraints <math>x = 8</math>, <math>y = 0</math>.
 
:which has as its only solution satisfying the constraints <math>x = 8</math>, <math>y = 0</math>.
  
Case 3: <math>\displaystyle n < 2000 \displaystyle</math>, <math>n = 19xy</math>, <math>x + y \geq 10</math>
+
Case 3: <math>n < 2000</math>, <math>n = 19xy</math>, <math>x + y \geq 10</math>
  
 
:This reduces to
 
:This reduces to
  
:<math>\displaystyle4x + y = 35</math>. The only two solutions satisfying the constraints for this equation are <math>x = 7</math>, <math>y = 7</math> and <math>x = 8</math>, <math>y = 3</math>.  
+
:<math>4x + y = 35</math>. The only two solutions satisfying the constraints for this equation are <math>x = 7</math>, <math>y = 7</math> and <math>x = 8</math>, <math>y = 3</math>.  
  
 
The solutions are thus <math>1977, 1980, 1983, 2001</math> and the answer is <math>\mathrm{(D)}\  4</math>.
 
The solutions are thus <math>1977, 1980, 1983, 2001</math> and the answer is <math>\mathrm{(D)}\  4</math>.

Revision as of 17:55, 5 January 2008

The following problem is from both the 2007 AMC 12A #22 and 2007 AMC 10A #25, so both problems redirect to this page.

Problem

For each positive integer $n$, let $S(n)$ denote the sum of the digits of $n.$ For how many values of $n$ is $n + S(n) + S(S(n)) = 2007?$

$\mathrm{(A)}\ 1 \qquad \mathrm{(B)}\ 2 \qquad \mathrm{(C)}\ 3 \qquad \mathrm{(D)}\ 4 \qquad \mathrm{(E)}\ 5$

Solution

Solution 1

For the sake of notation let $T(n) = n + S(n) + S(S(n))$. Obviously $n<2007$. Then the maximum value of $S(n) + S(S(n))$ is when $n = 1999$, and the sum becomes $28 + 10 = 38$. So the minimum bound is $1969$. We do casework upon the tens digit:

Case 1: $196u \Longrightarrow u = 9$. Easy to directly disprove.

Case 2: $197u$. $S(n) = 1 + 9 + 7 + u = 17 + u$, and $S(S(n)) = 8+u$ if $u \le 2$ and $S(S(n)) = 2 + (u-3) = u-1$ otherwise.

Subcase a: $T(n) = 1970 + u + 17 + u + 8 + u = 1995 + 3u = 2007 \Longrightarrow u = 4$. This exceeds our bounds, so no solution here.
Subcase b: $T(n) = 1970 + u + 17 + u + u - 1 = 1986 + 3u = 2007 \Longrightarrow u = 7$. First solution.

Case 3: $198u$. $S(n) = 18 + u$, and $S(S(n)) = 9 + u$ if $u \le 1$ and $2 + (u-2) = u$ otherwise.

Subcase a: $T(n) = 1980 + u + 18 + u + 9 + u = 2007 + 3u = 2007 \Longrightarrow u = 0$. Second solution.
Subcase b: $T(n) = 1980 + u + 18 + u + u = 1998 + 3u = 2007 \Longrightarrow u = 3$. Third solution.

Case 4: $199u$. But $S(n) > 19$, and the these clearly sum to $> 2007$.

Case 5: $200u$. So $S(n) = 2 + u$ and $S(S(n)) = 2 + u$, and $2000 + u + 2 + u + 2 + u = 2004 + 3u = 2007 \Longrightarrow u = 1$. Fourth solution.

In total we have $4 \mathrm{(D)}$ solutions, which are $1977, 1980, 1983,$ and $2001$.

Solution 2

Clearly, $n > 1900$. We can break this up into three cases:

Case 1: $n \geq 2000$

Inspection gives $n = 2001$.

Case 2: $n < 2000$, $n = 19xy$, $x + y < 10$

If you set up an equation, it reduces to

$4x + y = 32$

which has as its only solution satisfying the constraints $x = 8$, $y = 0$.

Case 3: $n < 2000$, $n = 19xy$, $x + y \geq 10$

This reduces to
$4x + y = 35$. The only two solutions satisfying the constraints for this equation are $x = 7$, $y = 7$ and $x = 8$, $y = 3$.

The solutions are thus $1977, 1980, 1983, 2001$ and the answer is $\mathrm{(D)}\  4$.

See also

2007 AMC 12A (ProblemsAnswer KeyResources)
Preceded by
Problem 21
Followed by
Problem 23
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25
All AMC 12 Problems and Solutions