diff --git a/HarvardMIT/md/en-102-2007-feb-alg-solutions.md b/HarvardMIT/md/en-102-2007-feb-alg-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..6768d5c79274426d80d4a179a263de24691812ed
--- /dev/null
+++ b/HarvardMIT/md/en-102-2007-feb-alg-solutions.md
@@ -0,0 +1,120 @@
+# $10^{\text {th }}$ Annual Harvard-MIT Mathematics Tournament
Saturday 24 February 2007
+
+## Individual Round: Algebra Test
+
+1. [3] Compute
+
+$$
+\left\lfloor\frac{2007!+2004!}{2006!+2005!}\right\rfloor
+$$
+
+(Note that $\lfloor x\rfloor$ denotes the greatest integer less than or equal to $x$.)
+Answer: 2006. We have
+
+$$
+\left\lfloor\frac{2007!+2004!}{2006!+2005!}\right\rfloor=\left\lfloor\frac{\left(2007 \cdot 2006+\frac{1}{2005}\right) \cdot 2005!}{(2006+1) \cdot 2005!}\right\rfloor=\left\lfloor\frac{2007 \cdot 2006+\frac{1}{2005}}{2007}\right\rfloor=\left\lfloor 2006+\frac{1}{2005 \cdot 2007}\right\rfloor
+$$
+
+2. [3] Two reals $x$ and $y$ are such that $x-y=4$ and $x^{3}-y^{3}=28$. Compute $x y$.
+
+Answer: $-\mathbf{3}$. We have $28=x^{3}-y^{3}=(x-y)\left(x^{2}+x y+y^{2}\right)=(x-y)\left((x-y)^{2}+3 x y\right)=4 \cdot(16+3 x y)$, from which $x y=-3$.
+3. [4] Three real numbers $x, y$, and $z$ are such that $(x+4) / 2=(y+9) /(z-3)=(x+5) /(z-5)$. Determine the value of $x / y$.
+Answer: 1/2. Because the first and third fractions are equal, adding their numerators and denominators produces another fraction equal to the others: $((x+4)+(x+5)) /(2+(z-5))=(2 x+9) /(z-3)$. Then $y+9=2 x+9$, etc.
+4. [4] Compute
+
+$$
+\frac{2^{3}-1}{2^{3}+1} \cdot \frac{3^{3}-1}{3^{3}+1} \cdot \frac{4^{3}-1}{4^{3}+1} \cdot \frac{5^{3}-1}{5^{3}+1} \cdot \frac{6^{3}-1}{6^{3}+1}
+$$
+
+Answer: $\frac{\mathbf{4 3} \text {. }}{63}$ Use the factorizations $n^{3}-1=(n-1)\left(n^{2}+n+1\right)$ and $n^{3}+1=(n+1)\left(n^{2}-n+1\right)$ to write
+
+$$
+\frac{1 \cdot 7}{3 \cdot 3} \cdot \frac{2 \cdot 13}{4 \cdot 7} \cdot \frac{3 \cdot 21}{5 \cdot 13} \cdot \frac{4 \cdot 31}{6 \cdot 21} \cdot \frac{5 \cdot 43}{7 \cdot 31}=\frac{1 \cdot 2 \cdot 43}{3 \cdot 6 \cdot 7}=\frac{43}{63}
+$$
+
+5. [5] A convex quadrilateral is determined by the points of intersection of the curves $x^{4}+y^{4}=100$ and $x y=4$; determine its area.
+Answer: $\mathbf{4 \sqrt { 1 7 }}$. By symmetry, the quadrilateral is a rectangle having $x=y$ and $x=-y$ as axes of symmetry. Let $(a, b)$ with $a>b>0$ be one of the vertices. Then the desired area is
+
+$$
+(\sqrt{2}(a-b)) \cdot(\sqrt{2}(a+b))=2\left(a^{2}-b^{2}\right)=2 \sqrt{a^{4}-2 a^{2} b^{2}+b^{4}}=2 \sqrt{100-2 \cdot 4^{2}}=4 \sqrt{17}
+$$
+
+6. [5] Consider the polynomial $P(x)=x^{3}+x^{2}-x+2$. Determine all real numbers $r$ for which there exists a complex number $z$ not in the reals such that $P(z)=r$.
+Answer: $\mathbf{r}>\mathbf{3}, \mathbf{r}<\frac{\mathbf{4 9}}{\mathbf{2 7}}$. Because such roots to polynomial equations come in conjugate pairs, we seek the values $r$ such that $P(x)=r$ has just one real root $x$. Considering the shape of a cubic, we are interested in the boundary values $r$ such that $P(x)-r$ has a repeated zero. Thus, we write
+
+$$
+P(x)-r=x^{3}+x^{2}-x+(2-r)=(x-p)^{2}(x-q)=x^{3}-(2 p+q) x^{2}+p(p+2 q) x-p^{2} q
+$$
+
+Then $q=-2 p-1$ and $1=p(p+2 q)=p(-3 p-2)$ so that $p=1 / 3$ or $p=-1$. It follows that the graph of $P(x)$ is horizontal at $x=1 / 3$ (a maximum) and $x=-1$ (a minimum), so the desired values $r$ are $r>P(-1)=3$ and $r
0$ for $n \geq 0$, so necessarily $B=0$, and $a_{0}=1 \Rightarrow A=1$. Therefore, the unique solution to the recurrence is $a_{n}=2^{n}$ for all n .
+8. [6] Let $A:=\mathbb{Q} \backslash\{0,1\}$ denote the set of all rationals other than 0 and 1. A function $f: A \rightarrow \mathbb{R}$ has the property that for all $x \in A$,
+
+$$
+f(x)+f\left(1-\frac{1}{x}\right)=\log |x|
+$$
+
+Compute the value of $f(2007)$.
+Answer: $\log (\mathbf{2 0 0 7} / \mathbf{2 0 0 6})$. Let $g: A \rightarrow A$ be defined by $g(x):=1-1 / x$; the key property is that
+
+$$
+g(g(g(x)))=1-\frac{1}{1-\frac{1}{1-\frac{1}{x}}}=x
+$$
+
+The given equation rewrites as $f(x)+f(g(x))=\log |x|$. Substituting $x=g(y)$ and $x=g(g(z))$ gives the further equations $f(g(y))+f(g(g(y)))=\log |g(x)|$ and $f(g(g(z)))+f(z)=\log |g(g(x))|$. Setting $y$ and $z$ to $x$ and solving the system of three equations for $f(x)$ gives
+
+$$
+f(x)=\frac{1}{2} \cdot(\log |x|-\log |g(x)|+\log |g(g(x))|)
+$$
+
+For $x=2007$, we have $g(x)=\frac{2006}{2007}$ and $g(g(x))=\frac{-1}{2006}$, so that
+
+$$
+f(2007)=\frac{\log |2007|-\log \left|\frac{2006}{2007}\right|+\log \left|\frac{-1}{2006}\right|}{2}=\log (2007 / 2006)
+$$
+
+9. [7] The complex numbers $\alpha_{1}, \alpha_{2}, \alpha_{3}$, and $\alpha_{4}$ are the four distinct roots of the equation $x^{4}+2 x^{3}+2=0$. Determine the unordered set
+
+$$
+\left\{\alpha_{1} \alpha_{2}+\alpha_{3} \alpha_{4}, \alpha_{1} \alpha_{3}+\alpha_{2} \alpha_{4}, \alpha_{1} \alpha_{4}+\alpha_{2} \alpha_{3}\right\} .
+$$
+
+Answer: $\{\mathbf{1} \pm \sqrt{\mathbf{5}}, \mathbf{- 2}\}$. Employing the elementary symmetric polynomials $\left(s_{1}=\alpha_{1}+\alpha_{2}+\alpha_{3}+\alpha_{4}=\right.$ $-2, s_{2}=\alpha_{1} \alpha_{2}+\alpha_{1} \alpha_{3}+\alpha_{1} \alpha_{4}+\alpha_{2} \alpha_{3}+\alpha_{2} \alpha_{4}+\alpha_{3} \alpha_{4}=0, s_{3}=\alpha_{1} \alpha_{2} \alpha_{3}+\alpha_{2} \alpha_{3} \alpha_{4}+\alpha_{3} \alpha_{4} \alpha_{1}+\alpha_{4} \alpha_{1} \alpha_{2}=0$, and $s_{4}=\alpha_{1} \alpha_{2} \alpha_{3} \alpha_{4}=2$ ) we consider the polynomial
+
+$$
+P(x)=\left(x-\left(\alpha_{1} \alpha_{2}+\alpha_{3} \alpha_{4}\right)\right)\left(x-\left(\alpha_{1} \alpha_{3}+\alpha_{2} \alpha_{4}\right)\right)\left(x-\left(\alpha_{1} \alpha_{4}+\alpha_{2} \alpha_{3}\right)\right)
+$$
+
+Because $P$ is symmetric with respect to $\alpha_{1}, \alpha_{2}, \alpha_{3}, \alpha_{4}$, we can express the coefficients of its expanded form in terms of the elementary symmetric polynomials. We compute
+
+$$
+\begin{aligned}
+P(x) & =x^{3}-s_{2} x^{2}+\left(s_{3} s_{1}-4 s_{4}\right) x+\left(-s_{3}^{2}-s_{4} s_{1}^{2}+s_{4} s_{2}\right) \\
+& =x^{3}-8 x-8 \\
+& =(x+2)\left(x^{2}-2 x-4\right)
+\end{aligned}
+$$
+
+The roots of $P(x)$ are -2 and $1 \pm \sqrt{5}$, so the answer is $\{1 \pm \sqrt{5},-2\}$.
+Remarks. It is easy to find the coefficients of $x^{2}$ and $x$ by expansion, and the constant term can be computed without the complete expansion and decomposition of $\left(\alpha_{1} \alpha_{2}+\alpha_{3} \alpha_{4}\right)\left(\alpha_{1} \alpha_{3}+\alpha_{2} \alpha_{4}\right)\left(\alpha_{1} \alpha_{4}+\right.$ $\alpha_{2} \alpha_{3}$ ) by noting that the only nonzero 6 th degree expressions in $s_{1}, s_{2}, s_{3}$, and $s_{4}$ are $s_{1}^{6}$ and $s_{4} s_{1}^{2}$. The general polynomial $P$ constructed here is called the cubic resolvent and arises in Galois theory.
+10. [8] The polynomial $f(x)=x^{2007}+17 x^{2006}+1$ has distinct zeroes $r_{1}, \ldots, r_{2007}$. A polynomial $P$ of degree 2007 has the property that $P\left(r_{j}+\frac{1}{r_{j}}\right)=0$ for $j=1, \ldots, 2007$. Determine the value of $P(1) / P(-1)$.
+
+Answer: | $\mathbf{2 8 9}$. |
+| :---: |
+| For some constant $k$, we have |
+
+$$
+P(z)=k \prod_{j=1}^{2007}\left(z-\left(r_{j}+\frac{1}{r_{j}}\right)\right)
+$$
+
+Now writing $\omega^{3}=1$ with $\omega \neq 1$, we have $\omega^{2}+\omega=-1$. Then
+
+$$
+\begin{gathered}
+P(1) / P(-1)=\frac{k \prod_{j=1}^{2007}\left(1-\left(r_{j}+\frac{1}{r_{j}}\right)\right)}{k \prod_{j=1}^{2007}\left(-1-\left(r_{j}+\frac{1}{r_{j}}\right)\right)}=\prod_{j=1}^{2007} \frac{r_{j}^{2}-r_{j}+1}{r_{j}^{2}+r_{j}+1}=\prod_{j=1}^{2007} \frac{\left(-\omega-r_{j}\right)\left(-\omega^{2}-r_{j}\right)}{\left(\omega-r_{j}\right)\left(\omega^{2}-r_{j}\right)} \\
+=\frac{f(-\omega) f\left(-\omega^{2}\right)}{f(\omega) f\left(\omega^{2}\right)}=\frac{\left(-\omega^{2007}+17 \omega^{2006}+1\right)\left(-\left(\omega^{2}\right)^{2007}+17\left(\omega^{2}\right)^{2006}+1\right)}{\left(\omega^{2007}+17 \omega^{2006}+1\right)\left(\left(\omega^{2}\right)^{2007}+17\left(\omega^{2}\right)^{2006}+1\right)}=\frac{\left(17 \omega^{2}\right)(17 \omega)}{\left(2+17 \omega^{2}\right)(2+17 \omega)} \\
+=\frac{289}{4+34\left(\omega+\omega^{2}\right)+289}=\frac{289}{259} .
+\end{gathered}
+$$
+
diff --git a/HarvardMIT/md/en-102-2007-feb-calc-solutions.md b/HarvardMIT/md/en-102-2007-feb-calc-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..e43f8deb2a6de7a9fab84988abc39b1ea4df900a
--- /dev/null
+++ b/HarvardMIT/md/en-102-2007-feb-calc-solutions.md
@@ -0,0 +1,130 @@
+# $10^{\text {th }}$ Annual Harvard-MIT Mathematics Tournament 0$ are positive and $l_{0}, l_{3} \geq 0$ are nonnegative. The equations
+
+$$
+w_{1}+w_{2}+w_{3}=10 \quad \text { and } \quad\left(l_{0}+1\right)+l_{1}+l_{2}+\left(l_{3}+1\right)=8
+$$
+
+are independent, and have $\binom{9}{2}$ and $\binom{7}{3}$ solutions, respectively. It follows that the answer is
+
+$$
+\frac{\binom{9}{2}\binom{7}{3}}{\binom{16}{6}}=\frac{315}{2002}
+$$
+
+18. [10] Convex quadrilateral $A B C D$ has right angles $\angle A$ and $\angle C$ and is such that $A B=B C$ and $A D=C D$. The diagonals $A C$ and $B D$ intersect at point $M$. Points $P$ and $Q$ lie on the circumcircle of triangle $A M B$ and segment $C D$, respectively, such that points $P, M$, and $Q$ are collinear. Suppose that $m \angle A B C=160^{\circ}$ and $m \angle Q M C=40^{\circ}$. Find $M P \cdot M Q$, given that $M C=6$.
+
+
+Answer: 36. Note that $m \angle Q P B=m \angle M P B=m \angle M A B=m \angle C A B=\angle B C A=\angle C D B$. Thus, $M P \cdot M Q=M B \cdot M D$. On the other hand, segment $C M$ is an altitude of right triangle $B C D$, so $M B \cdot M D=M C^{2}=36$.
+$10^{\text {th }}$ HARVARD-MIT MATHEMATICS TOURNAMENT, 24 FEBRUARY 2007 - GUTS ROUND
+19. [10] Define $x \star y=\frac{\sqrt{x^{2}+3 x y+y^{2}-2 x-2 y+4}}{x y+4}$. Compute
+
+$$
+((\cdots((2007 \star 2006) \star 2005) \star \cdots) \star 1) .
+$$
+
+Answer: $\frac{\sqrt{\mathbf{1 5}}}{\mathbf{9}}$. Note that $x \star 2=\frac{\sqrt{x^{2}+6 x+4-2 x-4+4}}{2 x+4}=\frac{\sqrt{(x+2)^{2}}}{2(x+2)}=\frac{1}{2}$ for $x>-2$. Because $x \star y>0$ if $x, y>0$, we need only compute $\frac{1}{2} \star 1=\frac{\sqrt{\frac{1}{4}+\frac{3}{2}+1-3+4}}{\frac{1}{2}+4}=\frac{\sqrt{15}}{9}$.
+20. [10] For $a$ a positive real number, let $x_{1}, x_{2}, x_{3}$ be the roots of the equation $x^{3}-a x^{2}+a x-a=0$. Determine the smallest possible value of $x_{1}^{3}+x_{2}^{3}+x_{3}^{3}-3 x_{1} x_{2} x_{3}$.
+Answer: -4 . Note that $x_{1}+x_{2}+x_{3}=x_{1} x_{2}+x_{2} x_{3}+x_{3} x_{1}=a$. Then
+
+$$
+\begin{aligned}
+& x_{1}^{3}+x_{2}^{3}+x_{3}^{3}-3 x_{1} x_{2} x_{3}=\left(x_{1}+x_{2}+x_{3}\right)\left(x_{1}^{2}+x_{2}^{2}+x_{3}^{2}-\left(x_{1} x_{2}+x_{2} x_{3}+x_{3} x_{1}\right)\right) \\
+& \quad=\left(x_{1}+x_{2}+x_{3}\right)\left(\left(x_{1}+x_{2}+x_{3}\right)^{2}-3\left(x_{1} x_{2}+x_{2} x_{3}+x_{3} x_{1}\right)\right)=a \cdot\left(a^{2}-3 a\right)=a^{3}-3 a^{2}
+\end{aligned}
+$$
+
+The expression is negative only where $01$. How many ordered triples $(x, y, n)$ of solutions are there to the equation $x^{n}-y^{n}=2^{100}$ ?
+Answer: 49. Break all possible values of $n$ into the four cases: $n=2, n=4, n>4$ and $n$ odd. By Fermat's theorem, no solutions exist for the $n=4$ case because we may write $y^{4}+\left(2^{25}\right)^{4}=x^{4}$.
+We show that for $n$ odd, no solutions exist to the more general equation $x^{n}-y^{n}=2^{k}$ where $k$ is a positive integer. Assume otherwise for contradiction's sake, and suppose on the grounds of well ordering that $k$ is the least exponent for which a solution exists. Clearly $x$ and $y$ must both be even or both odd. If both are odd, we have $(x-y)\left(x^{n-1}+\ldots+y^{n-1}\right)$. The right factor of this expression contains an odd number of odd terms whose sum is an odd number greater than 1 , impossible. Similarly if $x$ and $y$ are even, write $x=2 u$ and $y=2 v$. The equation becomes $u^{n}-v^{n}=2^{k-n}$. If $k-n$ is greater than 0 , then our choice $k$ could not have been minimal. Otherwise, $k-n=0$, so that two consecutive positive integers are perfect $n$th powers, which is also absurd.
+For the case that $n$ is even and greater than 4, consider the same generalization and hypotheses. Writing $n=2 m$, we find $\left(x^{m}-y^{m}\right)\left(x^{m}+y^{m}\right)=2^{k}$. Then $x^{m}-y^{m}=2^{a}<2^{k}$. By our previous work, we see that $m$ cannot be an odd integer greater than 1 . But then $m$ must also be even, contrary to the minimality of $k$.
+Finally, for $n=2$ we get $x^{2}-y^{2}=2^{100}$. Factoring the left hand side gives $x-y=2^{a}$ and $x+y=2^{b}$, where implicit is $a2$ together with the initial values $a_{1}=8$ and $a_{2}=64$ and $a_{3}=1024$. Compute
+
+$$
+\sqrt{a_{1}+\sqrt{a_{2}+\sqrt{a_{3}+\cdots}}}
+$$
+
+Answer: $\mathbf{3} \sqrt{\mathbf{2}}$. Taking the base- $2 \log$ of the sequence $\left\{a_{n}\right\}$ converts the multiplicative rule to a more familiar additive rule: $\log _{2}\left(a_{n+1}\right)-4 \log _{2}\left(a_{n}\right)+5 \log _{2}\left(a_{n-1}\right)-2 \log _{2}\left(a_{n-2}\right)=0$. The characteristic equation is $0=x^{3}-4 x^{2}+5 x-2=(x-1)^{2}(x-2)$, so $\log _{2}\left(a_{n}\right)$ is of the form $a \cdot n+b+c \cdot 2^{n}$ and we find $a_{n}=2^{2 n+2^{n-1}}$. Now,
+
+$$
+\sqrt{a_{1}+\sqrt{a_{2}+\sqrt{a_{3}+\cdots}}}=\sqrt{2} \cdot \sqrt{4+\sqrt{16+\sqrt{64+\cdots}}}
+$$
+
+We can estimate the new nested radical expression as 3 , which expands thus
+
+$$
+3=\sqrt{4+5}=\sqrt{4+\sqrt{16+9}}=\sqrt{4+\sqrt{16+\sqrt{64+17}}}=\cdots
+$$
+
+As a rigorous confirmation, we have $2^{k}+1=\sqrt{4^{k}+\left(2^{k+1}+1\right)}$, as desired. It follows that the answer is $3 \sqrt{2}$.
+30. [15] $A B C D$ is a cyclic quadrilateral in which $A B=3, B C=5, C D=6$, and $A D=10 . M, I$, and $T$ are the feet of the perpendiculars from $D$ to lines $A B, A C$, and $B C$ respectively. Determine the value of $M I / I T$.
+
+
+Answer: $\frac{\mathbf{2 5}}{\mathbf{9}}$. Quadrilaterals $A M I D$ and $D I C T$ are cyclic, having right angles $\angle A M D, \angle A I D$, and $\angle C I D, \angle C T D$ respectively. We see that $M, I$, and $T$ are collinear. For, $m \angle M I D=\pi-m \angle D A M=$ $\pi-m \angle D A B=m \angle B C D=\pi-m \angle D C T=\pi-m \angle D I T$. Therefore, Menelaus' theorem applied to triangle $M T B$ and line $I C A$ gives
+
+$$
+\frac{M I}{I T} \cdot \frac{T C}{C B} \cdot \frac{B A}{A M}=1
+$$
+
+On the other hand, triangle $A D M$ is similar to triangle $C D T$ since $\angle A M D \cong \angle C T D$ and $\angle D A M \cong$ $\angle D C T$ and thus $A M / C T=A D / C D$. It follows that
+
+$$
+\frac{M I}{I T}=\frac{B C \cdot A M}{A B \cdot C T}=\frac{B C \cdot A D}{A B \cdot C D}=\frac{5 \cdot 10}{3 \cdot 6}=\frac{25}{9}
+$$
+
+Remarks. The line MIT, constructed in this problem by taking perpendiculars from a point on the circumcircle of $A B C$, is known as the Simson line. It is often helpful for us to use directed angles while angle chasing to avoid supplementary configuration issues, such as those arising while establishing the collinearity of $M, I$, and $T$.
+
+## $10^{\text {th }}$ HARVARD-MIT MATHEMATICS TOURNAMENT, 24 FEBRUARY 2007 - GUTS ROUND
+
+31. [18] A sequence $\left\{a_{n}\right\}_{n \geq 0}$ of real numbers satisfies the recursion $a_{n+1}=a_{n}^{3}-3 a_{n}^{2}+3$ for all positive integers $n$. For how many values of $a_{0}$ does $a_{2007}=a_{0}$ ?
+Answer: $\mathbf{3}^{\mathbf{2 0 0 7}}$. If $x$ appears in the sequence, the next term $x^{3}-3 x^{2}+3$ is the same if and only if $0=x^{3}-3 x^{2}-x+3=(x-3)(x-1)(x+1)$. Moreover, that next term is strictly larger if $x>3$ and strictly smaller if $x<-1$. It follows that no values of $a_{0}$ with $\left|a_{0}-1\right|>2$ yield $a_{0}=a_{2007}$.
+Now suppose $a_{0}=a_{2007}$ and write $a_{0}=1+e^{\alpha i}+e^{-\alpha i}$; the values $a_{0}$ we seek will be in bijective correspondence with solutions $\alpha$ where $0 \leq \alpha \leq \pi$. Then
+
+$$
+a_{1}=\left(a_{0}-1\right)^{3}-3 a_{0}+4=e^{3 \alpha i}+3 e^{\alpha i}+3 e^{-\alpha i}+e^{-3 \alpha i}-3 e^{\alpha i}-3 e^{-\alpha i}-3+4=e^{3 \alpha i}+e^{-3 \alpha i}+1
+$$
+
+and an easy inductive argument gives $a_{2007}=e^{3^{2007} \alpha i}+e^{-3^{2007} \alpha i}+1$. It follows that $a_{0}=a_{2007}$ is equivalent to $\cos (\alpha)=\cos \left(3^{2007} \alpha\right)$. Now,
+
+$$
+\cos \left(3^{2007} \alpha\right)-\cos (\alpha)=2 \sin \left(\left(\frac{3^{2007}+1}{2}\right) \alpha\right) \sin \left(\left(\frac{3^{2007}-1}{2}\right) \alpha\right)
+$$
+
+so $\operatorname{since} \sin (k x)=0$ for a positive integer $k$ if and only if $x$ is a multiple of $\frac{\pi}{k}$, the solutions $\alpha$ are $\left\{0, \frac{2 \pi}{3^{2007}-1}, \frac{4 \pi}{3^{2007}-1}, \ldots, \pi\right\} \cup\left\{0, \frac{2 \pi}{3^{2007}+1}, \ldots, \pi\right\}$. Because our values $k$ are consecutive, these sets overlap only at 0 and $\pi$, so there are $3^{2007}$ distinct $\alpha$.
+32. [18] Triangle $A B C$ has $A B=4, B C=6$, and $A C=5$. Let $O$ denote the circumcenter of $A B C$. The circle $\Gamma$ is tangent to and surrounds the circumcircles of triangles $A O B, B O C$, and $A O C$. Determine the diameter of $\Gamma$.
+Answer: $\frac{\mathbf{2 5 6} \sqrt{\mathbf{7}}}{\mathbf{1 7}}$. Denote by $\omega, \Gamma_{1}, \Gamma_{2}$, and $\Gamma_{3}$ the circumcenters of triangles $A B C, B O C, C O A$, and $A O B$, respectively. An inversion about $\omega$ interchanges $\Gamma_{1}$ and line $B C, \Gamma_{2}$ and line $C A$, and $\Gamma_{3}$ and line $A B$. This inversion also preserves tangency between generalized circles, so the image of $\Gamma$ is a circle tangent to $A B, B C$, and $C A$. It is the incircle of $A B C$ because it is closer to $O$ than these lines and $A B C$ is acute.
+Now we run a few standard calculations. Where $s, r$, and $R$ denote the semiperimeter, inradius, and circumradius of $A B C$, respectively, we have the following:
+
+$$
+\begin{aligned}
+& {[A B C]=\sqrt{s(s-a)(s-b)(s-c)}=\frac{15 \sqrt{7}}{4}} \\
+& r=[A B C] / s=\sqrt{7} / 2 \\
+& R=\frac{a b c}{4[A B C]}=\frac{8}{\sqrt{7}} \\
+& O I^{2}=R(R-2 r)=\frac{8}{7}
+\end{aligned}
+$$
+
+Let $O I$ intersect the incircle of $A B C$ at $P$ and $Q$, with $I$ between $P$ and $O$. Then $O P=r+O I$ and $O Q=r-O I$, and $\overline{P Q}$ is a diameter. Under the inversion, $P$ and $Q$ map to $P^{\prime}$ and $Q^{\prime}$ respectively. Because $P, I, O$, and $Q$ are collinear in that order, $P^{\prime}$ and $Q^{\prime}$ are diametrically opposed on $\Gamma$. It follows that the diameter of $\Gamma$ is
+
+$$
+P^{\prime} Q^{\prime}=O P^{\prime}+O Q^{\prime}=\frac{R^{2}}{O P}+\frac{R^{2}}{O Q}=R^{2}\left(\frac{1}{r+O I}+\frac{1}{r-O I}\right)=\frac{2 r R^{2}}{r^{2}-O I^{2}} .
+$$
+
+We plug in the values found above to arrive at $\frac{256 \sqrt{7}}{17}$.
+
+33. [18] Compute
+
+$$
+\int_{1}^{2} \frac{9 x+4}{x^{5}+3 x^{2}+x} d x
+$$
+
+(No, your TI-89 doesn't know how to do this one. Yes, the end is near.)
+Answer: $\ln \frac{\mathbf{8 0}}{\mathbf{2 3}}$. We break the given integral into two pieces:
+
+$$
+\int_{1}^{2} \frac{9 x+4}{x^{5}+3 x^{2}+x} d x=5 \int_{1}^{2} \frac{x^{4}+3 x+1}{x^{5}+3 x^{2}+x} d x-\int_{1}^{2} \frac{5 x^{4}+6 x+1}{x^{5}+3 x^{2}+x} d x
+$$
+
+These two new integrals are easily computed; for, the first integrand reduces to $1 / x$ and the second is of the form $f^{\prime}(x) / f(x)$. We obtain
+
+$$
+\left[5 \ln |x|-\ln \left|x^{5}+3 x^{2}+x\right|\right]_{1}^{2}=\ln 32-\ln 46+\ln 5=\ln \frac{80}{23}
+$$
+
+Motivation. Writing $f(x)=9 x+4$ and $g(x)=x^{5}+3 x^{2}+x=x\left(x^{4}+3 x+1\right)$, we wish to find the antiderivative of $f(x) / g(x)$. It makes sense to consider other rational functions with denominator $g(x)$ that have an exact antiderivative. Clearly, if the numerator were $f_{1}(x)=x^{4}+3 x+1$ or a constant multiple, then we can integrate the function. Another trivial case is if the numerator were $f_{2}(x)=g^{\prime}(x)=5 x^{4}+6 x+1$ or a constant multiple. Guessing that $f(x)$ is a linear combination of $f_{1}(x)$ and $f_{2}(x)$, we easily find that $f(x)=9 x+4=5 f_{1}(x)-f_{2}(x)$.
+$10^{\text {th }}$ HARVARD-MIT MATHEMATICS TOURNAMENT, 24 FEBRUARY 2007 - GUTS ROUND
+34. [?] The Game. Eric and Greg are watching their new favorite TV show, The Price is Right. Bob Barker recently raised the intellectual level of his program, and he begins the latest installment with bidding on following question: How many Carmichael numbers are there less than 100,000?
+Each team is to list one nonnegative integer not greater than 100,000. Let $X$ denote the answer to Bob's question. The teams listing $N$, a maximal bid (of those submitted) not greater than $X$, will receive $N$ points, and all other teams will neither receive nor lose points. (A Carmichael number is an odd composite integer $n$ such that $n$ divides $a^{n-1}-1$ for all integers $a$ relatively prime to $n$ with $1n^{2 / 7}$, although this bound has been subsequently improved. (For details, see Alford, W. R.; Granville, A.; and Pomerance, C. "There are Infinitely Many Carmichael Numbers." Annals of Mathematics. 139 (1994), 703-722.) The expectation is that teams are unable to determine that $X=16$; otherwise, the obvious dominant play is listing 16. The Problem Czar, anticipating that teams will attempt to deduce $X$ by considering the point values of the other problems in the triplet, has chosen a value $X$ that is considerably lower. Teams may of course speculate whether this action has been taken, and to what extent, etc... On the actual TV show, many contestants win by guessing prices of 1 , or other numbers dramatically lower than the actual price. This strategy is enhanced because of the show's ordered bidding, and will be more difficult here. It will be interesting to see the submissions.
+35. [ $\leq \mathbf{2 5}]$ The Algorithm. There are thirteen broken computers situated at the following set $S$ of thirteen points in the plane:
+
+$$
+\begin{array}{lll}
+A=(1,10) & B=(976,9) & C=(666,87) \\
+D=(377,422) & E=(535,488) & F=(775,488) \\
+G=(941,500) & H=(225,583) & I=(388,696) \\
+J=(3,713) & K=(504,872) & L=(560,934) \\
+& M=(22,997) &
+\end{array}
+$$
+
+At time $t=0$, a repairman begins moving from one computer to the next, traveling continuously in straight lines at unit speed. Assuming the repairman begins and $A$ and fixes computers instantly, what path does he take to minimize the total downtime of the computers? List the points he visits in order. Your score will be $\left\lfloor\frac{N}{40}\right\rfloor$, where
+
+$$
+N=1000+\lfloor\text { the optimal downtime }\rfloor-\lfloor\text { your downtime }\rfloor,
+$$
+
+or 0 , whichever is greater. By total downtime we mean the sum
+
+$$
+\sum_{P \in S} t_{P}
+$$
+
+where $t_{P}$ is the time at which the repairman reaches $P$.
+Answer: ADHIKLEFGBCJM. This is an instance of the minimum-latency problem, which is at least NP-hard. There is an easy $O(n!)$ algorithm, but this is unavailable to teams on computational grounds ( 100 MHz calculators used to seem fast...) The best strategy may be drawing an accurate picture and exercising geometric intuition. The distribution of the points somewhat resembles a short, four-pronged fork with its outermost prongs bent apart; it is plausible to assume that the optimal order respects this shape. The optimal downtime is 24113.147907 , realized by ADHIKLEFGBCJM, though a number of others also receive positive marks.
+36. [25] The Marathon. Let $\omega$ denote the incircle of triangle $A B C$. The segments $B C, C A$, and $A B$ are tangent to $\omega$ at $D, E$, and $F$, respectively. Point $P$ lies on $E F$ such that segment $P D$ is perpendicular to $B C$. The line $A P$ intersects $B C$ at $Q$. The circles $\omega_{1}$ and $\omega_{2}$ pass through $B$ and $C$, respectively, and are tangent to $A Q$ at $Q$; the former meets $A B$ again at $X$, and the latter meets $A C$ again at $Y$. The line $X Y$ intersects $B C$ at $Z$. Given that $A B=15, B C=14$, and $C A=13$, find $\lfloor X Z \cdot Y Z\rfloor$.
+
+
+Answer: 101. Construct $D^{\prime}$ diametrically opposed to $D$, so that $\angle D F D^{\prime}$ and $\angle D E D^{\prime}$ are right, and note that $P$ lies on $D D^{\prime}$. By standard angle chasing, $m \angle F D D^{\prime}=\beta$ (half angle $B$ ) and $m \angle D^{\prime} D E=\gamma$. Thus, $m \angle D D^{\prime} F=90^{\circ}-\beta$ and $m \angle E D^{\prime} D=90^{\circ}-\gamma$. Then by the law of sines, $D E: E D^{\prime}: D^{\prime} F$ : $F D=\cos (\gamma): \sin (\gamma): \sin (\beta): \sin (\gamma)$. Now using $\triangle D E P \sim \triangle F D^{\prime} P$ and $\triangle D F P \sim \triangle E D^{\prime} P$, we have
+
+$$
+\frac{E P}{P F}=\frac{E D \cdot E D^{\prime}}{F D \cdot F D^{\prime}}=\frac{\sin (\gamma) \cos (\gamma)}{\sin (\beta) \sin (\beta)}=\frac{c}{b}
+$$
+
+Let the dilation centered at $A$ sending $E$ to $C$ map $P$ and $F$ to $P^{\prime}$ and $F^{\prime}$, respectively. Note that $A F^{\prime}=A C$ as $A E$ and $A F$ are equal tangents, and $C P^{\prime}: P^{\prime} F^{\prime}=E P: P F=c: b$ by similarity. Then by Menelaus' theorem,
+
+$$
+1=\frac{B Q}{Q C} \frac{C P^{\prime}}{P^{\prime} F^{\prime}} \frac{F^{\prime} A}{A B}=\frac{B Q}{Q C} \frac{c}{b} \frac{b}{c}
+$$
+
+so that $B Q=Q C$ and $A Q$ is actually a median. So, $A Q^{2}=\frac{1}{4}\left(2 b^{2}+2 c^{2}-a^{2}\right)=148$. Now by Power of a Point, $A B \cdot A X=A Q^{2}=A C \cdot A Y$, so $A X=148 / 15$ and $A Y=148 / 13$. Moreover, $B X C Y$ is cyclic as $\triangle A B C \sim \triangle A Y X$. Thus, $X Z \cdot Y Z=B Z \cdot C Z$, and it suffices to compute $B Z / C Z$. Menelaus once more gives
+
+$$
+1=\frac{B Z}{Z C} \frac{C Y}{Y A} \frac{A X}{X B}
+$$
+
+whence, $B Z / C Z=(A Y / A X)(B X / C Y)=(15 / 13)((77 \cdot 13) /(21 \cdot 15))=11 / 3$. We write $C Z=3 d$ and $B Z=11 d$. Because $A X 1 \\
+b^{2}>4 a c>4 c^{2} \Rightarrow b>2 c
+\end{gathered}
+$$
+
+Evaluated at 1 , the polynomial must be greater than 0 , so $a+c>b$. Then:
+
+$$
+\begin{gathered}
+2 c Saturday 8 November 2008
+
+## Team Round
+
+## Unit Fractions [100]
+
+A unit fraction is a fraction of the form $\frac{1}{n}$, where $n$ is a positive integer. In this problem, you will find out how rational numbers can be expressed as sums of these unit fractions. Even if you do not solve a problem, you may apply its result to later problems.
+
+We say we decompose a rational number $q$ into unit fractions if we write $q$ as a sum of 2 or more distinct unit fractions. In particular, if we write $q$ as a sum of $k$ distinct unit fractions, we say we have decomposed $q$ into $k$ fractions. As an example, we can decompose $\frac{2}{3}$ into 3 fractions: $\frac{2}{3}=\frac{1}{3}+\frac{1}{4}+\frac{1}{12}$.
+
+1. (a) Decompose 1 into unit fractions.
+
+Answer: $\frac{1}{2}+\frac{1}{3}+\frac{1}{6}$
+(b) Decompose $\frac{1}{4}$ into unit fractions.
+
+Answer: $\frac{1}{8}+\frac{1}{12}+\frac{1}{24}$
+(c) Decompose $\frac{2}{5}$ into unit fractions.
+
+Answer: $\frac{1}{5}+\frac{1}{10}+\frac{1}{15}+\frac{1}{30}$
+2. Explain how any unit fraction $\frac{1}{n}$ can be decomposed into other unit fractions.
+
+Answer: $\frac{1}{2 n}+\frac{1}{3 n}+\frac{1}{6 n}$
+3. (a) Write 1 as a sum of 4 distinct unit fractions.
+
+Answer: $\frac{1}{2}+\frac{1}{3}+\frac{1}{7}+\frac{1}{42}$
+(b) Write 1 as a sum of 5 distinct unit fractions.
+
+Answer: $\frac{1}{2}+\frac{1}{3}+\frac{1}{7}+\frac{1}{43}+\frac{1}{43 \cdot 42}$
+(c) Show that, for any integer $k>3,1$ can be decomposed into $k$ unit fractions.
+
+Solution: If we can do it for $k$ fractions, simply replace the last one (say $\frac{1}{n}$ ) with $\frac{1}{n+1}+\frac{1}{n(n+1)}$. Then we can do it for $k+1$ fractions. So, since we can do it for $k=3$, we can do it for any $k>3$.
+4. Say that $\frac{a}{b}$ is a positive rational number in simplest form, with $a \neq 1$. Further, say that $n$ is an integer such that:
+
+$$
+\frac{1}{n}>\frac{a}{b}>\frac{1}{n+1}
+$$
+
+Show that when $\frac{a}{b}-\frac{1}{n+1}$ is written in simplest form, its numerator is smaller than $a$.
+Solution: $\quad \frac{a}{b}-\frac{1}{n+1}=\frac{a(n+1)-b}{b(n+1)}$. Therefore, when we write it in simplest form, its numerator will be at most $a(n+1)-b$. We claim that $a(n+1)-bn$, which is given.
+
+## 5. An aside: the sum of all the unit fractions
+
+It is possible to show that, given any real M , there exists a positive integer $k$ large enough that:
+
+$$
+\sum_{n=1}^{k} \frac{1}{n}=\frac{1}{1}+\frac{1}{2}+\frac{1}{3} \ldots>M
+$$
+
+Note that this statement means that the infinite harmonic series, $\sum_{n=1}^{\infty} \frac{1}{n}$, grows without bound, or diverges. For the specific example $\mathrm{M}=5$, find a value of $k$, not necessarily the smallest, such that the inequality holds. Justify your answer.
+
+Solution: Note that $\frac{1}{n+1}+\frac{1}{n+2}+\ldots+\frac{1}{2 n}>\frac{1}{2 n}+\ldots+\frac{1}{2 n}=\frac{1}{2}$. Therefore, if we apply this to $n=1,2,4,8,16,32,64,128$, we get
+
+$$
+\left(\frac{1}{2}\right)+\left(\frac{1}{3}+\frac{1}{4}\right)+\left(\frac{1}{5}+\frac{1}{6}+\frac{1}{7}+\frac{1}{8}\right)+\ldots+\left(\frac{1}{129}+\ldots+\frac{1}{256}\right)>\frac{1}{2}+\ldots+\frac{1}{2}=4
+$$
+
+so, adding in $\frac{1}{1}$, we get
+
+$$
+\sum_{n=1}^{256} \frac{1}{n}>5
+$$
+
+so $k=256$ will suffice.
+6. Now, using information from problems 4 and 5 , prove that the following method to decompose any positive rational number will always terminate:
+Step 1. Start with the fraction $\frac{a}{b}$. Let $t_{1}$ be the largest unit fraction $\frac{1}{n}$ which is less than or equal to $\frac{a}{b}$.
+Step 2. If we have already chosen $t_{1}$ through $t_{k}$, and if $t_{1}+t_{2}+\ldots+t_{k}$ is still less than $\frac{a}{b}$, then let $t_{k+1}$ be the largest unit fraction less than both $t_{k}$ and $\frac{a}{b}$.
+Step 3. If $t_{1}+\ldots+t_{k+1}$ equals $\frac{a}{b}$, the decomposition is found. Otherwise, repeat step 2 .
+Why does this method never result in an infinite sequence of $t_{i}$ ?
+Solution: Let $\frac{a_{k}}{b_{k}}=\frac{a}{b}-t_{1}-\ldots-t_{k}$, where $\frac{a_{k}}{b_{k}}$ is a fraction in simplest terms. Initially, this algorithm will have $t_{1}=1, t_{2}=\frac{1}{2}, t_{3}=\frac{1}{3}$, etc. until $\frac{a_{k}}{b_{k}}<\frac{1}{k+1}$. This will eventually happen by problem 5 , since there exists a $k$ such that $\frac{1}{1}+\ldots+\frac{1}{k+1}>\frac{a_{k}}{b_{k}}$. At that point, there is some $n$ with $\frac{1}{n} P A$ and $P C 1$, let $a_{n}$ be the largest real number such that
+
+$$
+4\left(a_{n-1}^{2}+a_{n}^{2}\right)=10 a_{n-1} a_{n}-9
+$$
+
+What is the largest positive integer less than $a_{8}$ ?
+Answer: 335 Let $t_{n}$ be the larger real such that $a_{n}=t_{n}+\frac{1}{t_{n}}$. Then $t_{1}=\frac{3+\sqrt{5}}{2}$. We claim that $t_{n}=2 t_{n-1}$. Writing the recurrence as a quadratic polynomial in $a_{n}$, we have:
+
+$$
+4 a_{n}^{2}-10 a_{n-1} a_{n}+4 a_{n-1}^{2}+9=0
+$$
+
+Using the quadratic formula, we see that $a_{n}=\frac{5}{4} a_{n-1}+\frac{3}{4} \sqrt{a_{n-1}^{2}-4}$. (We ignore the negative square root, since $a_{n}$ is the largest real number satisfying the polynomial.) Substituting $t_{n-1}+\frac{1}{t_{n-1}}$ for $a_{n-1}$, we see that $\sqrt{a_{n-1}^{2}-4}=\sqrt{t_{n-1}^{2}-2+\frac{1}{t_{n-1}^{2}}}$, so we have:
+
+$$
+a_{n}=\frac{5}{4}\left(t_{n-1}+\frac{1}{t_{n-1}}\right)+\frac{3}{4} \sqrt{\left(t_{n-1}-\frac{1}{t_{n-1}}\right)^{2}}=2 t_{n-1}+\frac{1}{2 t_{n-1}}
+$$
+
+so $t_{n}=2 t_{n-1}$, as claimed. Then $a_{8}=\frac{128(3+\sqrt{5})}{2}+\frac{2}{128(3+\sqrt{5})}$. The second term is vanishingly small, so $\left\lfloor a_{8}\right\rfloor=\lfloor 64(3+\sqrt{5})\rfloor$. We approximate $\sqrt{5}$ to two decimal places as 2.24 , making this expression $\lfloor 335.36\rfloor=335$. Since our value of $\sqrt{5}$ is correct to within 0.005 , the decimal is correct to within 0.32 , which means the final answer is exact.
+$13^{\text {th }}$ ANNUAL HARVARD-MIT MATHEMATICS TOURNAMENT, 20 FEBRUARY 2010 - GUTS ROUND
+34. [25] 3000 people each go into one of three rooms randomly. What is the most likely value for the maximum number of people in any of the rooms? Your score for this problem will be 0 if you write down a number less than or equal to 1000 . Otherwise, it will be $25-27 \frac{|A-C|}{\min (A, C)-1000}$.
+Answer: 1019 To get a rough approximation, we can use the fact that a sum of identical random variables converges to a Gaussian distribution ${ }^{6}$ in this case with a mean of 1000 and a variance of $3000 \cdot \frac{2}{9}=667$. Since $\sqrt{667} \approx 26,1026$ is a good guess, as Gaussians tend to differ from their mean by approximately their variance.
+The actual answer was computed with the following python program:
+
+```
+facts = [0]*3001
+facts[0]=1
+for a in range(1,3001):
+ facts[a]=a*facts[a-1]
+def binom(n,k):
+ return facts[n]/(facts[k]*facts[n-k])
+```
+
+[^3]```
+maxes = [0]*3001
+M = 1075
+for a in range(0,3001):
+ for b in range(0,3001-a):
+ c = 3000-a-b
+ m = max (a,max (b,c))
+ if m < M:
+ maxes[m] += facts[3000]/(facts[a]*facts[b]*facts[c])
+ print [a,b]
+best = 1000
+for a in range(1000,1050):
+ print maxes[a],a
+ if maxes[best] <= maxes[a]:
+ best = a
+print maxes[best]
+print best
+```
+
+We can use arguments involving the Chernoff bound ${ }^{7}$ to show that the answer is necessarily less than 1075. Alternately, if we wanted to be really careful, we could just set $M=3001$, but then we'd have to wait a while for the script to finish.
+35. [25] Call an positive integer almost-square if it can be written as $a \cdot b$, where $a$ and $b$ are integers and $a \leq b \leq \frac{4}{3} a$. How many almost-square positive integers are less than or equal to 1000000 ? Your score will be equal to $25-65 \frac{|A-C|}{\min (A, C)}$.
+Answer: 130348 To get a good estimate for the number of almost-square integers, note that any number of the form $a \cdot b$, with $b \leq \frac{4}{3} a$, will be by definition almost-square. Let's assume that it's relatively unlikely that a number is almost-square in more than one way. Then the number of almostsquare numbers less than $n$ will be approximately
+
+$$
+\sum_{a=1}^{\sqrt{n}} \sum_{b=a}^{\frac{4}{3} a} 1=\frac{1}{3} \sum_{a=1}^{\sqrt{n}} a=\frac{1}{6} \sqrt{n}(\sqrt{n}+1)
+$$
+
+which is about $\frac{n}{6}$. So, $\frac{n}{6}$ will be a fairly good estimate for the number of almost-square numbers less than $n$, making 160000 a reasonable guess.
+
+We can do better, though. For example, we summed $\frac{a}{3}$ all the way up to $\sqrt{n}$, but we are really overcounting here because when $a$ is close to $\sqrt{n}, a \cdot b$ will be less than $n$ only when $b \leq \frac{n}{a}$, as opposed to $b \leq \frac{4 a}{3}$. So we should really be taking the sum
+
+[^4]\[
+
+$$
+\begin{aligned}
+& \sum_{a=1}^{\sqrt{\frac{3 n}{4}}} \sum_{b=a}^{\frac{4 a}{3}} 1+\sum_{a=\sqrt{\frac{3 n}{4}}}^{\sqrt{n}} \sum_{b=a}^{\frac{n}{a}} 1 \\
+& \quad=\sum_{a=1}^{\sqrt{\frac{3 n}{4}}} \frac{a}{3}+\sum_{a=\sqrt{\frac{3 n}{4}}}^{\sqrt{n}}\left(\frac{n}{a}-a\right) \\
+& \quad \approx \frac{1}{6} \frac{3 n}{4}+n\left(\log (\sqrt{n})-\log \left(\sqrt{\frac{3 n}{4}}\right)\right)-\left(\frac{n}{2}-\frac{3 n}{8}\right) \\
+& \quad=\frac{n}{8}+n \frac{\log (4)-\log (3)}{2}-\frac{n}{8} \\
+& \quad=n \frac{\log (4)-\log (3)}{2}
+\end{aligned}
+$$
+\]
+
+In the process of taking the sum, we saw that we had something between $\frac{n}{8}$ and $\frac{n}{6}$, so we could also guess something between 166000 and 125000 , which would give us about 145000 , an even better answer. If we actually calculate $\frac{\log (4)-\log (3)}{2}$, we see that it's about 0.14384 , so 143840 would be the best guess if we were to use this strategy. In reality, we would want to round down a bit in both cases, since we are overcounting (because numbers could be square-free in multiple ways), so we should probably answer something like 140000 .
+
+A final refinement to our calculation (and perhaps easier than the previous one), is to assume that the products $a \cdot b$ that we consider are randomly distributed between 1 and $n$, and to compute the expected number of distinct numbers we end up with. This is the same type of problem as number 31 on this contest, and we compute that if we randomly distribute $k$ numbers between 1 and $n$ then we expect to end up with $n\left(1-\left(1-\frac{1}{n}\right)^{k}\right)$ distinct numbers. When $k=n \frac{\log (4)-\log (3)}{2}$, we get that this equals
+
+$$
+\begin{aligned}
+n\left(1-\left(\left(1-\frac{1}{n}\right)^{n}\right)^{\frac{\log (4)-\log (3)}{2}}\right) & =n\left(1-\sqrt{e^{\log (3)-\log (4)}}\right) \\
+& =n\left(1-\sqrt{\frac{3}{4}}\right) \\
+& =n\left(1-\frac{\sqrt{3}}{2}\right) \\
+& \approx 0.134 n
+\end{aligned}
+$$
+
+Giving us an answer of 134000 , which is very close to the correct answer.
+The actual answer was found by computer, using the following $\mathrm{C}++$ program:
+
+```
+#include \frac{A}{B}$ and $\frac{c}{d}>\frac{C}{D}$. Is it necessarily true that $\frac{a+c}{b+d}>\frac{A+C}{B+D}$ ?
+(b) Do there exist irrational numbers $\alpha$ and $\beta$ such that the sequence $\lfloor\alpha\rfloor+\lfloor\beta\rfloor,\lfloor 2 \alpha\rfloor+\lfloor 2 \beta\rfloor,\lfloor 3 \alpha\rfloor+$ $\lfloor 3 \beta\rfloor, \ldots$ is arithmetic?
+(c) For any set of primes $\mathbb{P}$, let $S_{\mathbb{P}}$ denote the set of integers whose prime divisors all lie in $\mathbb{P}$. For instance $S_{\{2,3\}}=\left\{2^{a} 3^{b} \mid a, b \geq 0\right\}=\{1,2,3,4,6,8,9,12, \ldots\}$. Does there exist a finite set of primes $\mathbb{P}$ and integer polynomials $P$ and $Q$ such that $\operatorname{gcd}(P(x), Q(y)) \in S_{\mathbb{P}}$ for all $x, y$ ?
+(d) A function $f$ is called P-recursive if there exists a positive integer $m$ and real polynomials $p_{0}(n), p_{1}(n), \ldots, p_{m}(n)$ satisfying
+
+$$
+p_{m}(n) f(n+m)=p_{m-1}(n) f(n+m-1)+\ldots+p_{0}(n) f(n)
+$$
+
+for all $n$. Does there exist a P-recursive function $f$ satisfying $\lim _{n \rightarrow \infty} \frac{f(n)}{n^{\sqrt{2}}}=1$ ?
+(e) Does there exist a nonpolynomial function $f: \mathbb{Z} \rightarrow \mathbb{Z}$ such that $a-b$ divides $f(a)-f(b)$ for all integers $a \neq b$ ?
+(f) Do there exist periodic functions $f, g: \mathbb{R} \rightarrow \mathbb{R}$ such that $f(x)+g(x)=x$ for all $x$ ?
+
+Proposed by: Alexander Katz
+Answer: NNNYYY
+34. [20]
+(a) Can 1000 queens be placed on a $2017 \times 2017$ chessboard such that every square is attacked by some queen? A square is attacked by a queen if it lies in the same row, column, or diagonal as the queen.
+(b) A $2017 \times 2017$ grid of squares originally contains a 0 in each square. At any step, Kelvin the Frog chooses two adjacent squares (two squares are adjacent if they share a side) and increments the numbers in both of them by 1. Can Kelvin make every square contain a different power of 2 ?
+(c) A tournament consists of single games between every pair of players, where each game has a winner and loser with no ties. A set of people is dominated if there exists a player who beats all of them. Does there exist a tournament in which every set of 2017 people is dominated?
+(d) Every cell of a $19 \times 19$ grid is colored either red, yellow, green, or blue. Does there necessarily exist a rectangle whose sides are parallel to the grid, all of whose vertices are the same color?
+(e) Does there exist a $c \in \mathbb{R}^{+}$such that $\max (|A \cdot A|,|A+A|) \geq c|A| \log ^{2}|A|$ for all finite sets $A \subset \mathbb{Z}$ ?
+(f) Can the set $\{1,2, \ldots, 1093\}$ be partitioned into 7 subsets such that each subset is sum-free (i.e. no subset contains $a, b, c$ with $a+b=c)$ ?
+
+Proposed by: Alexander Katz
+Answer: NNYYYY
+35. [20]
+(a) Does there exist a finite set of points, not all collinear, such that a line between any two points in the set passes through a third point in the set?
+(b) Let $A B C$ be a triangle and $P$ be a point. The isogonal conjugate of $P$ is the intersection of the reflection of line $A P$ over the $A$-angle bisector, the reflection of line $B P$ over the $B$-angle bisector, and the reflection of line $C P$ over the $C$-angle bisector. Clearly the incenter is its own isogonal conjugate. Does there exist another point that is its own isogonal conjugate?
+(c) Let $F$ be a convex figure in a plane, and let $P$ be the largest pentagon that can be inscribed in $F$. Is it necessarily true that the area of $P$ is at least $\frac{3}{4}$ the area of $F$ ?
+(d) Is it possible to cut an equilateral triangle into 2017 pieces, and rearrange the pieces into a square?
+(e) Let $A B C$ be an acute triangle and $P$ be a point in its interior. Let $D, E, F$ lie on $B C, C A, A B$ respectively so that $P D$ bisects $\angle B P C, P E$ bisects $\angle C P A$, and $P F$ bisects $\angle A P B$. Is it necessarily true that $A P+B P+C P \geq 2(P D+P E+P F)$ ?
+(f) Let $P_{2018}$ be the surface area of the 2018-dimensional unit sphere, and let $P_{2017}$ be the surface area of the 2017-dimensional unit sphere. Is $P_{2018}>P_{2017}$ ?
+
+Proposed by: Alexander Katz
+Answer: NYYYYN
+36. [20]
+(a) Does $\sum_{i=1}^{p-1} \frac{1}{i} \equiv 0\left(\bmod p^{2}\right)$ for all odd prime numbers $p$ ? (Note that $\frac{1}{i}$ denotes the number such that $\left.i \cdot \frac{1}{i} \equiv 1\left(\bmod p^{2}\right)\right)$
+(b) Do there exist 2017 positive perfect cubes that sum to a perfect cube?
+(c) Does there exist a right triangle with rational side lengths and area 5?
+(d) A magic square is a $3 \times 3$ grid of numbers, all of whose rows, columns, and major diagonals sum to the same value. Does there exist a magic square whose entries are all prime numbers?
+(e) Is $\prod_{p} \frac{p^{2}+1}{p^{2}-1}=\frac{2^{2}+1}{2^{2}-1} \cdot \frac{3^{2}+1}{3^{2}-1} \cdot \frac{5^{2}+1}{5^{2}-1} \cdot \frac{7^{2}+1}{7^{2}-1} \cdot \ldots$ a rational number?
+(f) Do there exist an infinite number of pairs of distinct integers $(a, b)$ such that $a$ and $b$ have the same set of prime divisors, and $a+1$ and $b+1$ also have the same set of prime divisors?
+
+Proposed by: Alexander Katz
+Answer: NYYYYY
+
diff --git a/HarvardMIT/md/en-202-2017-feb-team-solutions.md b/HarvardMIT/md/en-202-2017-feb-team-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..1d1562cb4f87df5bbb3a6af0278143d798727105
--- /dev/null
+++ b/HarvardMIT/md/en-202-2017-feb-team-solutions.md
@@ -0,0 +1,156 @@
+## February 2017
+
+## February 18, 2017
+
+Team
+
+1. [15] Let $P(x), Q(x)$ be nonconstant polynomials with real number coefficients. Prove that if
+
+$$
+\lfloor P(y)\rfloor=\lfloor Q(y)\rfloor
+$$
+
+for all real numbers $y$, then $P(x)=Q(x)$ for all real numbers $x$.
+Proposed by: Alexander Katz
+
+## Answer:
+
+By the condition, we know that $|P(x)-Q(x)| \leq 1$ for all $x$. This can only hold if $P(x)-Q(x)$ is a constant polynomial. Now take a constant $c$ such that $P(x)=Q(x)+c$. Without loss of generality, we can assume that $c \geq 0$. Assume that $c>0$. By continuity, if $\operatorname{deg} P=\operatorname{deg} Q>0$, we can select an integer $r$ and a real number $x_{0}$ such that $Q\left(x_{0}\right)+c=r$. Then $\left\lfloor P\left(x_{0}\right)\right\rfloor=\left\lfloor Q\left(x_{0}\right)+c\right\rfloor=r$. On the other hand, $\left\lfloor Q\left(x_{0}\right)\right\rfloor=\lfloor r-c\rfloor \sqrt{2}-1$, which leads to the $(20,21,29)$ triangle, $(5,13): \frac{5}{13} \approx .385<\sqrt{2}-1$, which leads to the $(65,72,97)$ triangle, and $(7,17): \frac{7}{17} \approx .411<\sqrt{2}-1$ which leads to the $(119,120,169)$ right triangle.
+19. [10] Suppose there are 100 cookies arranged in a circle, and 53 of them are chocolate chip, with the remainder being oatmeal. Pearl wants to choose a contiguous subsegment of exactly 67 cookies and wants this subsegment to have exactly $k$ chocolate chip cookies. Find the sum of the $k$ for which Pearl is guaranteed to succeed regardless of how the cookies are arranged.
+Proposed by: Alexander Wei
+Answer: 71
+We claim that the only values of $k$ are 35 and 36 .
+WLOG assume that the cookies are labelled 0 through 99 around the circle. Consider the following arrangement: cookies 0 through 17,34 through 50 , and 67 through 84 are chocolate chip, and the remaining are oatmeal. (The cookies form six alternating blocks around the circle of length $18,16,17,16,18,15$.) Consider the block of 33 cookies that are not chosen. It is not difficult to see that since the sum of the lengths of each two adjacent block is always at least 33 and at most 34 , this block of unchosen cookies always contains at least one complete block of cookies of the same type (and no other cookies of this type). So this block contains 17 or 18 or $33-16=17$ or $33-15=18$ chocolate chip cookies. Therefore, the block of 67 chosen cookies can only have $53-17=36$ or $53-18=35$ chocolate chip cookies.
+
+Now we show that 35 and 36 can always be obtained. Consider all possible ways to choose 67 cookies: cookies 0 through 66,1 through $67, \ldots, 99$ through 65 . It is not difficult to see that the number of chocolate chip cookies in the block changes by at most 1 as we advance from one way to the next.
+
+Moreover, each cookie will be chosen 67 times, so on average there will be $\frac{67.53}{100}=35.51$ chocolate chip cookies in each block. Since not all blocks are below average and not all blocks are above average, there must be a point where a block below average transition into a block above average. The difference of these two blocks is at most 1 , so one must be 35 and one must be 36 .
+Therefore, the sum of all possible values of $k$ is $35+36=71$.
+20. [10] Triangle $\triangle A B C$ has $A B=21, B C=55$, and $C A=56$. There are two points $P$ in the plane of $\triangle A B C$ for which $\angle B A P=\angle C A P$ and $\angle B P C=90^{\circ}$. Find the distance between them.
+Proposed by: Michael Tang
+Answer: $\frac{5}{2} \sqrt{409}$
+Let $P_{1}$ and $P_{2}$ be the two possible points $P$, with $A P_{1}\binom{10}{2}-23=22$ when $n \geq 7$, so there cannot be any graph in this case.
+Case 2: $n=6$. WLOG suppose that 1 is connected to $2,3,4,5,6,7$, then none of $2,3,4,5,6,7$ can connect to each other.
+Case 2.1: There is at least one edge between $8,9,10$, then each of $2,3,4,5,6,7$ can connect to at most two of $8,9,10$, for at most $6 \cdot 2+\binom{3}{2}=15$ additional edges. Along with the 6 original edges, it is not enough to each 23 edges.
+Case 2.2: There are no edges between $8,9,10$, then this graph is a bipartite graph between $1,8,9,10$ and $2,3,4,5,6,7$. There can be at most $4 \cdot 6=24$ edges in this graph, so exactly one edge is removed from this graph. There are $\binom{10}{4} \cdot 24=5040$ possible graphs in this case.
+Case 3: $n=5$. WLOG suppose that 1 is connected to $2,3,4,5,6$, then none of $2,3,4,5,6$ can connect to each other.
+
+Case 3.1: There is at least one edge between $7,8,9,10$. Then each of $2,3,4,5,6$ can connect to at most three of $7,8,9,10$, for $5 \cdot 3=15$ edges. In this case at least three of $7,8,9,10$ must not be connected to each other, so there can be at most three edges, for $5+15+3=23$ edges at most. However, this requires the three disconnected vertices of $7,8,9,10$ to be connected to all of $2,3,4,5,6$ and the other
+vertex of $7,8,9,10$, causing them to have degree 6 . We can therefore ignore this case. (The case where $2,3,4,5,6$ can connect to two or less of $7,8,9,10$ can be easily ruled out.)
+
+Case 3.2: There are no edges between $7,8,9,10$, then this graph is a bipartite graph between $1,7,8,9,10$ and $2,3,4,5,6$. This is a $K_{5,5}$ with two edges removed, which accounts for $\binom{10}{5} / 2 \cdot\binom{25}{2}=126 \cdot 300=$ 37800 graphs.
+It is not difficult to see that Case 2.2 and Case 3.2 are disjoint (by considering max degree), so there are $5040+37800=42840$ graphs in total.
+23. [12] Kevin starts with the vectors $(1,0)$ and $(0,1)$ and at each time step, he replaces one of the vectors with their sum. Find the cotangent of the minimum possible angle between the vectors after 8 time steps.
+
+## Proposed by: Allen Liu
+
+Answer: 987
+Say that the vectors Kevin has at some step are $(a, b)$ and $(c, d)$. Notice that regardless of which vector he replaces with $(a+c, b+d)$, the area of the triangle with vertices $(0,0),(a, b)$, and $(c, d)$ is preserved with the new coordinates. We can see this geometrically: the parallelogram with vertices $(0,0),(a, b)$, $(c, d)$, and $(a+c, b+d)$ can be cut in half by looking at the triangle formed by any 3 of the vertices, which include the original triangle, and both possible triangles that might arise in the next step.
+Because the area is preserved, the minimum possible angle then arises when the two vectors, our sides, are as long as possible. This occurs when we alternate which vector is getting replaced for the sum. Given two vectors $(a, b)$ and $(c, d)$, with $\sqrt{a^{2}+b^{2}}>\sqrt{c^{2}+d^{2}}$, we would rather replace $(c, d)$ than $(a, b)$, and $(a+c, b+d)$ has a larger norm than $(a, b)$. Then at the $n$th step, Kevin has the vectors $\left(F_{n}, F_{n-1}\right)$ and $\left(F_{n+1}, F_{n}\right)$, where $F_{0}=0$ and $F_{1}=1$. The tangent of the angle between them is the tangent of the difference of the angles they make with the x-axis, which is just their slope. We can then compute the cotangent as
+
+$$
+\left|\frac{1+\frac{F_{n-1}}{F_{n}} \cdot \frac{F_{n}}{F_{n+1}}}{\frac{F_{n}}{F_{n+1}}-\frac{F_{n-1}}{F_{n}}}\right|=\left|\frac{F_{n}\left(F_{n+1}+F_{n-1}\right)}{F_{n}^{2}-F_{n-1} F_{n+1}}\right| .
+$$
+
+We can show (by induction) that $F_{n}\left(F_{n+1}+F_{n-1}\right)=F_{2 n}$ and $F_{n}^{2}-F_{n-1} F_{n+1}=(-1)^{n+1}$. Thus at the 8th step, the cotangent of the angle is $F_{16}=987$.
+24. [12] Find the largest positive integer $n$ for which there exist $n$ finite sets $X_{1}, X_{2}, \ldots, X_{n}$ with the property that for every $1 \leq a0$ earns $\lfloor 20 \min (N / E, E / N)\rfloor$ points.
+Proposed by: Yuan Yao
+Answer: 15600
+36. [20] In the game of Connect Four, there are seven vertical columns which have spaces for six tokens. These form a $7 \times 6$ grid of spaces. Two players White and Black move alternately. A player takes a turn by picking a column which is not already full and dropping a token of their color into the lowest unoccupied space in that column. The game ends when there are four consecutive tokens of the same color in a line, either horizontally, vertically, or diagonally. The player who has four tokens in a row of their color wins.
+Assume two players play this game randomly. Each player, on their turn, picks a random column which is not full and drops a token of their color into that column. This happens until one player wins or all of the columns are filled. Let $P$ be the probability that all of the columns are filled without any player obtaining four tokens in a row of their color. Estimate $P$.
+An estimate of $E>0$ earns $\lfloor 20 \min (P / E, E / P)\rfloor$ points.
+Proposed by: Allen Liu
+Answer: 0.0025632817
diff --git a/HarvardMIT/md/en-212-2018-feb-team-solutions.md b/HarvardMIT/md/en-212-2018-feb-team-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..16ade990d54e040ca4189c825dff282aabaf4aa5
--- /dev/null
+++ b/HarvardMIT/md/en-212-2018-feb-team-solutions.md
@@ -0,0 +1,136 @@
+## HMMT February 2018 1$. We look at the $x^{k p-1}$ coefficient, which is affected only by the $f_{k} g(x)^{k}$ term. By expanding, the coefficient is $k f_{k} g_{p}^{k-1} g_{p-1}$. Therefore $g_{p-1}=0$. Then we look at the $x^{k p-2}$ coefficient, then the $x^{k p-3}$ coefficient, etc. down to the $x^{k p-p+1}$ coefficient to conclude that $g_{p-1}=g_{p-2}=\cdots=g_{1}=0$. However, then the $x$ coefficient of $f(g(x))$ is zero, contradiction.
+Therefore we must have $k=1$, so $f$ is of the form $a x^{p}+b x+c$. Using the same method as we used when $k>1$, we get $g_{p-1}=g_{p-2}=\cdots g_{2}=0$, though the $x^{k p-p+1}$ coefficient is now the $x$ coefficient which we want to be nonzero. Hence we do not obtain $g_{1}=0$ anymore and we find that $g$ is of the form $d x^{p}+e x+f$.
+10. [60] Prove that for all positive integers $n$, all complex roots $r$ of the polynomial
+
+$$
+P(x)=(2 n) x^{2 n}+(2 n-1) x^{2 n-1}+\cdots+(n+1) x^{n+1}+n x^{n}+(n+1) x^{n-1}+\cdots+(2 n-1) x+2 n
+$$
+
+lie on the unit circle (i.e. $|r|=1$ ).
+Proposed by: Faraz Masroor
+Note that neither 0 nor 1 are roots of the polynomial. Consider the function
+$Q(x)=P(x) / x^{n}=(2 n) x^{n}+(2 n) x^{-n}+(2 n-1) x^{n-1}+(2 n-1) x^{-n+1}+\cdots+(n+1) x^{1}+(n+1) x^{-1}+n$.
+All $2 n$ of the complex roots of $P(x)$ will be roots of $Q(x)$.
+If $|x|=1$, then $x=e^{i \theta}$, and
+
+$$
+\begin{aligned}
+Q(x) & =(2 n)\left(x^{n}+x^{-n}\right)+(2 n-1)\left(x^{n-1}+x^{-n+1}\right)+\cdots+(n+1)\left(x+x^{-1}\right)+n \\
+& =(2 n)\left(e^{i n \theta}+e^{-i n \theta}\right)+(2 n-1)\left(e^{i(n-1) \theta}+e^{-i(n-1) \theta}\right)+\cdots+(n+1)\left(e^{i \theta}+e^{-i \theta}\right)+n \\
+& =(2 n)(2 \cos (n \theta))+(2 n-1)(2 \cos ((n-1) \theta))+\cdots+(n+1)(\cos (\theta))+n
+\end{aligned}
+$$
+
+which is real. Thus on the unit circle, we have $Q(x)$ is real, and we want to show it has $2 n$ roots there. Rewrite
+
+$$
+\begin{aligned}
+P(x) & =(2 n) x^{2 n}+(2 n-1) x^{2 n-1}+\cdots+(n+1) x^{n+1}+n x^{n}+(n+1) x^{n-1}+\cdots+2 n \\
+& =(2 n)\left(x^{2 n}+x^{2 n-1}+\cdots+1\right) \\
+& \quad-\left(x^{2 n-1}+2 x^{2 n-2}+\cdots+(n-1) x^{n}+n x^{n-1}+(n-1) x^{n-2}+\cdots+2 x^{2}+x\right) \\
+& =2 n \frac{x^{2 n+1}-1}{x-1}-x\left(x^{2 n-2}+2 x^{2 n-3}+\cdots+(n-1) x^{n}+n x^{n-1}+(n-1) x^{n-2}+\cdots+2 x+1\right) \\
+& =2 n \frac{x^{2 n+1}-1}{x-1}-x\left(x^{n-1}+x^{n-2}+\cdots+x+1\right)^{2} \\
+& =2 n \frac{x^{2 n+1}-1}{x-1}-x\left(\frac{x^{n}-1}{x-1}\right)^{2}
+\end{aligned}
+$$
+
+and thus
+
+$$
+Q(x)=\frac{2 n}{x^{n}} \frac{x^{2 n+1}-1}{x-1}-\frac{x}{x^{n}}\left(\frac{x^{n}-1}{x-1}\right)^{2}
+$$
+
+Consider the roots of unity $r_{j}=e^{i \frac{2 \pi}{2 n} j}$, for $j=0$ to $2 n-1$. There are $2 n$ such roots of unity: they all have $r_{j}^{2 n}=1$, and they alternate between those which satisfy $r_{j}^{n}=1$ or $r_{j}^{n}=-1$. At those $x=r_{j}$, if
+$r_{j}^{n}=1$ but $x \neq 1$, then
+
+$$
+\begin{aligned}
+Q(x) & =\frac{2 n}{x^{n}} \frac{x^{2 n+1}-1}{x-1}-\frac{x}{x^{n}}\left(\frac{x^{n}-1}{x-1}\right)^{2} \\
+& =2 n \frac{x^{1}-1}{x-1}-x\left(\frac{1-1}{x-1}\right)^{2}=2 n>0
+\end{aligned}
+$$
+
+At $x=1$, we can easily see $Q(1)>0$.
+If $r_{j}^{n}=-1$, then
+
+$$
+\begin{aligned}
+Q(x) & =\frac{2 n}{x^{n}} \frac{x^{2 n+1}-1}{x-1}-\frac{x}{x^{n}}\left(\frac{x^{n}-1}{x-1}\right)^{2} \\
+& =-2 n \frac{x^{1}-1}{x-1}+x\left(\frac{-1-1}{x-1}\right)^{2} \\
+& =-2 n+\frac{4 x}{(x-1)^{2}} \\
+& =-2 n+\frac{4}{x-2+1 / x} \\
+& =-2 n+\frac{4}{2 \cos \left(\frac{2 \pi}{2 n} j\right)-2}<-2 n-4<0
+\end{aligned}
+$$
+
+since the denominator of this second term is strictly negative $(j \neq 0)$.
+Thus at each of the $2 n$-roots of unity, $Q(x)$ alternates in sign, and because $Q(x)$ is real and continuous on the unit circle, it has at least one root between every pair of consecutive roots of unity. Since there are $2 n$ of these pairs, and we know that $Q(x)$ has exactly $2 n$ roots (by the Fundamental Theorem of Algebra), we have found all of $Q$ 's roots, and therefore those of $P$.
+
diff --git a/HarvardMIT/md/en-224-tournaments-2019-hmic-solutions.md b/HarvardMIT/md/en-224-tournaments-2019-hmic-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..cf784d7cd524a079529dd93057e9f68286d053f4
--- /dev/null
+++ b/HarvardMIT/md/en-224-tournaments-2019-hmic-solutions.md
@@ -0,0 +1,142 @@
+## HMIC 2019
+
+## March 30, 2019 - April 5, 2019
+
+1. [5] Let $A B C$ be an acute scalene triangle with incenter $I$. Show that the circumcircle of $B I C$ intersects the Euler line of $A B C$ in two distinct points.
+(Recall that the Euler line of a scalene triangle is the line that passes through its circumcenter, centroid, orthocenter, and the nine-point center.)
+Proposed by: Andrew Gu
+Let $O$ and $H$ be the circumcenter and orthocenter of $A B C$. Recall that
+
+$$
+\begin{aligned}
+\angle B O C & =2 \angle A, \\
+\angle B H C & =180^{\circ}-\angle A, \\
+\angle B I C & =90^{\circ}+\frac{1}{2} \angle A .
+\end{aligned}
+$$
+
+As $A B C$ is acute, $A, I, O, H$ all lie on the same side of $B C$.
+
+- If $\angle A>60^{\circ}$, then $\angle B O C>\angle B I C$, so $O$ lies inside ( $B I C$ ).
+- If $\angle A<60^{\circ}$, then $\angle B H C>\angle B I C$, so $H$ lies inside ( $B I C$ ).
+- If $\angle A=60^{\circ}$, then $O$ and $H$ are on (BIC).
+
+In all cases, two intersections are guaranteed.
+Note: For an obtuse triangle, the statement is not necessarily true.
+2. [7] Annie has a permutation $\left(a_{1}, a_{2}, \ldots, a_{2019}\right)$ of $S=\{1,2, \ldots, 2019\}$, and Yannick wants to guess her permutation. With each guess Yannick gives Annie an $n$-tuple ( $y_{1}, y_{2}, \ldots, y_{2019}$ ) of integers in $S$, and then Annie gives the number of indices $i \in S$ such that $a_{i}=y_{i}$.
+(a) Show that Yannick can always guess Annie's permutation with at most 1200000 guesses.
+(b) Show that Yannick can always guess Annie's permutation with at most 24000 guesses.
+
+Proposed by: Yuan Yao
+Part (a) uses the idea that for $x \neq y$, the guess $(x, y, y, \ldots, y)$ returns 0 if the first number is $y, 2$ if the first number is $x$, and 1 if the number is something else. If he tests the pairs $(x, y)=(1,2), \ldots,(2017,2018)$, he will get a 0 or 2 (and therefore find out what the first number is) or get only 1 (so the first number is 2019). In general, with $n$ numbers unknown, Yannick needs $\left\lfloor\frac{n}{2}\right\rfloor$ guesses to find out the next number in the permutation. Using this strategy, he can guess the permutation within at most
+
+$$
+\sum_{n=1}^{2019}\left\lfloor\frac{n}{2}\right\rfloor+1=1009 \cdot 1010+1=1019091
+$$
+
+guesses.
+Part (b) uses the idea that after the first number has been determined and $n$ numbers remain undetermined, it takes $\left\lceil\log _{2} n\right\rceil$ guesses to determine the index of another number, by doing a binary search to halve the candidate positions each time (using the first number as a filler). Using this Yannick can guess the permutation within
+
+$$
+1009+\sum_{n=1}^{2018}\left\lceil\log _{2} n\right\rceil+1=1009+1 \cdot 1+2 \cdot 2+4 \cdot 3+\cdots+512 \cdot 10+994 \cdot 11+1=21161
+$$
+
+guesses.
+3. [8] Do there exist four points $P_{i}=\left(x_{i}, y_{i}\right) \in \mathbb{R}^{2}(1 \leq i \leq 4)$ on the plane such that:
+
+- for all $i=1,2,3,4$, the inequality $x_{i}^{4}+y_{i}^{4} \leq x_{i}^{3}+y_{i}^{3}$ holds, and
+- for all $i \neq j$, the distance between $P_{i}$ and $P_{j}$ is greater than 1?
+
+Proposed by: Pakawut Jiradilok
+In fact, there are! One might think that the region
+
+$$
+\left\{(x, y) \in \mathbb{R}^{2} \mid x^{4}+y^{4} \leq x^{3}+y^{3}\right\}
+$$
+
+is inside the ball defined by $x^{2}+y^{2} \leq x+y$, which is a ball of radius $1 / \sqrt{2}$. It turns out that it is not the case.
+We claim that for all $\epsilon>0$ small enough, we can choose $(0,0),(1,1),\left(1-\epsilon^{2},-2 \epsilon\right)$, and $\left(-2 \epsilon, 1-\epsilon^{2}\right)$. First we check the condition $x_{i}^{4}+y_{i}^{4} \leq x_{i}^{3}+y_{i}^{3}$. This is obviously satisfied for the first two points, and for the other two points this translates to
+
+$$
+\begin{aligned}
+\left(1-\epsilon^{2}\right)^{4}+(-2 \epsilon)^{4} & \leq\left(1-\epsilon^{2}\right)^{3}+(-2 \epsilon)^{3} \\
+(2 \epsilon)^{3}(1+2 \epsilon) & \leq\left(1-\epsilon^{2}\right)^{3}\left(\epsilon^{2}\right) \\
+8 \epsilon(1+2 \epsilon) & \leq\left(1-\epsilon^{2}\right)^{3} .
+\end{aligned}
+$$
+
+This is satisfied for small $\epsilon$. Next we check that the distances are greater than 1. Clearly the third and fourth points are at distance greater than 1 from $(1,1)$ as they have negative $y$ and $x$ coordinates respectively. They are also at distance greater than 1 from each other for small $\epsilon$ as their distance tends to $\sqrt{2}$ as $\epsilon \rightarrow 0$. Also, $(0,0)$ and $(1,1)$ are at distance greater than 1 as well. The only remaining distances to check are the distance from the first point to the third and fourth points (which are the same distance). This distance is
+
+$$
+\sqrt{\left(1-\epsilon^{2}\right)^{2}+(-2 \epsilon)^{2}}=\sqrt{\left(1+\epsilon^{2}\right)^{2}}=1+\epsilon^{2}>0
+$$
+
+so all conditions are satisfied (for sufficiently small $\epsilon$ ).
+For example, one may choose $\epsilon=1 / 20$ to obtain the four points $(0,0),(1,1),\left(-\frac{1}{10}, \frac{399}{400}\right)$ and $\left(\frac{399}{400},-\frac{1}{10}\right)$.
+4. [10] A cactus is a finite simple connected graph where no two cycles share an edge. Show that in a nonempty cactus, there must exist a vertex which is part of at most one cycle.
+
+## Proposed by: Kevin Yang
+
+Let $C$ be the original cactus. For every cycle in $C$, arbitrarily remove one of its edges, yielding a new graph $T$. Observe that since the cycles are edge-disjoint, we removed exactly one edge from every cycle, meaning the graph stays connected. However, there are no longer any cycles, so $T$ is a tree.
+Now consider any leaf $v$ of $T$ (note that any nonempty tree must have a leaf). If $v$ is the only vertex in the graph we're trivially done, since then $v$ was the only vertex in $C$. Otherwise $v$ has degree 1 . If $v$ was originally a leaf of $C$, we're done. If not, observe that in the process of turning $C$ into $T$, a vertex's degree cannot decrease by more than half, because for every cycle that a vertex is part of in $C$, it gains a degree of 2 , but can only lose 1 degree from an edge of that cycle being removed. Therefore, the original degree of $v$ in $C$ was at most 2 , meaning it could have been part of at most 1 cycle, as desired.
+Remark. The problem originally did not state that the graph is finite. We apologize for the omission.
+5. [12] Let $p=2017$ be a prime and $\mathbb{F}_{p}$ be the integers modulo $p$. A function $f: \mathbb{Z} \rightarrow \mathbb{F}_{p}$ is called good if there is $\alpha \in \mathbb{F}_{p}$ with $\alpha \not \equiv 0(\bmod p)$ such that
+
+$$
+f(x) f(y)=f(x+y)+\alpha^{y} f(x-y) \quad(\bmod p)
+$$
+
+for all $x, y \in \mathbb{Z}$. How many good functions are there that are periodic with minimal period 2016 ?
+Proposed by: Ashwin Sah
+Answer: 1327392
+
+We will classify all good functions with parameter $\alpha \in \mathbb{F}_{p} \backslash\{0\}$. We will use $=$ to denote equality modulo $p$ when appropriate. Let the given statement be $P(x, y)$. Then $P(x, 0)$ gives $f(x) f(0)=2 f(x)$ for all $x \in \mathbb{Z}$. $f$ cannot be the zero function because it does not have minimal period 2016. Therefore $f(0)=2$.
+$P(x, 1)$ gives $f(x+1)-f(1) f(x)+\alpha f(x-1)=0$. This means that $f$ satisfies a recurrence of depth two.
+We can interpret $f$ as a function $f: \mathbb{Z} \rightarrow \mathbb{F}_{p^{2}}$, embedding the codomain $\mathbb{F}_{p}$ inside of $\mathbb{F}_{p^{2}}$. Let $\tau, \rho$ be the unique roots of $t^{2}-f(1) t+\alpha=0$ in $\mathbb{F}_{p^{2}}$, so that $\tau+\rho=f(1), \tau \rho=\alpha$. Since $\alpha$ is nonzero, so are $\tau$ and $\rho$. Notice that $f(0)=\tau^{0}+\rho^{0}$ and $f(1)=\tau^{1}+\rho^{1}$. By induction up and down, we see that $f(n)=\tau^{n}+\rho^{n}$ for all $n \in \mathbb{Z}$.
+We can also easily check that given any value of $f(1)$ and $\alpha$ with $\alpha \not \equiv 0(\bmod p)$, we get a unique such function. Thus there are $p(p-1)$ total such functions, one corresponding to each quadratic $t^{2}-a t+b$, where $b \neq 0$. If $\tau, \rho$ are the roots of the quadratic, the associated function is $f(n)=\tau^{n}+\rho^{n}$.
+Now if $f$ is $q$-periodic then $f(n)=f(n+q)$ for all $n \in \mathbb{Z}$, so $\tau^{n}+\rho^{n}=\tau^{n+q}+\rho^{n+q}$ for all $n \in \mathbb{Z}$ so
+
+$$
+\tau^{n}\left(1-\tau^{q}\right)=\rho^{n}\left(\rho^{q}-1\right)
+$$
+
+We have two cases.
+
+Case 1. $\tau \neq \rho$.
+Then $n=0$ and $n=1$ above give $1=\tau^{q}=\rho^{q}$, and this is furthermore sufficient to be $q$-periodic. Thus the period of $f$ is the minimal $q$ such that $\tau^{q}=\rho^{q}=1$, so the lcm of the orders of $\tau, \rho$ as elements of $\mathbb{F}_{p^{2}}$.
+
+Case 2. $\tau=\rho$.
+Then we see that $\tau=\rho=\frac{f(1)}{2}$, so they are in $\mathbb{F}_{p}$. This automatically means that $f(n)=2\left(\frac{f(1)}{2}\right)^{n}$ for all $n \in \mathbb{Z}$, where $f(1) \neq 0$ is forced (as $\tau \rho=\alpha$ ). This has period dividing $p-1$. More specifically, the period is the order of $\frac{f(1)}{2}$ as an element of $\mathbb{F}_{p}$.
+
+In the first case, note that the orders of $\tau, \rho$ dividing $p-1$ implies that $\tau, \rho$ are actually in $\mathbb{F}_{p}$, so that we can restrict to counting recurrences $f(n)=a^{n}+b^{n}$ where $a, b$ are nonzero elements of $\mathbb{F}_{p}$.
+The unordered pair $\{a, b\}$ determines $a+b=f(1)$ and $a b=\alpha$, so it determines a unique $f$ by our earlier observation. We need to count the number of such pairs with $\operatorname{lcm}\left(\operatorname{ord}_{p}(a), \operatorname{ord}_{p}(b)\right)=p-1$.
+Recall that for $d \mid p-1$, there are $\phi(d)$ elements of order $d$ in $\mathbb{F}_{p}^{\times}$. If $a=b$ we need $\operatorname{ord}_{p}(a)=p-1$, so there are $\phi(p-1)$ functions. If $S$ is the number of ordered pairs $(a, b)$ with $\operatorname{lcm}\left(\operatorname{ord}_{p}(a), \operatorname{ord}_{p}(b)\right)=p-1$, then we see that the desired count is $\frac{\phi(p-1)+S}{2}$ (as each unordered pair $\{a, b\}$ is counted twice as and ordered pair except for those with $a=b$ ).
+Now let $n=p-1$. We are counting pairs with the lcm equal to $n$. The number of pairs with respective orders $d_{1}, d_{2}$ is $\phi\left(d_{1}\right) \phi\left(d_{2}\right)$ hence our desired sum is $\sum_{d_{1}, d_{2} \mid n, l \mathrm{~cm}\left(d_{1}, d_{2}\right)=n} \phi\left(d_{1}\right) \phi\left(d_{2}\right)$. Now notice that $\phi$ is a multiplicative function, and the condition on the sum splits among the prime powers dividing $n$, so we can choose how $d_{1}, d_{2}$ behave on the prime factors of $n$ independently. Therefore if we define
+
+$$
+\chi(n)=\sum_{d_{1}, d_{2} \mid n, \operatorname{lcm}\left(d_{1}, d_{2}\right)=n} \phi\left(d_{1}\right) \phi\left(d_{2}\right)
+$$
+
+then $\chi$ is multiplicative. Finally, if $q$ is prime and $e \geq 1$ we have
+
+$$
+\begin{aligned}
+\chi\left(q^{e}\right) & =\sum_{d_{1}, d_{2} \mid q^{e}, \operatorname{lcm}\left(d_{1}, d_{2}\right)=q^{e}} \phi\left(d_{1}\right) \phi\left(d_{2}\right) \\
+& =2 \phi\left(q^{e}\right)\left(\phi(1)+\phi(q)+\cdots+\phi\left(q^{e-1}\right)\right)+\phi\left(q^{e}\right)^{2} \\
+& =2 q^{e-1}(q-1) q^{e-1}+q^{2 e-2}(q-1)^{2} \\
+& =q^{2 e-2}\left(q^{2}-1\right)=q^{2 e}\left(1-\frac{1}{q^{2}}\right)
+\end{aligned}
+$$
+
+This implies that $\chi(n)=n^{2} \prod_{q \mid n}\left(1-\frac{1}{q^{2}}\right)$ by multiplicativity. Finally, our original answer is
+
+$$
+\frac{\phi(p-1)+(p-1)^{2} \prod_{q \mid p-1}\left(1-\frac{1}{q^{2}}\right)}{2}
+$$
+
+which we now compute for $p=2017$. We have $p-1=2016=2^{5} \cdot 3^{2} \cdot 7$. Thus $\phi(p-1)=2^{4} \cdot 2 \cdot 3 \cdot 6=576$ and $\prod_{q \mid 2016}\left(1-\frac{1}{q^{2}}\right)=\frac{3}{4} \cdot \frac{8}{9} \cdot \frac{48}{49}=\frac{32}{49}$. Thus the number of functions is
+
+$$
+\frac{576+\frac{32}{49} \cdot 2016^{2}}{2}=\frac{576+2^{15} \cdot 3^{4}}{2}=288+2^{14} \cdot 3^{4}=1327392
+$$
+
diff --git a/HarvardMIT/md/en-231-2019-nov-gen-solutions.md b/HarvardMIT/md/en-231-2019-nov-gen-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..c7ca2f1eb163710728bcb5d38723804e797c1b07
--- /dev/null
+++ b/HarvardMIT/md/en-231-2019-nov-gen-solutions.md
@@ -0,0 +1,112 @@
+## HMMT November 2019
+
+## November 9, 2019
+
+## General Round
+
+1. Dylan has a $100 \times 100$ square, and wants to cut it into pieces of area at least 1 . Each cut must be a straight line (not a line segment) and must intersect the interior of the square. What is the largest number of cuts he can make?
+
+Proposed by: Carl Schildkraut
+Answer: 9999
+Since each piece has area at least 1 and the original square has area 10000, Dylan can end up with at most 10000 pieces. There is initially 1 piece, so the number of pieces can increase by at most 9999 . Each cut increases the number of pieces by at least 1, so Dylan can make at most 9999 cuts. Notice that this is achievable if Dylan makes 9999 vertical cuts spaced at increments of $\frac{1}{100}$ units.
+2. Meghana writes two (not necessarily distinct) primes $q$ and $r$ in base 10 next to each other on a blackboard, resulting in the concatenation of $q$ and $r$ (for example, if $q=13$ and $r=5$, the number on the blackboard is now 135). She notices that three more than the resulting number is the square of a prime $p$. Find all possible values of $p$.
+Proposed by: Carl Schildkraut
+Answer: 5
+Trying $p=2$, we see that $p^{2}-3=1$ is not the concatenation of two primes, so $p$ must be odd. Then $p^{2}-3$ is even. Since $r$ is prime and determines the units digit of the concatenation of $q$ and $r, r$ must be 2. Then $p^{2}$ will have units digit 5 , which means that $p$ will have units digit 5 . Since $p$ is prime, we find that $p$ can only be 5 , and in this case, $p^{2}-3=22$ allows us to set $q=r=2$ to satisfy the problem statement. So there is a valid solution when $p=5$, and this is the only possibility.
+3. Katie has a fair 2019-sided die with sides labeled $1,2, \ldots, 2019$. After each roll, she replaces her $n$-sided die with an $(n+1)$-sided die having the $n$ sides of her previous die and an additional side with the number she just rolled. What is the probability that Katie's $2019^{\text {th }}$ roll is a 2019 ?
+Proposed by: Freddie Zhao
+Answer: $\frac{1}{2019}$
+Since Katie's original die is fair, the problem is perfectly symmetric. So on the 2019th roll, each number is equally probable as any other. Therefore, the probability of rolling a 2019 is just $\frac{1}{2019}$.
+4. In $\triangle A B C, A B=2019, B C=2020$, and $C A=2021$. Yannick draws three regular $n$-gons in the plane of $\triangle A B C$ so that each $n$-gon shares a side with a distinct side of $\triangle A B C$ and no two of the $n$-gons overlap. What is the maximum possible value of $n$ ?
+Proposed by: Carl Schildkraut
+Answer: 11
+If any $n$-gon is drawn on the same side of one side of $\triangle A B C$ as $\triangle A B C$ itself, it will necessarily overlap with another triangle whenever $n>3$. Thus either $n=3$ or the triangles are all outside $A B C$. The interior angle of a regular $n$-gon is $180^{\circ} \cdot \frac{n-2}{n}$, so we require
+
+$$
+360^{\circ} \cdot \frac{n-2}{n}+\max (\angle A, \angle B, \angle C)<360^{\circ} .
+$$
+
+As $\triangle A B C$ is almost equilateral (in fact the largest angle is less than $60.1^{\circ}$ ), each angle is approximately $60^{\circ}$, so we require
+
+$$
+360 \cdot \frac{n-2}{n}<300 \Longrightarrow n<12
+$$
+
+Hence the answer is $n=11$.
+5. Let $a, b, c$ be positive real numbers such that $a \leq b \leq c \leq 2 a$. Find the maximum possible value of
+
+$$
+\frac{b}{a}+\frac{c}{b}+\frac{a}{c}
+$$
+
+Proposed by: Carl Schildkraut
+Answer: $\frac{7}{2}$
+Fix the values of $b, c$. By inspecting the graph of
+
+$$
+f(x)=\frac{b}{x}+\frac{x}{c}
+$$
+
+we see that on any interval the graph attains its maximum at an endpoint. This argument applies when we fix any two variables, so it suffices to check boundary cases in which $b=a$ or $b=c$, and $c=b$ or $c=2 a$. All pairs of these conditions determine the ratio between $a, b, c$, except $b=c$ and $c=b$, in which case the boundary condition on $a$ tells us that $a=b$ or $2 a=b=c$. In summary, these cases are
+
+$$
+(a, b, c) \in\{(a, a, a),(a, a, 2 a),(a, 2 a, 2 a)\}
+$$
+
+The largest value achieved from any of these three is $\frac{7}{2}$.
+6. Find all ordered pairs $(a, b)$ of positive integers such that $2 a+1$ divides $3 b-1$ and $2 b+1$ divides $3 a-1$.
+
+Proposed by: Milan Haiman
+Answer: $(2,2),(12,17),(17,12)$
+This is equivalent to the existence of nonnegative integers $c$ and $d$ such that $3 b-1=c(2 a+1)$ and $3 a-1=d(2 b+1)$. Then
+
+$$
+c d=\frac{(3 b-1)(3 a-1)}{(2 a+1)(2 b+1)}=\frac{3 a-1}{2 a+1} \cdot \frac{3 b-1}{2 b+1}<\frac{3}{2} \cdot \frac{3}{2}=2.25 .
+$$
+
+Neither $c$ nor $d$ can equal 0 since that would give $a=\frac{1}{3}$ or $b=\frac{1}{3}$, so $c d \leq 2.25$ implies $(c, d) \in$ $\{(1,1),(2,1),(1,2)\}$. Substituting $(c, d)$ back in gives three systems of equations and the three solutions: $(2,2),(12,17),(17,12)$.
+7. In Middle-Earth, nine cities form a 3 by 3 grid. The top left city is the capital of Gondor and the bottom right city is the capital of Mordor. How many ways can the remaining cities be divided among the two nations such that all cities in a country can be reached from its capital via the grid-lines without passing through a city of the other country?
+Proposed by: Shengtong Zhang
+Answer: 30
+For convenience, we will center the grid on the origin of the coordinate plane and align the outer corners of the grid with the points $( \pm 1, \pm 1)$, so that $(-1,1)$ is the capital of Gondor and $(1,-1)$ is the capital of Mordor.
+We will use casework on which nation the city at $(0,0)$ is part of. Assume that is belongs to Gondor. Then consider the sequence of cities at $(1,0),(1,1),(0,1)$. If one of these belongs to Mordor, then all of the previous cities belong to Mordor, since Mordor must be connected. So we have 4 choices for which cities belong to Mordor. Note that this also makes all the other cities in the sequence connected to Gondor. Similarly, we have 4 (independent) choices for the sequence of cities $(0,-1),(-1-1),(-1,0)$. All of these choices keep $(0,0)$ connected to Gondor except the choice that assigns all cities in both sequences to Mordor. Putting this together, the answer is $2(4 \cdot 4-1)=30$.
+8. Compute the number of ordered pairs of integers $(x, y)$ such that $x^{2}+y^{2}<2019$ and
+
+$$
+x^{2}+\min (x, y)=y^{2}+\max (x, y)
+$$
+
+Proposed by: Milan Haiman
+Answer: 127
+We have
+
+$$
+x^{2}-y^{2}=\max (x, y)-\min (x, y)=|x-y|
+$$
+
+Now if $x \neq y$, we can divide by $x-y$ to obtain $x+y= \pm 1$. Thus $x=y$ or $x+y= \pm 1$.
+If $x=y$, we see that $2019>x^{2}+y^{2}=2 x^{2}$, so we see that $-31 \leq x \leq 31$. There are 63 ordered pairs in this case.
+In the second case, note that $|x| \geq|y|$ since $x^{2}-y^{2}=|x-y| \geq 0$. Since $x+y= \pm 1$, we cannot have $x y>0$, so either $x \geq 0, y \leq 0$, or $x \leq 0, y \geq 0$. In the first case, $x+y=1$; in the second case, $x+y=-1$. Thus, the solutions for $(x, y)$ are of the form $(k, 1-k)$ or $(-k, k-1)$ for some $k>0$. In either case, we must have $k^{2}+(k-1)^{2}<2019$, which holds true for any $1 \leq k \leq 32$ but fails for $k=33$. There are a total of $32 \cdot 2=64$ solutions in this case.
+In summary, there are a total of $63+64=127$ integer solutions to the equation $x^{2}+\min (x, y)=$ $y^{2}+\max (x, y)$ with $x^{2}+y^{2}<2019$.
+9. Let $A B C D$ be an isosceles trapezoid with $A D=B C=255$ and $A B=128$. Let $M$ be the midpoint of $C D$ and let $N$ be the foot of the perpendicular from $A$ to $C D$. If $\angle M B C=90^{\circ}$, compute $\tan \angle N B M$.
+Proposed by: Milan Haiman
+Answer: $\frac{120}{353}$
+Construct $P$, the reflection of $A$ over $C D$. Note that $P, M$, and $B$ are collinear. As $\angle P N C=\angle P B C=$ $90^{\circ}, P N B C$ is cyclic. Thus, $\angle N B M=\angle N C P$, so our desired tangent is $\tan \angle A C N=\frac{A N}{C N}$. Note that $N M=\frac{1}{2} A B=64$. Since $\triangle A N D \sim \triangle M A D$,
+
+$$
+\frac{255}{64+N D}=\frac{N D}{255}
+$$
+
+Solving, we find $N D=225$, which gives $A N=120$. Then we calculate $\frac{A N}{C N}=\frac{120}{128+225}=\frac{120}{353}$.
+10. An up-right path between two lattice points $P$ and $Q$ is a path from $P$ to $Q$ that takes steps of 1 unit either up or to the right. A lattice point $(x, y)$ with $0 \leq x, y \leq 5$ is chosen uniformly at random. Compute the expected number of up-right paths from $(0,0)$ to $(5,5)$ not passing through $(x, y)$.
+Proposed by: Mehtaab Sawnhey
+Answer: 175
+For a lattice point $(x, y)$, let $F(x, y)$ denote the number of up-right paths from $(0,0)$ to $(5,5)$ that don't pass through $(x, y)$, and let
+
+$$
+S=\sum_{0 \leq x \leq 5} \sum_{0 \leq y \leq 5} F(x, y)
+$$
+
+Our answer is $\frac{S}{36}$, as there are 36 lattice points $(x, y)$ with $0 \leq x, y \leq 5$.
+Notice that the number of up-right paths from $(0,0)$ to $(5,5)$ is $\binom{10}{5}=252$ because each path consists of 10 steps, of which we can choose 5 to be to the right. Each of these paths passes through 11 lattice points $(x, y)$ with $0 \leq x, y \leq 5$, so each path contributes $36-11=25$ to the quantity we are counting in $S$. Then $S=25 \cdot 252$, so our answer is $\frac{25 \cdot 252}{36}=175$.
+
diff --git a/HarvardMIT/md/en-231-2019-nov-guts-solutions.md b/HarvardMIT/md/en-231-2019-nov-guts-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..7ff620f6b3fd95995b3cbe4f7b3376e9f2fef335
--- /dev/null
+++ b/HarvardMIT/md/en-231-2019-nov-guts-solutions.md
@@ -0,0 +1,538 @@
+# HMMT November 2019 5$. In that case $q=2$ works. Otherwise assume $p$ is not a Fermat prime or Mersenne prime, so that $p-1$ and $p+1$ are not powers of 2 .
+If $p \equiv 1(\bmod 4)$, then let $q$ be an odd prime divisor of $p-1$, so that $p \equiv 1(\bmod q)$. Then by quadratic reciprocity $\left(\frac{q}{p}\right)=\left(\frac{p}{q}\right)=1$.
+If $p \equiv 3(\bmod 4)$, then let $q$ be an odd prime divisor of $p+1$, so that $p \equiv-1(\bmod q)$. Either $q \equiv 1$ $(\bmod 4)$ so that $\left(\frac{q}{p}\right)=\left(\frac{p}{q}\right)=1$ or $q \equiv 3(\bmod 4)$ so that $\left(\frac{q}{p}\right)=-\left(\frac{p}{q}\right)=-\left(\frac{-1}{q}\right)=1$.
+
+Solution 2: (Ankan Bhattacharya) We assume the same standard facts about quadratic residues as the previous solution.
+If $p \equiv 1(\bmod 4)$, then since $p>5$, there exists an odd prime divisor $q$ of $p-4$, which gives
+
+$$
+\left(\frac{q}{p}\right)=\left(\frac{p}{q}\right)=\left(\frac{4}{q}\right)=1
+$$
+
+If $p \equiv 7(\bmod 8)$, then we can take $q=2$.
+If $p \equiv 3(\bmod 8)$, then by Legendre's three square theorem there exist odd $a, b, c$ satisfying $p=$ $a^{2}+b^{2}+c^{2}$. Since $p>3$, these are not all equal and we may assume without loss of generality that $b \neq c$. Then $p-a^{2}=b^{2}+c^{2}$ has a prime divisor $q \equiv 1(\bmod 4)$, which gives
+
+$$
+\left(\frac{q}{p}\right)=\left(\frac{p}{q}\right)=\left(\frac{a^{2}}{q}\right)=1
+$$
+
+Remark. For an odd prime number $p$, let $l(p)$ be the least prime number which is a quadratic residue modulo $p$ and $h(-p)$ be the class number of the quadratic field $\mathbb{Q}[\sqrt{-p}]$. In the paper "The Least Prime Quadratic Residue and the Class Number" by Chowla, Cowles, and Cowles, the following results were proven:
+
+- If $p>5$ and $p \equiv 5(\bmod 8)$, then $l(p)<\sqrt{p}$.
+- If $p>3, p \equiv 3(\bmod 8)$, and $h(-p)>1$, then $l(p)<\sqrt{p / 3}$.
+- If $p>3, p \equiv 3(\bmod 8)$, and $h(-p)=1$, then $l(p)=\frac{p+1}{4}$.
+
+The proofs of the second and third results require knowledge of binary quadratic forms.
+10. [60] Let $n$ be a fixed positive integer, and choose $n$ positive integers $a_{1}, \ldots, a_{n}$. Given a permutation $\pi$ on the first $n$ positive integers, let $S_{\pi}=\left\{i \left\lvert\, \frac{a_{i}}{\pi(i)}\right.\right.$ is an integer $\}$. Let $N$ denote the number of distinct sets $S_{\pi}$ as $\pi$ ranges over all such permutations. Determine, in terms of $n$, the maximum value of $N$ over all possible values of $a_{1}, \ldots, a_{n}$.
+Proposed by: James Lin
+Answer: $2^{n}-n$
+Solution: The answer is $2^{n}-n$.
+Let $D=\left(d_{i j}\right)$ be the matrix where $d_{i j}$ is 1 if $i$ is a divisor of $a_{j}$ and 0 otherwise. For a subset $S$ of $[n]$, let $D_{S}$ be the matrix obtained from $D$ by flipping $(0 \leftrightarrow 1)$ every entry $d_{i j}$ where $j \notin S$. Observe that $S=S_{\pi}$ if and only if $\left(D_{S}\right)_{\pi(i) i}=1$ for all $i$.
+To show that $N \leq 2^{n}-n$ we consider two cases. If all the rows of $D$ are distinct, then there exist $n$ different possibilities for $S$ that set a row equal to zero. In this case, there is clearly no $\pi$ so that $S_{\pi}=S$. Thus there are at most $2^{n}-n$ possible $S_{\pi}$. Otherwise, if two rows in $D$ are the same, then choose an $S_{0}$ such that $D_{S_{0}}$ has two zero rows. Then, the $n+1$ sets $S$ that are at most "one element away" from $S_{0}$ are such that $D_{S}$ only has one column with nonzero entries in those two rows. This makes it impossible for $S_{\pi}=S$ as well, so $N \leq 2^{n}-n-1$.
+Now we construct $N=2^{n}-n$ by setting $a_{j}=j$. By Hall's marriage theorem, it suffices to prove the following:
+
+Assuming that $D_{S}$ has no completely-zero rows, given a set $I=\left\{i_{1}, i_{2}, \ldots, i_{k}\right\}$ there exist at least $k$ values of $j$ so that there exists an $i \in I$ so that $\left(D_{S}\right)_{i j}=1$. Call such $j$ admissible.
+Without loss of generality assume $i_{1}
Saturday 24 February 2007
+
+Individual Round: Calculus Test
+
+1. [3] Compute:
+
+$$
+\lim _{x \rightarrow 0} \frac{x^{2}}{1-\cos (x)}
+$$
+
+Answer: 2. Since $\sin ^{2}(x)=1-\cos ^{2}(x)$, we multiply the numerator and denominator by $1+\cos (x)$ and use the fact that $x / \sin (x) \rightarrow 1$, obtaining
+
+$$
+\lim _{x \rightarrow 0} \frac{x^{2}}{1-\cos (x)}=\lim _{x \rightarrow 0} \frac{x^{2}(1+\cos (x))}{1-\cos ^{2}(x)}=\lim _{x \rightarrow 0}\left(\frac{x}{\sin (x)}\right)^{2} \cdot 2=2
+$$
+
+Remarks. Another solution, using L'Hôpital's rule, is possible: $\lim _{x \rightarrow 0} \frac{x^{2}}{1-\cos (x)}=\lim _{x \rightarrow 0} \frac{2 x}{\sin (x)}=2$.
+2. [3] Determine the real number $a$ having the property that $f(a)=a$ is a relative minimum of $f(x)=$ $x^{4}-x^{3}-x^{2}+a x+1$.
+Answer: 1. Being a relative minimum, we have $0=f^{\prime}(a)=4 a^{3}-3 a^{2}-2 a+a=a(4 a+1)(a-1)$. Then $a=0,1,-1 / 4$ are the only possibilities. However, it is easily seen that $a=1$ is the only value satisfying $f(a)=a$.
+3. [4] Let $a$ be a positive real number. Find the value of $a$ such that the definite integral
+
+$$
+\int_{a}^{a^{2}} \frac{\mathrm{~d} x}{x+\sqrt{x}}
+$$
+
+achieves its smallest possible value.
+Answer: $\sqrt[{3-2 \sqrt{2}}]{ }$ Let $F(a)$ denote the given definite integral. Then
+
+$$
+F^{\prime}(a)=\frac{\mathrm{d}}{\mathrm{~d} a} \int_{a}^{a^{2}} \frac{\mathrm{~d} x}{x+\sqrt{x}}=2 a \cdot \frac{1}{a^{2}+\sqrt{a^{2}}}-\frac{1}{a+\sqrt{a}} .
+$$
+
+Setting $F^{\prime}(a)=0$, we find that $2 a+2 \sqrt{a}=a+1$ or $(\sqrt{a}+1)^{2}=2$. We find $\sqrt{a}= \pm \sqrt{2}-1$, and because $\sqrt{a}>0, a=(\sqrt{2}-1)^{2}=3-2 \sqrt{2}$.
+4. [4] Find the real number $\alpha$ such that the curve $f(x)=e^{x}$ is tangent to the curve $g(x)=\alpha x^{2}$.
+
+Answer: $\mathbf{e}^{\mathbf{2} / 4}$. Suppose tangency occurs at $x=x_{0}$. Then $e^{x_{0}}=\alpha x_{0}^{2}$ and $f^{\prime}\left(x_{0}\right)=2 \alpha x_{0}$. On the other hand, $f^{\prime}(x)=f(x)$, so $\alpha x_{0}^{2}=2 \alpha x_{0}$. Clearly, $\alpha=0$ and $x_{0}=0$ are impossible, so it must be that $x_{0}=2$. Then $\alpha=e^{x_{0}} /\left(x_{0}^{2}\right)=e^{2} / 4$.
+5. [5] The function $f: \mathbb{R} \rightarrow \mathbb{R}$ satisfies $f\left(x^{2}\right) f^{\prime \prime}(x)=f^{\prime}(x) f^{\prime}\left(x^{2}\right)$ for all real $x$. Given that $f(1)=1$ and $f^{\prime \prime \prime}(1)=8$, determine $f^{\prime}(1)+f^{\prime \prime}(1)$.
+Answer: 6. Let $f^{\prime}(1)=a$ and $f^{\prime \prime}(1)=b$. Then setting $x=1$ in the given equation, $b=a^{2}$. Differentiating the given yields
+
+$$
+2 x f^{\prime}\left(x^{2}\right) f^{\prime \prime}(x)+f\left(x^{2}\right) f^{\prime \prime \prime}(x)=f^{\prime \prime}(x) f^{\prime}\left(x^{2}\right)+2 x f^{\prime}(x) f^{\prime \prime}\left(x^{2}\right)
+$$
+
+Plugging $x=1$ into this equation gives $2 a b+8=a b+2 a b$, or $a b=8$. Then because $a$ and $b$ are real, we obtain the solution $(a, b)=(2,4)$.
+Remarks. A priori, the function needn't exist, but one possibility is $f(x)=e^{2 x-2}$.
+6. [5] The elliptic curve $y^{2}=x^{3}+1$ is tangent to a circle centered at $(4,0)$ at the point $\left(x_{0}, y_{0}\right)$. Determine the sum of all possible values of $x_{0}$.
+Answer: $\frac{\mathbf{1}}{\mathbf{3}}$. Note that $y^{2} \geq 0$, so $x^{3} \geq-1$ and $x \geq-1$. Let the circle be defined by $(x-4)^{2}+y^{2}=c$ for some $c \geq 0$. Now differentiate the equations with respect to $x$, obtaining $2 y \frac{\mathrm{~d} y}{\mathrm{~d} x}=3 x^{2}$ from the given and $2 y \frac{\mathrm{~d} y}{\mathrm{~d} x}=-2 x+8$ from the circle. For tangency, the two expressions $\frac{\mathrm{d} y}{\mathrm{~d} x}$ must be equal if they are well-defined, and this is almost always the case. Thus, $-2 x_{0}+8=3 x_{0}^{2}$ so $x_{0}=-2$ or $x_{0}=4 / 3$, but only the latter corresponds to a point on $y^{2}=x^{3}+1$. Otherwise, $y_{0}=0$, and this gives the trivial solution $x_{0}=-1$.
+7. [5] Compute
+
+$$
+\sum_{n=1}^{\infty} \frac{1}{n \cdot(n+1) \cdot(n+1)!}
+$$
+
+Answer: 3-e. We write
+
+$$
+\begin{gathered}
+\sum_{n=1}^{\infty} \frac{1}{n \cdot(n+1) \cdot(n+1)!}=\sum_{n=1}^{\infty}\left(\frac{1}{n}-\frac{1}{n+1}\right) \frac{1}{(n+1)!}=\sum_{n=1}^{\infty} \frac{1}{n \cdot(n+1)!}-\sum_{n=1}^{\infty} \frac{1}{(n+1) \cdot(n+1)!} \\
+\frac{1}{2}+\sum_{n=2}^{\infty} \frac{1}{n \cdot(n+1)!}-\sum_{n=1}^{\infty} \frac{1}{(n+1) \cdot(n+1)!}=\frac{1}{2}+\sum_{n=1}^{\infty} \frac{1}{(n+1) \cdot(n+2)!}-\frac{1}{(n+1) \cdot(n+1)!} \\
+\frac{1}{2}+\sum_{n=1}^{\infty} \frac{1-(n+2)}{(n+1) \cdot(n+2)!}=\frac{1}{2}-\left(\frac{1}{3!}+\frac{1}{4!}+\cdots\right)=3-\left(\frac{1}{0!}+\frac{1}{1!}+\frac{1}{2!}+\cdots\right)=3-e .
+\end{gathered}
+$$
+
+Alternatively, but with considerably less motivation, we can induce telescoping by adding and subtracting $e-2=1 / 2!+1 / 3!+\cdots$, obtaining
+
+$$
+\begin{aligned}
+2-e & +\sum_{n=1}^{\infty} \frac{n(n+1)+1}{n \cdot(n+1) \cdot(n+1)!}=2-e+\sum_{n=1}^{\infty} \frac{(n+1)^{2}-n}{n \cdot(n+1) \cdot(n+1)!} \\
+2 & -e+\sum_{n=1}^{\infty} \frac{1}{n \cdot n!}-\frac{1}{(n+1) \cdot(n+1)!}=3-e
+\end{aligned}
+$$
+
+8. [6] Suppose that $\omega$ is a primitive $2007^{\text {th }}$ root of unity. Find $\left(2^{2007}-1\right) \sum_{j=1}^{2006} \frac{1}{2-\omega^{j}}$.
+
+For this problem only, you may express your answer in the form $m \cdot n^{k}+p$, where $m, n, k$, and $p$ are positive integers. Note that a number $z$ is a primitive $n^{\text {th }}$ root of unity if $z^{n}=1$ and $n$ is the smallest number amongst $k=1,2, \ldots, n$ such that $z^{k}=1$.
+Answer: $2005 \cdot \mathbf{2}^{2006}+1$. Note that
+
+$$
+\begin{aligned}
+& \frac{1}{z-\omega}+\cdots+\frac{1}{z-\omega^{2006}}=\frac{\sum_{j=1}^{2006} \prod_{i \neq j}\left(z-\omega^{i}\right)}{(z-\omega) \cdots\left(z-\omega^{2006}\right)} \\
+& \quad=\frac{\frac{\mathrm{d}}{\mathrm{~d} z}\left[z^{2006}+z^{2005}+\cdots+1\right]}{z^{2006}+z^{2005}+\cdots+1}=\frac{2006 z^{2005}+2005 z^{2004}+\cdots+1}{z^{2006}+z^{2005}+\cdots+1} \cdot \frac{z-1}{z-1} \\
+& \quad=\frac{2006 z^{2006}-z^{2005}-z^{2004}-\cdots-1}{z^{2007}-1} \cdot \frac{z-1}{z-1}=\frac{2006 z^{2007}-2007 z^{2006}+1}{\left(z^{2007}-1\right)(z-1)} .
+\end{aligned}
+$$
+
+Plugging in $z=2$ gives $\frac{2005 \cdot 2^{2006}+1}{2^{2007}-1}$; whence the answer.
+9. $[7] g$ is a twice differentiable function over the positive reals such that
+
+$$
+\begin{aligned}
+g(x)+2 x^{3} g^{\prime}(x)+x^{4} g^{\prime \prime}(x) & =0 \quad \text { for all positive reals } x . \\
+\lim _{x \rightarrow \infty} x g(x) & =1
+\end{aligned}
+$$
+
+Find the real number $\alpha>1$ such that $g(\alpha)=1 / 2$.
+Answer: $\frac{6}{\pi}$. In the first equation, we can convert the expression $2 x^{3} g^{\prime}(x)+x^{4} g^{\prime \prime}(x)$ into the derivative of a product, and in fact a second derivative, by writing $y=1 / x$. Specifically,
+
+$$
+\begin{aligned}
+0=g(x)+2 x^{3} g^{\prime}(x)+x^{4} g^{\prime \prime}(x) & =g\left(\frac{1}{y}\right)+2 y^{-3} g^{\prime}\left(\frac{1}{y}\right)+y^{-4} g^{\prime \prime}\left(\frac{1}{y}\right) \\
+& =g\left(\frac{1}{y}\right)+\frac{\mathrm{d}}{\mathrm{~d} y}\left[-y^{-2} g^{\prime}\left(\frac{1}{y}\right)\right] \\
+& =g\left(\frac{1}{y}\right)+\frac{\mathrm{d}^{2}}{\mathrm{~d} y^{2}}\left[g\left(\frac{1}{y}\right)\right]
+\end{aligned}
+$$
+
+Thus $g\left(\frac{1}{y}\right)=c_{1} \cos (y)+c_{2} \sin (y)$ or $g(x)=c_{1} \cos (1 / x)+c_{2} \sin (1 / x)$. Now the second condition gives
+
+$$
+1=\lim _{x \rightarrow \infty} c_{1} x+c_{2} \cdot \frac{\sin (1 / x)}{1 / x}=c_{2}+\lim _{x \rightarrow \infty} c_{1} x
+$$
+
+It must be that $c_{1}=0, c_{2}=1$. Now since $0<1 / \alpha<1$, the value of $\alpha$ such that $g(\alpha)=\sin (1 / \alpha)=1 / 2$ is given by $1 / \alpha=\pi / 6$ and so $\alpha=6 / \pi$.
+10. [8] Compute
+
+$$
+\int_{0}^{\infty} \frac{e^{-x} \sin (x)}{x} d x
+$$
+
+Answer: $\frac{\pi}{4}$. We can compute the integral by introducing a parameter and exchanging the order of integration:
+
+$$
+\begin{aligned}
+\int_{0}^{\infty} e^{-x}\left(\frac{\sin (x)}{x}\right) \mathrm{d} x & =\int_{0}^{\infty} e^{-x}\left(\int_{0}^{1} \cos (a x) \mathrm{d} a\right) \mathrm{d} x=\int_{0}^{1}\left(\int_{0}^{\infty} e^{-x} \cos (a x) \mathrm{d} x\right) \mathrm{d} a \\
+& =\int_{0}^{1} \operatorname{Re}\left[\int_{0}^{\infty} e^{(-1+a i) x} \mathrm{~d} x\right] \mathrm{d} a=\int_{0}^{1} \operatorname{Re}\left[\left.\frac{e^{(-1+a i) x}}{-1+a i}\right|_{x=0} ^{\infty}\right] \mathrm{d} a \\
+& =\int_{0}^{1} \operatorname{Re}\left[\frac{1}{1-a i}\right] \mathrm{d} a=\int_{0}^{1} \operatorname{Re}\left[\frac{1+a i}{1+a^{2}}\right] \mathrm{d} a \\
+& =\int_{0}^{1} \frac{1}{1+a^{2}} \mathrm{~d} a=\left.\tan ^{-1}(a)\right|_{a=0} ^{1}=\frac{\pi}{4}
+\end{aligned}
+$$
+
diff --git a/HarvardMIT/md/en-102-2007-feb-comb-solutions.md b/HarvardMIT/md/en-102-2007-feb-comb-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..ca2d0a8bc83f9557fa1c8313a3b7d84799f245a4
--- /dev/null
+++ b/HarvardMIT/md/en-102-2007-feb-comb-solutions.md
@@ -0,0 +1,75 @@
+# $10^{\text {th }}$ Annual Harvard-MIT Mathematics Tournament
Saturday 24 February 2007
+
+
Saturday 24 February 2007}
+
+## Individual Round: Combinatorics Test
+
+1. [3] A committee of 5 is to be chosen from a group of 9 people. How many ways can it be chosen, if Biff and Jacob must serve together or not at all, and Alice and Jane refuse to serve with each other?
+Answer: 41. If Biff and Jacob are on the committee, there are $\binom{7}{3}=35$ ways for the other members to be chosen. Amongst these 35 possibilities, we reject the $\binom{5}{1}=5$ choices where both Alice and Jane are also serving. If Biff and Jacob are not serving, then there are $\binom{7}{5}=21$ ways to choose the remaining 5 members. Again, we reject the $\binom{5}{3}=10$ instances where Alice and Jane are chosen, so the total is $(35-5)+(21-10)=41$.
+2. [3] How many 5-digit numbers $\overline{a b c d e}$ exist such that digits $b$ and $d$ are each the sum of the digits to their immediate left and right? (That is, $b=a+c$ and $d=c+e$.)
+Answer: 330. Note that $a>0$, so that $b>c$, and $e \geq 0$ so that $d \geq c$. Conversely, for each choice of $(b, c, d)$ with $b>c$ and $d \geq c$, there exists a unique pair $(a, e)$ such that $\overline{a b c d e}$ is a number having the desired property. Thus, we compute
+
+$$
+\sum_{c=0}^{9}(9-c)(10-c)=\sum_{c=0}^{9} c^{2}-19 c+90=330
+$$
+
+3. [4] Jack, Jill, and John play a game in which each randomly picks and then replaces a card from a standard 52 card deck, until a spades card is drawn. What is the probability that Jill draws the spade? (Jack, Jill, and John draw in that order, and the game repeats if no spade is drawn.)
+Answer: $\frac{\mathbf{1 2}}{\mathbf{3 7}}$. The desired probability is the relative probability that Jill draws the spade. In the first round, Jack, Jill, and John draw a spade with probability $1 / 4,3 / 4 \cdot 1 / 4$, and $(3 / 4)^{2} \cdot 1 / 4$ respectively. Thus, the probability that Jill draws the spade is
+
+$$
+\frac{3 / 4 \cdot 1 / 4}{1 / 4+3 / 4 \cdot 1 / 4+(3 / 4)^{2} \cdot 1 / 4}=\frac{12}{37}
+$$
+
+4. [4] On the Cartesian grid, Johnny wants to travel from $(0,0)$ to $(5,1)$, and he wants to pass through all twelve points in the set $S=\{(i, j) \mid 0 \leq i \leq 1,0 \leq j \leq 5, i, j \in \mathbb{Z}\}$. Each step, Johnny may go from one point in $S$ to another point in $S$ by a line segment connecting the two points. How many ways are there for Johnny to start at $(0,0)$ and end at $(5,1)$ so that he never crosses his own path?
+
+
+Answer: 252. Observe that Johnny needs to pass through the points $(0,0),(1,0),(2,0), \ldots,(5,0)$ in that order, and he needs to pass through $(0,1),(1,1),(2,1), \ldots,(5,1)$ in that order, or else he will intersect his own path. Then, the problem is equivalent to interlacing those two sequence together, so that the first term is $(0,0)$ and the final term is $(5,1)$. To do this, we need to select 5 positions out of 10 to have points with $x$-coordinate 0 . Hence the answer is $\binom{10}{5}=252$.
+5. [5] Determine the number of ways to select a positive number of squares on an $8 \times 8$ chessboard such that no two lie in the same row or the same column and no chosen square lies to the left of and below another chosen square.
+
+Answer: $12869=\binom{16}{8}$ - 1. If $k$ is the number of squares chosen, then there are $\binom{8}{k}$ ways to choose $k$ columns, and $\binom{8}{k}$ ways to choose $k$ rows, and this would uniquely determine the set of squares selected. Thus the answer is
+
+$$
+\sum_{k=1}^{8}\binom{8}{k}\binom{8}{k}=-1+\sum_{k=0}^{8}\binom{8}{k}\binom{8}{k}=-1+\binom{16}{8}=12869
+$$
+
+6. [5] Kevin has four red marbles and eight blue marbles. He arranges these twelve marbles randomly, in a ring. Determine the probability that no two red marbles are adjacent.
+Answer: $\frac{7}{\mathbf{7 3}}$. Select any blue marble and consider the remaining eleven marbles, arranged in a line. The proportion of arrangement for which no two red marbles are adjacent will be the same as for the original twelve marbles, arranged in a ring. The total number of ways of arranging 4 red marbles out of 11 is $\binom{11}{4}=330$. To count the number of arrangements such that no two red marbles are adjacent, there must be one red marble between each two would-be adjacent red marbles. Having fixed the positions of three blue marbles we have four blue marbles to play with. So that we can arrange the remaining four marbles is $\binom{8}{4}=70$ ways. This yields a probability of $70 / 330=7 / 33$ as our final answer.
+7. [5] Forty two cards are labeled with the natural numbers 1 through 42 and randomly shuffled into a stack. One by one, cards are taken off of the top of the stack until a card labeled with a prime number is removed. How many cards are removed on average?
+Answer: $\frac{\mathbf{4 3}}{\mathbf{1 4}}$. Note that there are 13 prime numbers amongst the cards. We may view these as separating the remaining 29 cards into 14 groups of nonprimes - those appearing before the first prime, between the first and second, etc. Each of these groups is equally likely to appear first, so 29/14 nonprimes are removed on average. We are done since exactly one prime is always drawn.
+8. [6] A set of six edges of a regular octahedron is called Hamiltonian cycle if the edges in some order constitute a single continuous loop that visits each vertex exactly once. How many ways are there to partition the twelve edges into two Hamiltonian cycles?
+
+
+Answer: 6. Call the octahedron $A B C D E F$, where $A, B$, and $C$ are opposite $D, E$, and $F$, respectively. Note that each Hamiltonian cycle can be described in terms of the order it visits vertices in exactly 12 different ways. Conversely, listing the six vertices in some order determines a Hamiltonian cycle precisely when no pair of opposite vertices are listed consecutively or first-and-last. Suppose we begin with $A B$. If $D$ is listed third, then the final three letters are $C E F$ or $F E C$. Otherwise, $C$ or $F$ is listed next, and each gives three possibilities for the final three. For example $A B C$ is be followed by $D E F, D F E$, or $E D F$. Thus, there are $6 \cdot 4 \cdot(2+3+3)=192$ listings. These correspond to $192 / 12=16$ Hamiltonian cycles. Finally, the complement of all but four Hamiltonian cycles is a Hamiltonian cycle. For, each vertex has degree four, so is an endpoint of two edges in the complement of a Hamiltonian cycle, so is also a Hamiltonian cycle unless it describes two opposite faces. It follows that there are six pairs of disjoint Hamiltonian cycles.
+9. [7] Let $S$ denote the set of all triples $(i, j, k)$ of positive integers where $i+j+k=17$. Compute
+
+$$
+\sum_{(i, j, k) \in S} i j k .
+$$
+
+Answer: $11628=\binom{\mathbf{1 9}}{\mathbf{5}}$. We view choosing five objects from a row of 19 objects in an unual way. First, remove two of the chosen objects, the second and fourth, which are not adjacent nor at either end, forming three nonempty groups of consecutive objects. We then have $i, j$, and $k$ choices for the first, third, and fifth objects. Because this is a reversible process taking a triple $(i, j, k)$ to $i j k$ choices, the answer is $\binom{19}{5}=11628$.
+A simple generating functions argument is also possible. Let $s_{n}=\sum_{i+j+k=n} i j k$. Then
+
+$$
+\sum_{n \geq 0} s_{n} x^{n}=\left(\sum_{n \geq 0} n x^{n}\right)^{3}=\left(\frac{x}{(1-x)^{2}}\right)^{3}=\frac{x^{3}}{(1-x)^{6}}
+$$
+
+and so $s_{n}=\left(\binom{6}{n-3}\right)=\binom{n+2}{5}$, yielding $s_{17}=\binom{19}{5}$.
+10. [8] A subset $S$ of the nonnegative integers is called supported if it contains 0 , and $k+8, k+9 \in S$ for all $k \in S$. How many supported sets are there?
+Answer: 1430. Note that every supported set $S$ contains $0,8,9,16,17,18,24-27,32-36,40-45$, $48-54$, and all $n \geq 55$. Now define $\bar{S}:=\mathbb{Z}^{+} \backslash S$, which is a subset of $\{1-7,10-15,19-23,28-$ $31,37,38,39,46,47,55\}$ satisfying the opposite property that $k \in \bar{S} \Longrightarrow k-8, k-9 \in \bar{S}$.
+
+
+Consider the above arrangement after removing the numbers not in $\bar{S}$. The condition that $S$ be supported ensures that sets $\bar{S}$ are in bijective correspondence with paths from $(0,0)$ to $(16,0)$ consisting of discrete steps of $\langle 1,1\rangle$ and $\langle 1,-1\rangle$ and lying above the $x$-axis: from the modified version of the above diagram, a unique path passes through the top items left in each column. The number of such paths is the 8th Catalan number, so the answer is $C_{8}=\frac{1}{8+1}\binom{8 \cdot 2}{8}=\frac{12870}{9}=1430$. (Incidentally, 16 choose 8 was computed in an earlier problem.) Without the explicit formula for Catalan numbers, the answer can be computed recursively by filling in the number of ways a path can reach $(16,0)$ from each position in the figure. One works right to left, obtaining the following:
+
+| | | | | | | | | 1 | | | | | | | |
+| :---: | :---: | :---: | :---: | :---: | :---: | :---: | :---: | :---: | :---: | :---: | :---: | :---: | :---: | :---: | :---: |
+| | | | | | | | 8 | | 1 | | | | | | |
+| | | | | | | 35 | | 7 | | 1 | | | | | |
+| | | | | | 110 | | 27 | | 6 | | 1 | | | | |
+| | | | | 275 | | 75 | | 20 | | 5 | | 1 | | | |
+| | | | 572 | | 165 | | 48 | | 14 | | 4 | | 1 | | |
+| | | 1001 | | 297 | | 90 | | 28 | | 9 | | 3 | | 1 | |
+| | 1430 | | 429 | | 132 | | 42 | | 14 | | 5 | | 2 | | 1 |
+| 1430 | | 429 | | 132 | | 42 | | 14 | | 5 | | 2 | | 1 | |
+
+One can exploit symmetry and, having determined the middle column, sum the squares: $1^{2}+7^{2}+$ $20^{2}+28^{2}+14^{2}=1430$.
+
diff --git a/HarvardMIT/md/en-102-2007-feb-gen1-solutions.md b/HarvardMIT/md/en-102-2007-feb-gen1-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..5b379aee874eec3bb2e1d8ca81d51f75a4331e07
--- /dev/null
+++ b/HarvardMIT/md/en-102-2007-feb-gen1-solutions.md
@@ -0,0 +1,36 @@
+# $10^{\text {th }}$ Annual Harvard-MIT Mathematics Tournament Saturday 24 February 2007
+
+Individual Round: General Test, Part 1
+
+1. [2] Michael has 16 white socks, 3 blue socks, and 6 red socks in a drawer. Ever the lazy college student, he has overslept and is late for his favorite team's season-opener. Because he is now in such a rush to get from Harvard to Foxborough, he randomly takes socks from the drawer (one at a time) until he has a pair of the same color. What is the largest number of socks he could possibly withdraw in this fashion?
+Answer: 4. It is possible for him to begin with three socks of different colors, but an instance of the Pigeon Hole Principle is that among any four objects of three types some two are the same type.
+2. [2] Rectangle $A B C D$ has side lengths $A B=12$ and $B C=5$. Let $P$ and $Q$ denote the midpoints of segments $A B$ and $D P$, respectively. Determine the area of triangle $C D Q$.
+Answer: 15. Note that $[C D P]=\frac{1}{2} \cdot 5 \cdot 12=30$, while the area of triangle $C D Q$ is half of the area of triangle $C D P$.
+3. $[3] A, B, C$, and $D$ are points on a circle, and segments $\overline{A C}$ and $\overline{B D}$ intersect at $P$, such that $A P=8$, $P C=1$, and $B D=6$. Find $B P$, given that $B P
Saturday 24 February 2007
+
+
Saturday 24 February 2007}
+
+Team Round: A Division
$\Sigma, \tau$, and You: Fun at Fraternities? [270]
+
+A number theoretic function is a function whose domain is the set of positive integers. A multiplicative number theoretic function is a number theoretic function $f$ such that $f(m n)=f(m) f(n)$ for all pairs of relatively prime positive integers $m$ and $n$. Examples of multiplicative number theoretic functions include $\sigma, \tau, \phi$, and $\mu$, defined as follows. For each positive integer $n$,
+
+- The sum-of-divisors function, $\sigma(n)$, is the sum of all positive integer divisors of $n$. If $p_{1}, \ldots, p_{i}$ are distinct primes and $e_{1}, \ldots, e_{i}$ are positive integers,
+
+$$
+\sigma\left(p_{1}^{e_{1}} \cdots p_{i}^{e_{i}}\right)=\prod_{k=1}^{i}\left(1+p_{k}+\cdots+p_{k}^{e_{k}}\right)=\prod_{k=1}^{i} \frac{p_{k}^{e_{k}+1}-1}{p_{k}-1}
+$$
+
+- The divisor function, $\tau(n)$, is the number of positive integer divisors of $n$. It can be computed by the formula
+
+$$
+\tau\left(p_{1}^{e_{1}} \cdots p_{i}^{e_{i}}\right)=\left(e_{1}+1\right) \cdots\left(e_{i}+1\right)
+$$
+
+where $p_{1}, \ldots, p_{i}$ and $e_{1}, \ldots, e_{i}$ are as above.
+
+- Euler's totient function, $\phi(n)$, is the number of positive integers $k \leq n$ such that $k$ and $n$ are relatively prime. For $p_{1}, \ldots, p_{i}$ and $e_{1}, \ldots, e_{i}$ as above, the phi function satisfies
+
+$$
+\phi\left(p_{1}^{e_{1}} \cdots p_{i}^{e_{i}}\right)=\prod_{k=1}^{i} p_{k}^{e_{k}-1}\left(p_{k}-1\right)
+$$
+
+- The Möbius function, $\mu(n)$, is equal to either $1,-1$, or 0 . An integer is called square-free if it is not divisible by the square of any prime. If $n$ is a square-free positive integer having an even number of distinct prime divisors, $\mu(n)=1$. If $n$ is a square-free positive integer having an odd number of distinct prime divisors, $\mu(n)=-1$. Otherwise, $\mu(n)=0$.
+
+The Möbius function has a number of peculiar properties. For example, if $f$ and $g$ are number theoretic functions such that
+
+$$
+g(n)=\sum_{d \mid n} f(d)
+$$
+
+for all positive integers $n$, then
+
+$$
+f(n)=\sum_{d \mid n} g(d) \mu\left(\frac{n}{d}\right)
+$$
+
+This is known as Möbius inversion. In proving the following problems, you may use any of the preceding assertions without proving them. You may also cite the results of previous problems, even if you were unable to prove them.
+
+1. [15] Evaluate the functions $\phi(n), \sigma(n)$, and $\tau(n)$ for $n=12, n=2007$, and $n=2^{2007}$.
+
+Solution. For $n=12=2^{2} \cdot 3^{1}$,
+
+$$
+\phi(12)=2(2-1)(3-1)=4, \quad \sigma(12)=(1+2+4)(1+3)=28, \quad \tau(12)=(2+1)(1+1)=6
+$$
+
+for $n=2007=3^{2} \cdot 223$,
+$\phi(2007)=3(3-1)(223-1)=1332, \quad \sigma(2007)=(1+3+9)(1+223)=2912, \quad \tau(2007)=(2+1)(1+1)=6 ;$
+and for $n=2^{2007}$,
+
+$$
+\phi\left(2^{2007}\right)=2^{2006}, \quad \sigma\left(2^{2007}\right)=\left(1+2+\cdots+2^{2007}\right)=2^{2008}-1, \quad \tau\left(2^{2007}\right)=2007+1=2008
+$$
+
+2. [20] Solve for the positive integer(s) $n$ such that $\phi\left(n^{2}\right)=1000 \phi(n)$.
+
+Answer: 1000.
+Solution. The unique solution is $n=1000$. For, $\phi(p n)=p \phi(n)$ for every prime $p$ dividing $n$, so that $\phi\left(n^{2}\right)=n \phi(n)$ for all positive integers $n$.
+3. [25] Prove that for every integer $n$ greater than 1 ,
+
+$$
+\sigma(n) \phi(n) \leq n^{2}-1
+$$
+
+When does equality hold?
+Solution. Note that
+
+$$
+\sigma(m n) \phi(m n)=\sigma(m) \phi(m) \sigma(n) \phi(n) \leq\left(m^{2}-1\right)\left(n^{2}-1\right)=(m n)^{2}-\left(m^{2}+n^{2}-1\right)<(m n)^{2}-1
+$$
+
+for any pair of relatively prime positive integers $(m, n)$ other than $(1,1)$. Now, for $p$ a prime and $k$ a positive integer, $\sigma\left(p^{k}\right)=1+p+\cdots+p^{k}=\frac{p^{k+1}-1}{p-1}$ and $\phi\left(p^{k}\right)=p^{k}-\frac{1}{p} \cdot p^{k}=(p-1) p^{k-1}$. Thus,
+
+$$
+\sigma\left(p^{k}\right) \phi\left(p^{k}\right)=\frac{p^{k+1}-1}{p-1} \cdot(p-1) p^{k-1}=\left(p^{k+1}-1\right) p^{k-1}=p^{2 k}-p^{k-1} \leq p^{2 k}-1
+$$
+
+with equality where $k=1$. It follows that equality holds in the given inequality if and only if $n$ is prime.
+4. [25] Let $F$ and $G$ be two multiplicative functions, and define for positive integers $n$,
+
+$$
+H(n)=\sum_{d \mid n} F(d) G\left(\frac{n}{d}\right)
+$$
+
+The number theoretic function $H$ is called the convolution of $F$ and $G$. Prove that $H$ is multiplicative. Solution. Let $m$ and $n$ be relatively prime positive integers. We have
+
+$$
+\begin{aligned}
+& H(m) H(n)=\left(\sum_{d \mid m} F(d) G\left(\frac{m}{d}\right)\right)\left(\sum_{d^{\prime} \mid n} F\left(d^{\prime}\right) G\left(\frac{n}{d^{\prime}}\right)\right) \\
+& \quad=\sum_{d\left|m, d^{\prime}\right| n} F(d) F\left(d^{\prime}\right) G\left(\frac{m}{d^{\prime}}\right) G\left(\frac{n}{d}\right)=\sum_{d\left|m, d^{\prime}\right| n} F\left(d d^{\prime}\right) G\left(\frac{m n}{d d^{\prime}}\right) \\
+& \quad=\sum_{d \mid m n} F(d) G\left(\frac{m n}{d}\right)=H(m n)
+\end{aligned}
+$$
+
+5. [30] Prove the identity
+
+$$
+\sum_{d \mid n} \tau(d)^{3}=\left(\sum_{d \mid n} \tau(d)\right)^{2}
+$$
+
+Solution. Note that $\tau^{3}$ is multiplicative; in light of the convolution property just shown, it follows that both sides of the posed equality are multiplicative. Thus, it would suffice to prove the claim for $n$ a power of a prime. So, write $n=p^{k}$ where $p$ is a prime and $k$ is a nonnegative integer. Then
+
+$$
+\begin{aligned}
+& \sum_{d \mid n} \tau(d)^{3}=\sum_{i=0}^{k} \tau\left(p^{i}\right)^{3}=\sum_{i=0}^{k}(i+1)^{3} \\
+& \quad=1^{3}+\cdots+(k+1)^{3}=\frac{(k+1)^{2}(k+2)^{2}}{4}=\left(\frac{(k+1)(k+2)}{2}\right)^{2} \\
+& \quad=\left(\sum_{i=0}^{k} \tau\left(p^{i}\right)\right)^{2}=\left(\sum_{d \mid n} \tau(d)\right)^{2}
+\end{aligned}
+$$
+
+as required.
+6. [25] Show that for positive integers $n$,
+
+$$
+\sum_{d \mid n} \phi(d)=n
+$$
+
+Solution. Both sides are multiplicative functions of $n$, the right side trivially and the left because for relatively prime positive integers $n$ and $n^{\prime}$,
+
+$$
+\left(\sum_{d \mid n} \phi(d)\right)\left(\sum_{d^{\prime} \mid n^{\prime}} \phi\left(d^{\prime}\right)\right)=\sum_{d\left|n, d^{\prime}\right| n^{\prime}} \phi(d) \phi\left(d^{\prime}\right),
+$$
+
+and $\phi(d) \phi\left(d^{\prime}\right)=\phi\left(d d^{\prime}\right)$. The identity is then easy to check; since $\phi\left(p^{k}\right)=p^{k-1}(p-1)$ for positive integers $k$ and $\phi(1)=1$, we have $\phi(1)+\phi(p)+\cdots+\phi\left(p^{k}\right)=1+(p-1)+\left(p^{2}-p\right)+\cdots+\left(p^{k}-p^{k-1}\right)=p^{k}$, as desired.
+7. [25] Show that for positive integers $n$,
+
+$$
+\sum_{d \mid n} \frac{\mu(d)}{d}=\frac{\phi(n)}{n}
+$$
+
+Solution. On the grounds of the previous problem, Möbius inversion with $f(k)=\phi(k)$ and $g(k)=k$ gives:
+
+$$
+\phi(n)=f(n)=\sum_{d \mid n} g(d) \mu\left(\frac{n}{d}\right)=\sum_{d^{\prime} \mid n} g\left(\frac{n}{d^{\prime}}\right) \mu\left(d^{\prime}\right)=\sum_{d^{\prime} \mid n} \frac{n}{d^{\prime}} \mu\left(d^{\prime}\right)
+$$
+
+Alternatively, one uses the convolution of the functions $f(k)=n$ and $g(k)=\frac{\mu(d)}{d}$. The strategy is the same as the previous convolution proof. For $n=p^{k}$ with $k$ a positive integer, we have $\phi(n)=p^{k}-p^{k-1}$, while the series reduces to $p^{k} \cdot \mu(1)+p^{k} \cdot \mu(p) / p=p^{k}-p^{k-1}$.
+8. [30] Determine with proof, a simple closed form expression for
+
+$$
+\sum_{d \mid n} \phi(d) \tau\left(\frac{n}{d}\right)
+$$
+
+Solution. We claim the series reduces to $\sigma(n)$. The series counts the ordered triples $(d, x, y)$ with $d|n ; x| d ; 0
Saturday 24 February 2007
+
+
Saturday 24 February 2007}
+
+Team Round: B Division
+
+$$
+\text { Compute }(x-a)(x-b) \cdots(x-z) \text { - Short Answer [200] }
+$$
+
+For this section, your team should give only the anwers to the problems.
+
+1. [20] Find the sum of the positive integer divisors of $2^{2007}$.
+
+Answer: $\mathbf{2}^{\mathbf{2 0 0 8}}-\mathbf{1}$. The divisors are the powers of two not exceeding $2^{2007}$. So the sum is
+$1+2+2^{2}+\cdots+2^{2007}=-1+2+2+2^{2}+\cdots+2^{2007}=-1+2^{2}+2^{2}+\cdots+2^{2007}=\cdots=-1+2^{2008}$.
+2. [20] The four sides of quadrilateral $A B C D$ are equal in length. Determine the perimeter of $A B C D$ given that it has area 120 and $A C=10$.
+
+
+Answer: 52. Let $M$ be the midpoint of $A C$. Then triangles $A M B, B M C, C M D$, and $D M A$ are all right triangles having legs 5 and $h$ for some $h$. The area of $A B C D$ is 120 , but also $4 \cdot\left(\frac{1}{2} \cdot 5 \cdot h\right)=10 h$, so $h=12$. Then $A B=B C=C D=D A=\sqrt{12^{2}+5^{2}}=13$, and the perimeter of $A B C D$ is 52 .
+3. [20] Five people are crowding into a booth against a wall at a noisy restaurant. If at most three can fit on one side, how many seating arrangements accomodate them all?
+Answer: 240. Three people will sit on one side and two sit on the other, giving a factor of two. Then there are 5 ! ways to permute the people.
+4. [20] Thomas and Michael are just two people in a large pool of well qualified candidates for appointment to a problem writing committee for a prestigious college math contest. It is 40 times more likely that both will serve if the size of the committee is increased from its traditional 3 members to a whopping $n$ members. Determine $n$. (Each person in the pool is equally likely to be chosen.)
+Answer: 16. Suppose there are $k$ candidates. Then the probability that both serve on a 3 membered committee is $(k-2) /\binom{k}{3}$, and the odds that both serve on an $n$ membered committee are $\binom{k-2}{n-2} /\binom{k}{n}$. The ratio of the latter to the former is
+
+$$
+\frac{\binom{k}{3}\binom{k-2}{n-2}}{(k-2)\binom{k}{n}}=\frac{k!(k-2)!1!(k-3)!n!(k-n)!}{k!(k-2)!(n-2)!(k-n)!3!(k-3)!}=\frac{n \cdot(n-1)}{3!}
+$$
+
+Solving $n \cdot(n-1)=240$ produces $n=16,-15$, and we discard the latter.
+5. [20] The curves $y=x^{2}(x-3)^{2}$ and $y=\left(x^{2}-1\right)(x-2)$ intersect at a number of points in the real plane. Determine the sum of the $x$-coordinates of these points of intersection.
+Answer: 7. Because the first curve touches the $x$-axis at $x=0$ and $x=3$ while the second curve crosses the $x$-axis at $x= \pm 1$ and $x=2$, there are four points of intersection. In particular, the points of intersection have $x$-coordinates determined by the difference of the two curves:
+
+$$
+0=x^{2}(x-3)^{2}-\left(x^{2}-1\right)(x-2)=\left(x^{4}-6 x^{3}+\cdots\right)-\left(x^{3}+\cdots\right)=x^{4}-7 x^{3}+\cdots
+$$
+
+We need only the first two coefficients to determine $x_{1}+x_{2}+x_{3}+x_{4}=-\left(\frac{-7}{1}\right)=7$.
+6. [20] Andrew has a fair six sided die labeled with 1 through 6 as usual. He tosses it repeatedly, and on every third roll writes down the number facing up as long as it is not the 6 . He stops as soon as the last two numbers he has written down are squares or one is a prime and the other is a square. What is the probability that he stops after writing squares consecutively?
+Answer: $4 / \mathbf{2 5}$. We can safely ignore all of the rolls he doesn't record. The probability that he stops after writing two squares consecutively is the same as the probability that he never rolls a prime. For, as soon as the first prime is written, either it must have been preceded by a square or it will be followed by a nonnegative number of additional primes and then a square. So we want the probability that two numbers chosen uniformly with replacement from $\{1,2,3,4,5\}$ are both squares, which is $(2 / 5)^{2}$.
+7. [20] Three positive reals $x, y$, and $z$ are such that
+
+$$
+\begin{aligned}
+x^{2}+2(y-1)(z-1) & =85 \\
+y^{2}+2(z-1)(x-1) & =84 \\
+z^{2}+2(x-1)(y-1) & =89
+\end{aligned}
+$$
+
+Compute $x+y+z$.
+Answer: 18. Add the three equations to obtain
+
+$$
+x^{2}+y^{2}+z^{2}+2 x y+2 y z+2 z x-4 x-4 y-4 z+6=258
+$$
+
+which rewrites as $(x+y+z-2)^{2}=256$. Evidently, $x+y+z=2 \pm 16$. Since $x, y$, and $z$ are positive, $x+y+z>0$ so $x+y+z=2+16=18$.
+8. [20] Find the positive real number(s) $x$ such that $\frac{1}{2}\left(3 x^{2}-1\right)=\left(x^{2}-50 x-10\right)\left(x^{2}+25 x+5\right)$.
+
+Answer: $\mathbf{2 5}+\mathbf{2} \sqrt{\mathbf{1 5 9}}$. Write $a=x^{2}-50 x-10$ and $b=x^{2}+25 x+5$; the given becomes $\frac{a+2 b-1}{2}=a b$, so $0=2 a b-a-2 b+1=(a-1)(2 b-1)$. Then $a-1=x^{2}-50 x-11=0$ or $2 b-1=2 x^{2}+50 x+9=0$. The former has a positive root, $x=25+2 \sqrt{159}$, while the latter cannot, for obvious reasons.
+9. [20] Cyclic quadrilateral $A B C D$ has side lengths $A B=1, B C=2, C D=3$, and $A D=4$. Determine $A C / B D$.
+
+
+Answer: 5/7. Let the diagonals intersect at $P$. Note that triangles $A B P$ and $D C P$ are similar, so that $3 A P=D P$ and $3 B P=C P$. Additionally, triangles $B C P$ and $A D P$ are similar, so that $2 B P=A P$. It follows that
+
+$$
+\frac{A C}{B D}=\frac{A P+P C}{B P+P D}=\frac{2 B P+3 B P}{B P+6 B P}=\frac{5}{7}
+$$
+
+10. [20] A positive real number $x$ is such that
+
+$$
+\sqrt[3]{1-x^{3}}+\sqrt[3]{1+x^{3}}=1
+$$
+
+Find $x^{2}$.
+Answer: $\frac{\sqrt[3]{28}}{\mathbf{3}}$. Cubing the given equation yields
+
+$$
+1=\left(1-x^{3}\right)+3 \sqrt[3]{\left(1-x^{3}\right)\left(1+x^{3}\right)}\left(\sqrt[3]{1-x^{3}}+\sqrt[3]{1+x^{3}}\right)+\left(1+x^{3}\right)=2+3 \sqrt[3]{1-x^{6}}
+$$
+
+Then $\frac{-1}{3}=\sqrt[3]{1-x^{6}}$, so $\frac{-1}{27}=1-x^{6}$ and $x^{6}=\frac{28}{27}$ and $x^{2}=\frac{\sqrt[3]{28}}{3}$.
+
+## Adult Acorns - Gee, I'm a Tree! [200]
+
+In this section of the team round, your team will derive some basic results concerning tangential quadrilaterals. Tangential quadrilaterals have an incircle, or a circle lying within them that is tangent to all four sides. If a quadrilateral has an incircle, then the center of this circle is the incenter of the quadrilateral. As you shall see, tangential quadrilaterals are related to cyclic quadrilaterals. For reference, a review of cyclic quadrilaterals is given at the end of this section.
+
+Your answers for this section of the team test should be proofs. Note that you may use any standard facts about cyclic quadrilaterals, such as those listed at the end of this test, without proving them. Additionally, you may cite the results of previous problems, even if you were unable to prove them.
+
+For these problems, $A B C D$ is a tangential quadrilateral having incenter $I$. For the first three problems, the point $P$ is constructed such that triangle $P A B$ is similar to triangle $I D C$ and lies outside $A B C D$.
+
+1. $[\mathbf{3 0}]$ Show that $P A I B$ is cyclic by proving that $\angle I A P$ is supplementary to $\angle P B I$.
+
+Solution. Note that $I$ lies on the angle bisectors of the angles of quadrilateral $A B C D$. So writing $\angle D A B=2 \alpha, \angle A B C=2 \beta, \angle B C D=2 \gamma$, and $\angle C D A=2 \delta$, we have
+
+$$
+\begin{aligned}
+\angle I A P+\angle P B I & =\angle I A B+\angle B A P+\angle P B A+\angle A B I \\
+& =\angle I A B+\angle C D I+\angle I C D+\angle A B I \\
+& =\alpha+\beta+\gamma+\delta .
+\end{aligned}
+$$
+
+We are done because the angles in quadrilateral $A B C D$ add up to $360^{\circ}$.
+
+2. [40] Show that triangle $P A I$ is similar to triangle $B I C$. Then conclude that
+
+$$
+P A=\frac{P I}{B C} \cdot B I
+$$
+
+Solution. We have $\angle I B C=\angle A B I$ because $I$ lies on the angle bisector, and $\angle A B I=\angle A P I$ because $P A I B$ is cyclic. Additionally,
+
+$$
+\angle B C I=\angle I C D=\angle P B A=\angle P I A
+$$
+
+by the angle bisector $C I$, that triangles $P A B$ and $I D C$ are similar, and the fact that $P A I B$ is cyclic, respectively. It follows that triangles $P A I$ and $B I C$ are similar. In particular, it follows that $I P / P A=B C / B I$, as required.
+3. [25] Deduce from the above that
+
+$$
+\frac{B C}{A D} \cdot \frac{A I}{B I} \cdot \frac{D I}{C I}=1
+$$
+
+Solution. Exchanging the roles of $A$ and $D$ with $B$ and $C$, respectively, converts the formula from problem 2 into another formula:
+
+$$
+P B=\frac{P I}{A D} \cdot A D
+$$
+
+Then one the one hand, dividing the two gives $P A / P B=(A D \cdot B I) /(B C \cdot A I)$. On the other hand, $P A / P B=D I / C I$ because triangles $P A B$ and $I D C$ are similar. Clearing the denominators in the equation
+
+$$
+\frac{D I}{C I}=\frac{A D \cdot B I}{B C \cdot A I}
+$$
+
+yields the desired form.
+4. [25] Show that $A B+C D=A D+B C$. Use the above to conclude that for some positive number $\alpha$,
+
+$$
+\begin{array}{ll}
+A B=\alpha \cdot\left(\frac{A I}{C I}+\frac{B I}{D I}\right) & B C=\alpha \cdot\left(\frac{B I}{D I}+\frac{C I}{A I}\right) \\
+C D=\alpha \cdot\left(\frac{C I}{A I}+\frac{D I}{B I}\right) & D A=\alpha \cdot\left(\frac{D I}{B I}+\frac{A I}{C I}\right) .
+\end{array}
+$$
+
+Solution. Draw in the points of tangency $P, Q, R$, and $S$, of the incircle with sides $A B, B C, C D$, and $A D$, as shown. Then we have equal tangents $A P=A S, B P=B Q, C Q=C R$, and $D R=D S$. Then
+
+$$
+A B+C D=A P+B P+C R+D R=A S+(B Q+C Q)+D S=B C+A D
+$$
+
+Using the result of problem 3, we set $B C=x \cdot B I \cdot C I$ and $A D=x \cdot A I \cdot D I$ for some $x$, and $A B=y \cdot A I \cdot B I$ and $C D=y \cdot C I \cdot D I$ for some $y$. Now because $A B+C D=B C+A D$, we obtain
+
+$$
+y(A I \cdot B I+C I \cdot D I)=x(B I \cdot C I+A I \cdot D I)
+$$
+
+So it follows that the ratio $A B: B C: C D: D A$ is uniquely determined. One easily checks that the posed ratio satisfies the three required relations.
+
+5. [40] Show that
+
+$$
+A B \cdot B C=B I^{2}+\frac{A I \cdot B I \cdot C I}{D I}
+$$
+
+Solution. Returning to the original set up, Ptolemy's theorem applied to quadrilateral $P A I B$ gives $A B \cdot P I=P A \cdot B I+P B \cdot A I$. Substituting equation $P A=\frac{P I}{B C} \cdot B I$ from problem 2 and its cousin $P B=\frac{P I}{A D} \cdot A I$ allows us to write
+
+$$
+A B \cdot P I=\frac{P I}{B C} \cdot B I^{2}+\frac{P I}{A D} \cdot A I^{2}
+$$
+
+or
+
+$$
+A B \cdot B C=B I^{2}+\frac{B C}{A D} \cdot A I^{2}
+$$
+
+Substituting the formula $B C / A D=\frac{B I \cdot C I}{A I \cdot D I}$ from problem 3 finishes the problem.
+6. [40] Let the incircle of $A B C D$ be tangent to sides $A B, B C, C D$, and $A D$ at points $P, Q, R$, and $S$, respectively. Show that $A B C D$ is cyclic if and only if $P R \perp Q S$.
+Solution. Let the diagonals of $P Q R S$ intersect at $T$. Because $\overline{A P}$ and $\overline{A S}$ are tangent to $\omega$ at $P$ and $S$, we may write $\alpha=\angle A S P=\angle S P A=\angle S Q P$ and $\beta=\angle C Q R=\angle Q R C=\angle Q P R$. Then $\angle P T Q=\pi-\alpha-\beta$. On the other hand, $\angle P A S=\pi-2 \alpha$ and $\angle R C Q=\pi-2 \beta$, so that $A B C D$ is cyclic if and only if
+
+$$
+\pi=\angle B A D+\angle D C B=2 \pi-2 \alpha-2 \beta
+$$
+
+or simply
+
+$$
+\pi / 2=\pi-\alpha-\beta=\angle P T Q
+$$
+
+as desired.
+
+A brief review of cyclic Quadrilaterals.
+
+The following discussion of cyclic quadrilaterals is included for reference. Any of the results given here may be cited without proof in your writeups.
+A cyclic quadrilateral is a quadrilateral whose four vertices lie on a circle called the circumcircle (the circle is unique if it exists.) If a quadrilateral has a circumcircle, then the center of this circumcircle is called the circumcenter of the quadrilateral. For a convex quadrilateral $A B C D$, the following are equivalent:
+
+- Quadrilateral $A B C D$ is cyclic;
+- $\angle A B D=\angle A C D$ (or $\angle B C A=\angle B D A$, etc.);
+- Angles $\angle A B C$ and $\angle C D A$ are supplementary, that is, $m \angle A B C+m \angle C D A=180^{\circ}$ (or angles $\angle B C D$ and $\angle B A D$ are supplementary);
+
+Cyclic quadrilaterals have a number of interesting properties. A cyclic quadrilateral $A B C D$ satisfies
+
+$$
+A C \cdot B D=A B \cdot C D+A D \cdot B C
+$$
+
+a result known as Ptolemy's theorem. Another result, typically called Power of a Point, asserts that given a circle $\omega$, a point $P$ anywhere in the plane of $\omega$, and a line $\ell$ through $P$ intersecting $\omega$ at points $A$ and $B$, the value of $A P \cdot B P$ is independent of $\ell$; i.e., if a second line $\ell^{\prime}$ through $P$ intersects $\omega$ at $A^{\prime}$ and $B^{\prime}$, then $A P \cdot B P=A^{\prime} P \cdot B^{\prime} P$. This second theorem is proved via similar triangles. Say $P$ lies outside of $\omega$, that $\ell$ and $\ell^{\prime}$ are as before and that $A$ and $A^{\prime}$ lie on segments $B P$ and $B^{\prime} P$ respectively. Then triangle $A A^{\prime} P$ is similar to triangle $B^{\prime} B P$ because the triangles share an angle at $P$ and we have
+
+$$
+m \angle A A^{\prime} P=180^{\circ}-m \angle B^{\prime} A^{\prime} A=m \angle A B B^{\prime}=m \angle P B B^{\prime}
+$$
+
+The case where $A=B$ is valid and describes the tangents to $\omega$. A similar proof works for $P$ inside $\omega$.
+
diff --git a/HarvardMIT/md/en-112-2008-feb-alg-solutions.md b/HarvardMIT/md/en-112-2008-feb-alg-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..b5fe83112399b17e31c0e4e02a151ed4be7f40f3
--- /dev/null
+++ b/HarvardMIT/md/en-112-2008-feb-alg-solutions.md
@@ -0,0 +1,151 @@
+# $11^{\text {th }}$ Annual Harvard-MIT Mathematics Tournament
+
+## Saturday 23 February 2008
+
+## Individual Round: Algebra Test
+
+1. [3] Positive real numbers $x, y$ satisfy the equations $x^{2}+y^{2}=1$ and $x^{4}+y^{4}=\frac{17}{18}$. Find $x y$.
+
+Answer: $\sqrt[\frac{1}{6}]{ }$ We have $2 x^{2} y^{2}=\left(x^{2}+y^{2}\right)^{2}-\left(x^{4}+y^{4}\right)=\frac{1}{18}$, so $x y=\frac{1}{6}$.
+2. [3] Let $f(n)$ be the number of times you have to hit the $\sqrt{ }$ key on a calculator to get a number less than 2 starting from $n$. For instance, $f(2)=1, f(5)=2$. For how many $1
$\qquad$
+
+
+
+Let the incircle touch sides $A C$ and $A B$ at $E$ and $F$ respectively. Note that $E$ and $F$ both lie on the circle with diameter $A I$ since $\angle A E I=\angle A F I=90^{\circ}$. The key observation is that $D, E, P$ are collinear. To prove this, suppose that $P$ lies outside the triangle (the other case is analogous), then $\angle P E A=\angle P I A=\angle I B A+\angle I A B=\frac{1}{2}(\angle B+\angle A)=90^{\circ}-\frac{1}{2} \angle C=\angle D E C$, which implies that $D, E, P$ are collinear. Similarly $D, F, Q$ are collinear. Then, by Power of a Point, $D E \cdot D P=D F \cdot D Q$. So $D P / D Q=D F / D E$.
+Now we compute $D F / D E$. Note that $D F=2 D B \sin \angle D B I=2 \sqrt{6^{2}-3^{2}}\left(\frac{3}{6}\right)=3 \sqrt{3}$, and $D E=$ $2 D C \sin \angle D C I=2 \sqrt{5^{2}-3^{2}}\left(\frac{3}{5}\right)=\frac{24}{5}$. Therefore, $D F / D E=\frac{5 \sqrt{3}}{8}$.
+10. [7] Let $A B C$ be a triangle with $B C=2007, C A=2008, A B=2009$. Let $\omega$ be an excircle of $A B C$ that touches the line segment $B C$ at $D$, and touches extensions of lines $A C$ and $A B$ at $E$ and $F$, respectively (so that $C$ lies on segment $A E$ and $B$ lies on segment $A F$ ). Let $O$ be the center of $\omega$. Let $\ell$ be the line through $O$ perpendicular to $A D$. Let $\ell$ meet line $E F$ at $G$. Compute the length $D G$.
+Answer: 2014024 Let line $A D$ meet $\omega$ again at $H$. Since $A F$ and $A E$ are tangents to $\omega$ and $A D H$ is a secant, we see that $D E H F$ is a harmonic quadrilateral. This implies that the pole of $A D$ with respect to $\omega$ lies on $E F$. Since $\ell \perp A D$, the pole of $A D$ lies on $\ell$. It follows that the pole of $A D$ is $G$.
+
+
+Thus, $G$ must lie on the tangent to $\omega$ at $D$, so $C, D, B, G$ are collinear. Furthermore, since the pencil of lines $(A E, A F ; A D, A G)$ is harmonic, by intersecting it with the line $B C$, we see that $(C, B ; D, G)$ is harmonic as well. This means that
+
+$$
+\frac{B D}{D C} \cdot \frac{C G}{G B}=-1
+$$
+
+(where the lengths are directed.) The semiperimeter of $A B C$ is $s=\frac{1}{2}(2007+2008+2009)=3012$. So $B D=s-2009=1003$ and $C D=s-2008=1004$. Let $x=D G$, then the above equations gives
+
+$$
+\frac{1003}{1004} \cdot \frac{x+1004}{x-1003}=1
+$$
+
+Solving gives $x=2014024$.
+Remark: If you are interested to learn about projective geometry, check out the last chapter of Geometry Revisited by Coxeter and Greitzer or Geometric Transformations III by Yaglom.
+
diff --git a/HarvardMIT/md/en-112-2008-feb-guts-solutions.md b/HarvardMIT/md/en-112-2008-feb-guts-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..9aeb798610c5e6df46cb1f24e9201edd1f94fa2c
--- /dev/null
+++ b/HarvardMIT/md/en-112-2008-feb-guts-solutions.md
@@ -0,0 +1,359 @@
+# $11^{\text {th }}$ Annual Harvard-MIT Mathematics Tournament
+
+Saturday 23 February 2008
+
+## Guts Round
+
+$11^{\text {th }}$ HARVARD-MIT MATHEMATICS TOURNAMENT, 23 FEBRUARY 2008 - GUTS ROUND
+
+1. [5] Determine all pairs $(a, b)$ of real numbers such that $10, a, b, a b$ is an arithmetic progression.
+
+Answer: $(4,-2),\left(\frac{5}{2},-5\right)$ Since $10, a, b$ is an arithmetic progression, we have $a=\frac{1}{2}(10+b)$. Also, we have $a+a b=2 b$, and so $a(1+b)=2 b$. Substituting the expression for $a$ gives $(10+b)(1+b)=4 b$. Solving this quadratic equation gives the solutions $b=-2$ and $b=-5$. The corresponding values for $a$ can be found by $a=\frac{1}{2}(10+b)$.
+2. [5] Given right triangle $A B C$, with $A B=4, B C=3$, and $C A=5$. Circle $\omega$ passes through $A$ and is tangent to $B C$ at $C$. What is the radius of $\omega$ ?
+Answer: $\quad \frac{25}{8}$ Let $O$ be the center of $\omega$, and let $M$ be the midpoint of $A C$. Since $O A=O C$, $O M \perp A C$. Also, $\angle O C M=\angle B A C$, and so triangles $A B C$ and $C M O$ are similar. Then, $C O / C M=$ $A C / A B$, from which we obtain that the radius of $\omega$ is $C O=\frac{25}{8}$.
+3. [5] How many ways can you color the squares of a $2 \times 2008$ grid in 3 colors such that no two squares of the same color share an edge?
+Answer: $2 \cdot 3^{2008}$ Denote the colors $A, B, C$. The left-most column can be colored in 6 ways. For each subsequent column, if the $k$ th column is colored with $A B$, then the $(k+1)$ th column can only be colored with one of $B A, B C, C A$. That is, if we have colored the first $k$ columns, then there are 3 ways to color the $(k+1)$ th column. It follows that the number of ways of coloring the board is $6 \times 3^{2007}$.
+
+## $11^{\text {th }}$ HARVARD-MIT MATHEMATICS TOURNAMENT, 23 FEBRUARY 2008 - GUTS ROUND
+
+4. [6] Find the real solution(s) to the equation $(x+y)^{2}=(x+1)(y-1)$.
+
+Answer: $(-1,1)$ Set $p=x+1$ and $q=y-1$, then we get $(p+q)^{2}=p q$, which simplifies to $p^{2}+p q+q^{2}=0$. Then we have $\left(p+\frac{q}{2}\right)^{2}+\frac{3 q^{2}}{4}$, and so $p=q=0$. Thus $(x, y)=(-1,1)$.
+5. [6] A Vandal and a Moderator are editing a Wikipedia article. The article originally is error-free. Each day, the Vandal introduces one new error into the Wikipedia article. At the end of the day, the moderator checks the article and has a $2 / 3$ chance of catching each individual error still in the article. After 3 days, what is the probability that the article is error-free?
+Answer: $\frac{416}{729}$ Consider the error that was introduced on day 1. The probability that the Moderator misses this error on all three checks is $1 / 3^{3}$, so the probability that this error gets removed is $1-\frac{1}{3^{3}}$. Similarly, the probability that the moderator misses the other two errors are $1-\frac{1}{3^{2}}$ and $1-\frac{1}{3}$. So the probability that the article is error-free is
+
+$$
+\left(1-\frac{1}{3^{3}}\right)\left(1-\frac{1}{3^{2}}\right)\left(1-\frac{1}{3}\right)=\frac{416}{729}
+$$
+
+6. [6] Determine the number of non-degenerate rectangles whose edges lie completely on the grid lines of the following figure.
+
+
+Answer: 297 First, let us count the total number of rectangles in the grid without the hole in the middle. There are $\binom{7}{2}=21$ ways to choose the two vertical boundaries of the rectangle, and there are 21 ways to choose the two horizontal boundaries of the rectangles. This makes $21^{2}=441$ rectangles. However, we must exclude those rectangles whose boundary passes through the center point. We can count these rectangles as follows: the number of rectangles with the center of the grid lying in the interior of its south edge is $3 \times 3 \times 3=27$ (there are three choices for each of the three other edges); the number of rectangles whose south-west vertex coincides with the center is $3 \times 3=9$. Summing over all 4 orientations, we see that the total number of rectangles to exclude is $4(27+9)=144$. Therefore, the answer is $441-144=297$.
+
+## $11^{\text {th }}$ HARVARD-MIT MATHEMATICS TOURNAMENT, 23 FEBRUARY 2008 - GUTS ROUND
+
+7. [6] Given that $x+\sin y=2008$ and $x+2008 \cos y=2007$, where $0 \leq y \leq \pi / 2$, find the value of $x+y$.
+Answer: $2007+\frac{\pi}{2}$ Subtracting the two equations gives $\sin y-2008 \cos y=1$. But since $0 \leq y \leq \pi / 2$, the maximum of $\sin y$ is 1 and the minimum of $\cos y$ is 0 , so we must have $\sin y=1$, so $y=\pi / 2$ and $x+y=2007+\frac{\pi}{2}$.
+8. [6] Trodgor the dragon is burning down a village consisting of 90 cottages. At time $t=0$ an angry peasant arises from each cottage, and every 8 minutes ( 480 seconds) thereafter another angry peasant spontaneously generates from each non-burned cottage. It takes Trodgor 5 seconds to either burn a peasant or to burn a cottage, but Trodgor cannot begin burning cottages until all the peasants around him have been burned. How many seconds does it take Trodgor to burn down the entire village?
+Answer: 1920 We look at the number of cottages after each wave of peasants. Let $A_{n}$ be the number of cottages remaining after $8 n$ minutes. During each 8 minute interval, Trodgor burns a total of $480 / 5=96$ peasants and cottages. Trodgor first burns $A_{n}$ peasants and spends the remaining time burning $96-A_{n}$ cottages. Therefore, as long as we do not reach negative cottages, we have the recurrence relation $A_{n+1}=A_{n}-\left(96-A_{n}\right)$, which is equivalent to $A_{n+1}=2 A_{n}-96$. Computing the first few terms of the series, we get that $A_{1}=84, A_{2}=72, A_{3}=48$, and $A_{4}=0$. Therefore, it takes Trodgor 32 minutes, which is 1920 seconds.
+9. [6] Consider a circular cone with vertex $V$, and let $A B C$ be a triangle inscribed in the base of the cone, such that $A B$ is a diameter and $A C=B C$. Let $L$ be a point on $B V$ such that the volume of the cone is 4 times the volume of the tetrahedron $A B C L$. Find the value of $B L / L V$.
+Answer: $\sqrt{\frac{\pi}{4-\pi}}$ Let $R$ be the radius of the base, $H$ the height of the cone, $h$ the height of the pyramid and let $B L / L V=x / y$. Let [•] denote volume. Then [cone] $=\frac{1}{3} \pi R^{2} H$ and $[A B C L]=\frac{1}{3} \pi R^{2} h$ and $h=\frac{x}{x+y} H$. We are given that $[$ cone $]=4[A B C L]$, so $x / y=\frac{\pi}{4-\pi}$.
+
+## $11^{\text {th }}$ HARVARD-MIT MATHEMATICS TOURNAMENT, 23 FEBRUARY 2008 - GUTS ROUND
+
+10. [7] Find the number of subsets $S$ of $\{1,2, \ldots 63\}$ the sum of whose elements is 2008 .
+
+Answer: 6 Note that $1+2+\cdots+63=2016$. So the problem is equivalent to finding the number of subsets of $\{1,2, \cdots 63\}$ whose sum of elements is 8 . We can count this by hand: $\{8\},\{1,7\},\{2,6\}$, $\{3,5\},\{1,2,5\},\{1,3,4\}$.
+11. [7] Let $f(r)=\sum_{j=2}^{2008} \frac{1}{j^{r}}=\frac{1}{2^{r}}+\frac{1}{3^{r}}+\cdots+\frac{1}{2008^{r}}$. Find $\sum_{k=2}^{\infty} f(k)$.
+
+Answer: $\frac{2007}{2008}$ We change the order of summation:
+$$
+\sum_{k=2}^{\infty} \sum_{j=2}^{2008} \frac{1}{j^{k}}=\sum_{j=2}^{2008} \sum_{k=2}^{\infty} \frac{1}{j^{k}}=\sum_{j=2}^{2008} \frac{1}{j^{2}\left(1-\frac{1}{j}\right)}=\sum_{j=2}^{2008} \frac{1}{j(j-1)}=\sum_{j=2}^{2008}\left(\frac{1}{j-1}-\frac{1}{j}\right)=1-\frac{1}{2008}=\frac{2007}{2008}
+$$
+
+12. [7] Suppose we have an (infinite) cone $\mathcal{C}$ with apex $A$ and a plane $\pi$. The intersection of $\pi$ and $\mathcal{C}$ is an ellipse $\mathcal{E}$ with major axis $B C$, such that $B$ is closer to $A$ than $C$, and $B C=4, A C=5, A B=3$. Suppose we inscribe a sphere in each part of $\mathcal{C}$ cut up by $\mathcal{E}$ with both spheres tangent to $\mathcal{E}$. What is the ratio of the radii of the spheres (smaller to larger)?
+Answer: $\sqrt{\frac{1}{3}}$ It can be seen that the points of tangency of the spheres with $E$ must lie on its major axis due to symmetry. Hence, we consider the two-dimensional cross-section with plane $A B C$. Then the two spheres become the incentre and the excentre of the triangle $A B C$, and we are looking for the ratio of the inradius to the exradius. Let $s, r, r_{a}$ denote the semiperimeter, inradius, and exradius (opposite to $A$ ) of the triangle $A B C$. We know that the area of $A B C$ can be expressed as both $r s$ and $r_{a}(s-|B C|)$, and so $\frac{r}{r_{a}}=\frac{s-|B C|}{s}$. For the given triangle, $s=6$ and $a=4$, so the required ratio is $\frac{1}{3}$.
+$11^{\text {th }}$ HARVARD-MIT MATHEMATICS TOURNAMENT, 23 FEBRUARY 2008 - GUTS ROUND
+13. [8] Let $P(x)$ be a polynomial with degree 2008 and leading coefficient 1 such that
+
+$$
+P(0)=2007, P(1)=2006, P(2)=2005, \ldots, P(2007)=0 .
+$$
+
+Determine the value of $P(2008)$. You may use factorials in your answer.
+Answer: $2008!-1$ Consider the polynomial $Q(x)=P(x)+x-2007$. The given conditions
+ we know that $Q(x)$ is also a polynomial with degree 2008 and leading coefficient 1 . It follows that $Q(x)=x(x-1)(x-2)(x-3) \cdots(x-2007)$. Thus
+
+$$
+P(x)=x(x-1)(x-2)(x-3) \cdots(x-2007)-x+2007 .
+$$
+
+Setting $x=2008$ gives the answer.
+14. [8] Evaluate the infinite sum $\sum_{n=1}^{\infty} \frac{n}{n^{4}+4}$.
+
+Answer: | $\frac{3}{8}$ |
+| :---: |
+| We have |
+
+$$
+\begin{aligned}
+\sum_{n=1}^{\infty} \frac{n}{n^{4}+4} & =\sum_{n=1}^{\infty} \frac{n}{\left(n^{2}+2 n+2\right)\left(n^{2}-2 n+2\right)} \\
+& =\frac{1}{4} \sum_{n=1}^{\infty}\left(\frac{1}{n^{2}-2 n+2}-\frac{1}{n^{2}+2 n+2}\right) \\
+& =\frac{1}{4} \sum_{n=1}^{\infty}\left(\frac{1}{(n-1)^{2}+1}-\frac{1}{(n+1)^{2}+1}\right)
+\end{aligned}
+$$
+
+Observe that the sum telescopes. From this we find that the answer is $\frac{1}{4}\left(\frac{1}{0^{2}+1}+\frac{1}{1^{2}+1}\right)=\frac{3}{8}$.
+15. [8] In a game show, Bob is faced with 7 doors, 2 of which hide prizes. After he chooses a door, the host opens three other doors, of which one is hiding a prize. Bob chooses to switch to another door. What is the probability that his new door is hiding a prize?
+
+Answer: | $\frac{5}{21}$ | If Bob initially chooses a door with a prize, then he will not find a prize by switching. |
+| :---: | :---: | :---: | With probability $5 / 7$ his original door does not hide the prize. After the host opens the three doors, the remaining three doors have equal probability of hiding the prize. Therefore, the probability that Bob finds the prize is $\frac{5}{7} \times \frac{1}{3}=\frac{5}{21}$.
+
+Remark: This problem can be easily recognized as a variation of the classic Monty Hall problem.
+$11^{\text {th }}$ HARVARD-MIT MATHEMATICS TOURNAMENT, 23 FEBRUARY 2008 - GUTS ROUND
+16. [9] Point $A$ lies at $(0,4)$ and point $B$ lies at $(3,8)$. Find the $x$-coordinate of the point $X$ on the $x$-axis maximizing $\angle A X B$.
+Answer: $\quad 5 \sqrt{2}-3$ Let $X$ be a point on the $x$-axis and let $\theta=\angle A X B$. We can easily see that the circle with diameter $A B$ does not meet the $x$-axis, so $\theta \leq \pi$. Thus, maximizing $\theta$ is equivalent to maximizing $\sin \theta$. By the Law of Sines, this in turn is equivalent to minimizing the circumradius of triangle $A B X$. This will occur when the circumcircle of $A B X$ is the smaller of the two circles through $A$ and $B$ tangent to the $x$-axis. So let $X$ now be this point of tangency. Extend line $A B$ to meet the $x$-axis at $C=(-3,0)$; by Power of a Point $C X^{2}=C A \cdot C B=50$ so $C X=5 \sqrt{2}$. Clearly $X$ has larger $x$-coordinate than $C$, so the $x$-coordinate of $X$ is $5 \sqrt{2}-3$.
+17. [9] Solve the equation
+
+$$
+\sqrt{x+\sqrt{4 x+\sqrt{16 x+\sqrt{\ldots+\sqrt{4^{2008} x+3}}}}}-\sqrt{x}=1
+$$
+
+Express your answer as a reduced fraction with the numerator and denominator written in their prime factorization.
+Answer: $\frac{1}{2^{4016}}$ Rewrite the equation to get
+
+$$
+\sqrt{x+\sqrt{4 x+\sqrt{16 x+\sqrt{\ldots+\sqrt{4^{2008} x+3}}}}}=\sqrt{x}+1
+$$
+
+Squaring both sides yields
+
+$$
+\sqrt{4 x+\sqrt{\ldots+\sqrt{4^{2008} x+3}}}=2 \sqrt{x}+1
+$$
+
+Squaring again yields
+
+$$
+\sqrt{16 x+\sqrt{\ldots+\sqrt{4^{2008} x+3}}}=4 \sqrt{x}+1
+$$
+
+One can see that by continuing this process one gets
+
+$$
+\sqrt{4^{2008} x+3}=2^{2008} \sqrt{x}+1
+$$
+
+so that $2 \cdot 2^{2008} \sqrt{x}=2$. Hence $x=4^{-2008}$. It is also easy to check that this is indeed a solution to the original equation.
+18. [9] Let $A B C$ be a right triangle with $\angle A=90^{\circ}$. Let $D$ be the midpoint of $A B$ and let $E$ be a point on segment $A C$ such that $A D=A E$. Let $B E$ meet $C D$ at $F$. If $\angle B F C=135^{\circ}$, determine $B C / A B$.
+Answer: $\frac{\sqrt{13}}{2}$ Let $\alpha=\angle A D C$ and $\beta=\angle A B E$. By exterior angle theorem, $\alpha=\angle B F D+\beta=$ $45^{\circ}+\beta$. Also, note that $\tan \beta=A E / A B=A D / A B=1 / 2$. Thus,
+
+$$
+1=\tan 45^{\circ}=\tan (\alpha-\beta)=\frac{\tan \alpha-\tan \beta}{1+\tan \alpha \tan \beta}=\frac{\tan \alpha-\frac{1}{2}}{1+\frac{1}{2} \tan \alpha}
+$$
+
+Solving for $\tan \alpha$ gives $\tan \alpha=3$. Therefore, $A C=3 A D=\frac{3}{2} A B$. Using Pythagorean Theorem, we find that $B C=\frac{\sqrt{13}}{2} A B$. So the answer is $\frac{\sqrt{13}}{2}$.
+
+## $11^{\text {th }}$ HARVARD-MIT MATHEMATICS TOURNAMENT, 23 FEBRUARY 2008 - GUTS ROUND
+
+19. [10] Let $A B C D$ be a regular tetrahedron, and let $O$ be the centroid of triangle $B C D$. Consider the point $P$ on $A O$ such that $P$ minimizes $P A+2(P B+P C+P D)$. Find $\sin \angle P B O$.
+
+Answer: | $\frac{1}{6}$ |
+| :---: |
+| We translate the problem into one about 2-D geometry. Consider the right triangle | $A B O$, and $P$ is some point on $A O$. Then, the choice of $P$ minimizes $P A+6 P B$. Construct the line $\ell$ through $A$ but outside the triangle $A B O$ so that $\sin \angle(A O, \ell)=\frac{1}{6}$. For whichever $P$ chosen, let $Q$ be the projection of $P$ onto $\ell$, then $P Q=\frac{1}{6} A P$. Then, since $P A+6 P B=6(P Q+P B)$, it is equivalent to minimize $P Q+P B$. Observe that this sum is minimized when $B, P, Q$ are collinear and the line through them is perpendicular to $\ell$ (so that $P Q+P B$ is simply the distance from $B$ to $\ell$ ). Then, $\angle A Q B=90^{\circ}$, and since $\angle A O B=90^{\circ}$ as well, we see that $A, Q, P, B$ are concyclic. Therefore, $\angle P B O=\angle O P A=\angle(A O, \ell)$, and the sine of this angle is therefore $\frac{1}{6}$.
+
+20. [10] For how many ordered triples $(a, b, c)$ of positive integers are the equations $a b c+9=a b+b c+c a$ and $a+b+c=10$ satisfied?
+Answer: 21 Subtracting the first equation from the second, we obtain $1-a-b-c+a b+b c+c a-a b c=$ $(1-a)(1-b)(1-c)=0$. Since $a, b$, and $c$ are positive integers, at least one must equal 1 . Note that $a=b=c=1$ is not a valid triple, so it suffices to consider the cases where exactly two or one of $a, b, c$ are equal to 1 . If $a=b=1$, we obtain $c=8$ and similarly for the other two cases, so this gives 3 ordered triples. If $a=1$, then we need $b+c=9$, which has 6 solutions for $b, c \neq 1$; a similar argument for $b$ and $c$ gives a total of 18 such solutions. It is easy to check that all the solutions we found are actually solutions to the original equations. Adding, we find $18+3=21$ total triples.
+21. [10] Let $A B C$ be a triangle with $A B=5, B C=4$ and $A C=3$. Let $\mathcal{P}$ and $\mathcal{Q}$ be squares inside $A B C$ with disjoint interiors such that they both have one side lying on $A B$. Also, the two squares each have an edge lying on a common line perpendicular to $A B$, and $\mathcal{P}$ has one vertex on $A C$ and $\mathcal{Q}$ has one vertex on $B C$. Determine the minimum value of the sum of the areas of the two squares.
+
+
+Answer: $\frac{144}{49}$ Let the side lengths of $\mathcal{P}$ and $\mathcal{Q}$ be $a$ and $b$, respectively. Label two of the vertices of $\mathcal{P}$ as $D$ and $E$ so that $D$ lies on $A B$ and $E$ lies on $A C$, and so that $D E$ is perpendicular to $A B$. The triangle $A D E$ is similar to $A C B$. So $A D=\frac{3}{4} a$. Using similar arguments, we find that
+
+$$
+\frac{3 a}{4}+a+b+\frac{4 b}{3}=A B=5
+$$
+
+so
+
+$$
+\frac{a}{4}+\frac{b}{3}=\frac{5}{7}
+$$
+
+Using Cauchy-Schwarz inequality, we get
+
+$$
+\left(a^{2}+b^{2}\right)\left(\frac{1}{4^{2}}+\frac{1}{3^{2}}\right) \geq\left(\frac{a}{4}+\frac{b}{3}\right)^{2}=\frac{25}{49}
+$$
+
+It follows that
+
+$$
+a^{2}+b^{2} \geq \frac{144}{49}
+$$
+
+Equality occurs at $a=\frac{36}{35}$ and $b=\frac{48}{35}$.
+
+$$
+11^{\text {th }} \text { HARVARD-MIT MATHEMATICS TOURNAMENT, } 23 \text { FEBRUARY } 2008 \text { - GUTS ROUND }
+$$
+
+22. [10] For a positive integer $n$, let $\theta(n)$ denote the number of integers $0 \leq x<2010$ such that $x^{2}-n$ is divisible by 2010. Determine the remainder when $\sum_{n=0}^{2009} n \cdot \theta(n)$ is divided by 2010.
+Answer: 335 Let us consider the sum $\sum_{n=0}^{2009} n \cdot \theta(n)(\bmod 2010)$ in a another way. Consider the sum $0^{2}+1^{2}+2^{2}+\cdots+2007^{2}(\bmod 2010)$. For each $0 \leq n<2010$, in the latter sum, the term $n$ appears $\theta(n)$ times, so the sum is congruent to $\sum_{n=0}^{2009} n \cdot \theta(n)$. In other words,
+
+$$
+\sum_{n=0}^{2009} n \cdot \theta(n)=\sum_{n=0}^{2009} n^{2}=\frac{(2009)(2009+1)(2 \cdot 2009+1)}{6} \equiv(-1) \cdot \frac{2010}{6} \cdot(-1)=335 \quad(\bmod 2010)
+$$
+
+23. [10] Two mathematicians, Kelly and Jason, play a cooperative game. The computer selects some secret positive integer $n<60$ (both Kelly and Jason know that $n<60$, but that they don't know what the value of $n$ is). The computer tells Kelly the unit digit of $n$, and it tells Jason the number of divisors of $n$. Then, Kelly and Jason have the following dialogue:
+Kelly: I don't know what $n$ is, and I'm sure that you don't know either. However, I know that $n$ is divisible by at least two different primes.
+Jason: Oh, then I know what the value of $n$ is.
+Kelly: Now I also know what $n$ is.
+Assuming that both Kelly and Jason speak truthfully and to the best of their knowledge, what are all the possible values of $n$ ?
+Answer: 10 The only way in which Kelly can know that $n$ is divisible by at least two different primes is if she is given 0 as the unit digit of $n$, since if she received anything else, then there is some number with that unit digit and not divisible by two primes (i.e., $1,2,3,4,5,16,7,8,9$ ). Then, after Kelly says the first line, Jason too knows that $n$ is divisible by 10 .
+The number of divisors of $10,20,30,40,50$ are $4,6,8,8,6$, respectively. So unless Jason received 4 , he cannot otherwise be certain of what $n$ is. It follows that Jason received 4 , and thus $n=10$.
+24. [10] Suppose that $A B C$ is an isosceles triangle with $A B=A C$. Let $P$ be the point on side $A C$ so that $A P=2 C P$. Given that $B P=1$, determine the maximum possible area of $A B C$.
+Answer: $\sqrt{\frac{9}{10}}$ Let $Q$ be the point on $A B$ so that $A Q=2 B Q$, and let $X$ be the intersection of $B P$ and $C Q$. The key observation that, as we will show, $B X$ and $C X$ are fixed lengths, and the ratio of areas $[A B C] /[B C X]$ is constant. So, to maximize $[A B C]$, it is equivalent to maximize $[B C X]$.
+Using Menelaus' theorem on $A B P$, we have
+
+$$
+\frac{B X \cdot P C \cdot A Q}{X P \cdot C A \cdot Q B}=1
+$$
+
+Since $P C / C A=1 / 3$ and $A Q / Q B=2$, we get $B X / X P=3 / 2$. It follows that $B X=3 / 5$. By symmetry, $C X=3 / 5$.
+Also, we have
+
+$$
+[A B C]=3[B P C]=3 \cdot \frac{5}{3}[B X C]=5[B X C]
+$$
+
+Note that $[B X C]$ is maximized when $\angle B X C=90^{\circ}$ (one can check that this configuration is indeed possible). Thus, the maximum value of $[B X C]$ is $\frac{1}{2} B X \cdot C X=\frac{1}{2}\left(\frac{3}{5}\right)^{2}=\frac{9}{50}$. It follows that the maximum value of $[A B C]$ is $\frac{9}{10}$.
+
+## $11^{\text {th }}$ HARVARD-MIT MATHEMATICS TOURNAMENT, 23 FEBRUARY 2008 - GUTS ROUND
+
+25. [12] Alice and the Cheshire Cat play a game. At each step, Alice either (1) gives the cat a penny, which causes the cat to change the number of (magic) beans that Alice has from $n$ to $5 n$ or (2) gives the cat a nickel, which causes the cat to give Alice another bean. Alice wins (and the cat disappears) as soon as the number of beans Alice has is greater than 2008 and has last two digits 42 . What is the minimum number of cents Alice can spend to win the game, assuming she starts with 0 beans?
+Answer: 35 Consider the number of beans Alice has in base 5 . Note that $2008=31013_{5}, 42=132_{5}$, and $100=400_{5}$. Now, suppose Alice has $d_{k} \cdots d_{2} d_{1}$ beans when she wins; the conditions for winning mean that these digits must satisfy $d_{2} d_{1}=32, d_{k} \cdots d_{3} \geq 310$, and $d_{k} \cdots d_{3}=4 i+1$ for some $i$. To gain these $d_{k} \cdots d_{2} d_{1}$ beans, Alice must spend at least $5\left(d_{1}+d_{2}+\cdots+d_{k}\right)+k-1$ cents (5 cents to get each bean in the "units digit" and $k-1$ cents to promote all the beans). We now must have $k \geq 5$ because $d_{k} \cdots d_{2} d_{1}>2008$. If $k=5$, then $d_{k} \geq 3$ since $d_{k} \cdots d_{3} \geq 3100$; otherwise, we have $d_{k} \geq 1$. Therefore, if $k=5$, we have $5\left(d_{1}+d_{2}+\cdots+d_{k}\right)+k-1 \geq 44>36$; if $k>5$, we have $5\left(d_{1}+d_{2}+\cdots+d_{k}\right)+k-1 \geq 30+k-1 \geq 35$. But we can attain 36 cents by taking $d_{k} \cdots d_{3}=1000$, so this is indeed the minimum.
+26. [12] Let $\mathcal{P}$ be a parabola, and let $V_{1}$ and $F_{1}$ be its vertex and focus, respectively. Let $A$ and $B$ be points on $\mathcal{P}$ so that $\angle A V_{1} B=90^{\circ}$. Let $\mathcal{Q}$ be the locus of the midpoint of $A B$. It turns out that $\mathcal{Q}$ is also a parabola, and let $V_{2}$ and $F_{2}$ denote its vertex and focus, respectively. Determine the ratio $F_{1} F_{2} / V_{1} V_{2}$.
+Answer: $\frac{7}{8}$ Since all parabolas are similar, we may assume that $\mathcal{P}$ is the curve $y=x^{2}$. Then, if $A=\left(a, a^{2}\right)$ and $B=\left(b, b^{2}\right)$, the condition that $\angle A V_{1} B=90^{\circ}$ gives $a b+a^{2} b^{2}=0$, or $a b=-1$. Then, the midpoint of $A B$ is
+
+$$
+\frac{A+B}{2}=\left(\frac{a+b}{2}, \frac{a^{2}+b^{2}}{2}\right)=\left(\frac{a+b}{2}, \frac{(a+b)^{2}-2 a b}{2}\right)=\left(\frac{a+b}{2}, \frac{(a+b)^{2}}{2}+1\right) .
+$$
+
+(Note that $a+b$ can range over all real numbers under the constraint $a b=-1$.) It follows that the locus of the midpoint of $A B$ is the curve $y=2 x^{2}+1$.
+Recall that the focus of $y=a x^{2}$ is $\left(0, \frac{1}{4 a}\right)$. We find that $V_{1}=(0,0), V_{2}=(0,1), F_{1}=\left(0, \frac{1}{4}\right)$, $F_{2}=\left(0,1+\frac{1}{8}\right)$. Therefore, $F_{1} F_{2} / V_{1} V_{2}=\frac{7}{8}$.
+27. [12] Cyclic pentagon $A B C D E$ has a right angle $\angle A B C=90^{\circ}$ and side lengths $A B=15$ and $B C=20$. Supposing that $A B=D E=E A$, find $C D$.
+Answer: 7 By Pythagoras, $A C=25$. Since $\overline{A C}$ is a diameter, angles $\angle A D C$ and $\angle A E C$ are also right, so that $C E=20$ and $A D^{2}+C D^{2}=A C^{2}$ as well. Beginning with Ptolemy's theorem,
+
+$$
+\begin{aligned}
+& (A E \cdot C D+A C \cdot D E)^{2}=A D^{2} \cdot E C^{2}=\left(A C^{2}-C D^{2}\right) E C^{2} \\
+& \quad \Longrightarrow C D^{2}\left(A E^{2}+E C^{2}\right)+2 \cdot C D \cdot A E^{2} \cdot A C+A C^{2}\left(D E^{2}-E C^{2}\right)=0 \\
+& \quad \Longrightarrow C D^{2}+2 C D\left(\frac{A E^{2}}{A C}\right)+D E^{2}-E C^{2}=0
+\end{aligned}
+$$
+
+It follows that $C D^{2}+18 C D-175=0$, from which $C D=7$.
+Remark: A simple trigonometric solution is possible. One writes $\alpha=\angle A C E=\angle E C D \Longrightarrow \angle D A C=$ $90^{\circ}-2 \alpha$ and applies double angle formula.
+
+## $11^{\text {th }}$ HARVARD-MIT MATHEMATICS TOURNAMENT, 23 FEBRUARY 2008 - GUTS ROUND
+
+28. [15] Let $P$ be a polyhedron where every face is a regular polygon, and every edge has length 1. Each vertex of $P$ is incident to two regular hexagons and one square. Choose a vertex $V$ of the polyhedron. Find the volume of the set of all points contained in $P$ that are closer to $V$ than to any other vertex.
+Answer: $\quad \frac{\sqrt{2}}{3}$ Observe that $P$ is a truncated octahedron, formed by cutting off the corners from a regular octahedron with edge length 3 . So, to compute the value of $P$, we can find the volume of the octahedron, and then subtract off the volume of truncated corners. Given a square pyramid where each triangular face an equilateral triangle, and whose side length is $s$, the height of the pyramid is $\frac{\sqrt{2}}{2} s$, and thus the volume is $\frac{1}{3} \cdot s^{2} \cdot \frac{\sqrt{2}}{2} s=\frac{\sqrt{2}}{6} s^{3}$. The side length of the octahedron is 3 , and noting that the octahedron is made up of two square pyramids, its volume must be is $2 \cdot \frac{\sqrt{2}(3)^{3}}{6}=9 \sqrt{2}$. The six "corners" that we remove are all square pyramids, each with volume $\frac{\sqrt{2}}{6}$, and so the resulting polyhedron $P$ has volume $9 \sqrt{2}-6 \cdot \frac{\sqrt{2}}{6}=8 \sqrt{2}$.
+Finally, to find the volume of all points closer to one particular vertex than any other vertex, note that due to symmetry, every point in $P$ (except for a set with zero volume), is closest to one of the 24 vertices. Due to symmetry, it doesn't matter which $V$ is picked, so we can just divide the volume of $P$ by 24 to obtain the answer $\frac{\sqrt{2}}{3}$.
+29. [15] Let $(x, y)$ be a pair of real numbers satisfying
+
+$$
+56 x+33 y=\frac{-y}{x^{2}+y^{2}}, \quad \text { and } \quad 33 x-56 y=\frac{x}{x^{2}+y^{2}}
+$$
+
+Determine the value of $|x|+|y|$.
+Answer: $\frac{11}{65}$ Observe that
+
+$$
+\frac{1}{x+y i}=\frac{x-y i}{x^{2}+y^{2}}=33 x-56 y+(56 x+33 y) i=(33+56 i)(x+y i)
+$$
+
+So
+
+$$
+(x+y i)^{2}=\frac{1}{33+56 i}=\frac{1}{(7+4 i)^{2}}=\left(\frac{7-4 i}{65}\right)^{2}
+$$
+
+It follows that $(x, y)= \pm\left(\frac{7}{65},-\frac{4}{65}\right)$.
+30. [15] Triangle $A B C$ obeys $A B=2 A C$ and $\angle B A C=120^{\circ}$. Points $P$ and $Q$ lie on segment $B C$ such that
+
+$$
+\begin{aligned}
+A B^{2}+B C \cdot C P & =B C^{2} \\
+3 A C^{2}+2 B C \cdot C Q & =B C^{2}
+\end{aligned}
+$$
+
+Find $\angle P A Q$ in degrees.
+Answer: $40^{\circ}$ We have $A B^{2}=B C(B C-C P)=B C \cdot B P$, so triangle $A B C$ is similar to triangle $P B A$. Also, $A B^{2}=B C(B C-2 C Q)+A C^{2}=(B C-C Q)^{2}-C Q^{2}+A C^{2}$, which rewrites as $A B^{2}+C Q^{2}=$ $B Q^{2}+A C^{2}$. We deduce that $Q$ is the foot of the altitude from $A$. Thus, $\angle P A Q=90^{\circ}-\angle Q P A=90^{\circ}-$ $\angle A B P-\angle B A P$. Using the similar triangles, $\angle P A Q=90^{\circ}-\angle A B C-\angle B C A=\angle B A C-90^{\circ}=40^{\circ}$.
+
+## $11^{\text {th }}$ HARVARD-MIT MATHEMATICS TOURNAMENT, 23 FEBRUARY 2008 - GUTS ROUND
+
+31. [18] Let $\mathcal{C}$ be the hyperbola $y^{2}-x^{2}=1$. Given a point $P_{0}$ on the $x$-axis, we construct a sequence of points $\left(P_{n}\right)$ on the $x$-axis in the following manner: let $\ell_{n}$ be the line with slope 1 passing passing
+through $P_{n}$, then $P_{n+1}$ is the orthogonal projection of the point of intersection of $\ell_{n}$ and $\mathcal{C}$ onto the $x$-axis. (If $P_{n}=0$, then the sequence simply terminates.)
+Let $N$ be the number of starting positions $P_{0}$ on the $x$-axis such that $P_{0}=P_{2008}$. Determine the remainder of $N$ when divided by 2008.
+Answer: 254 Let $P_{n}=\left(x_{n}, 0\right)$. Then the $\ell_{n}$ meet $\mathcal{C}$ at $\left(x_{n+1}, x_{n+1}-x_{n}\right)$. Since this point lies on the hyperbola, we have $\left(x_{n+1}-x_{n}\right)^{2}-x_{n+1}^{2}=1$. Rearranging this equation gives
+
+$$
+x_{n+1}=\frac{x_{n}^{2}-1}{2 x_{n}}
+$$
+
+Choose a $\theta_{0} \in(0, \pi)$ with $\cot \theta_{0}=x_{0}$, and define $\theta_{n}=2^{n} \theta_{0}$. Using the double-angle formula, we have
+
+$$
+\cot \theta_{n+1}=\cot \left(2 \theta_{n}\right)=\frac{\cot ^{2} \theta_{n}-1}{2 \cot \theta_{n}}
+$$
+
+It follows by induction that $x_{n}=\cot \theta_{n}$. Then, $P_{0}=P_{2008}$ corresponds to $\cot \theta_{0}=\cot \left(2^{2008} \theta_{0}\right)$ (assuming that $P_{0}$ is never at the origin, or equivalently, $2^{n} \theta$ is never an integer multiple of $\pi$ ). So, we need to find the number of $\theta_{0} \in(0, \pi)$ with the property that $2^{2008} \theta_{0}-\theta_{0}=k \pi$ for some integer $k$. We have $\theta_{0}=\frac{k \pi}{2^{2008}-1}$, so $k$ can be any integer between 1 and $2^{2008}-2$ inclusive (and note that since the denominator is odd, the sequence never terminates). It follows that the number of starting positions is $N=2^{2008}-2$.
+Finally, we need to compute the remainder when $N$ is divided by 2008 . We have $2008=2^{3} \times 251$. Using Fermat's Little Theorem with 251 , we get $2^{2008} \equiv\left(2^{250}\right)^{4} \cdot 256 \equiv 1^{4} \cdot 5=5(\bmod 251)$. So we have $N \equiv 3(\bmod 251)$ and $N \equiv-2(\bmod 8)$. Using Chinese Remainder Theorem, we get $N \equiv 254$ $(\bmod 2008)$.
+32. [18] Cyclic pentagon $A B C D E$ has side lengths $A B=B C=5, C D=D E=12$, and $A E=14$. Determine the radius of its circumcircle.
+Answer: $\frac{225 \sqrt{11}}{88}$ Let $C^{\prime}$ be the point on minor arc $B C D$ such that $B C^{\prime}=12$ and $C^{\prime} D=5$, and write $A C^{\prime}=B D=C^{\prime} E=x, A D=y$, and $B D=z$. Ptolemy applied to quadrilaterals $A B C^{\prime} D, B C^{\prime} D E$, and $A B D E$ gives
+
+$$
+\begin{aligned}
+& x^{2}=12 y+5^{2} \\
+& x^{2}=5 z+12^{2} \\
+& y z=14 x+5 \cdot 12
+\end{aligned}
+$$
+
+Then
+
+$$
+\left(x^{2}-5^{2}\right)\left(x^{2}-12^{2}\right)=5 \cdot 12 y z=5 \cdot 12 \cdot 14 x+5^{2} \cdot 12^{2}
+$$
+
+from which $x^{3}-169 x-5 \cdot 12 \cdot 14=0$. Noting that $x>13$, the rational root theorem leads quickly to the root $x=15$. Then triangle $B C D$ has area $\sqrt{16 \cdot 1 \cdot 4 \cdot 11}=8 \sqrt{11}$ and circumradius $R=\frac{5 \cdot 12 \cdot 15}{4 \cdot 8 \sqrt{11}}=$ $\frac{225 \sqrt{11}}{88}$.
+33. [18] Let $a, b, c$ be nonzero real numbers such that $a+b+c=0$ and $a^{3}+b^{3}+c^{3}=a^{5}+b^{5}+c^{5}$. Find the value of $a^{2}+b^{2}+c^{2}$.
+Answer: $\quad \frac{6}{5}$ Let $\sigma_{1}=a+b+c, \sigma_{2}=a b+b c+c a$ and $\sigma_{3}=a b c$ be the three elementary symmetric polynomials. Since $a^{3}+b^{3}+c^{3}$ is a symmetric polynomial, it can be written as a polynomial in $\sigma_{1}, \sigma_{2}$ and $\sigma_{3}$. Now, observe that $\sigma_{1}=0$, and so we only need to worry about the terms not containing $\sigma_{1}$. By considering the degrees of the terms, we see that the only possibility is $\sigma_{3}$. That is, $a^{3}+b^{3}+c^{3}=k \sigma_{3}$ for some constant $k$. By setting $a=b=1, c=-2$, we see that $k=3$.
+By similar reasoning, we find that $a^{5}+b^{5}+c^{5}=h \sigma_{2} \sigma_{3}$ for some constant $h$. By setting $a=b=1$ and $c=-2$, we get $h=-5$.
+
+So, we now know that $a+b+c=0$ implies
+
+$$
+a^{3}+b^{3}+c^{3}=3 a b c \quad \text { and } \quad a^{5}+b^{5}+c^{5}=-5 a b c(a b+b c+c a)
+$$
+
+Then $a^{3}+b^{3}+c^{3}=a^{5}+b^{5}+c^{5}$ implies that $3 a b c=-5 a b c(a b+b c+c a)$. Given that $a, b, c$ are nonzero, we get $a b+b c+c a=-\frac{3}{5}$. Then, $a^{2}+b^{2}+c^{2}=(a+b+c)^{2}-2(a b+b c+c a)=\frac{6}{5}$.
+
+## $11^{\text {th }}$ HARVARD-MIT MATHEMATICS TOURNAMENT, 23 FEBRUARY 2008 - GUTS ROUND
+
+34. Who Wants to Be a Millionaire. In 2000, the Clay Mathematics Institute named seven Millennium Prize Problems, with each carrying a prize of $\$ 1$ Million for its solution. Write down the name of ONE of the seven Clay Millennium Problems. If your submission is incorrect or misspelled, then your submission is disqualified. If another team wrote down the same Millennium Problem as you, then you get 0 points, otherwise you get 20 points.
+
+Solution: The seven Millennium Prize Problems are:
+(a) Birch and Swinnerton-Dyer Conjecture
+(b) Hodge Conjecture
+(c) Navier-Stokes Equations
+(d) P vs NP
+(e) Poincaré Conjecture
+(f) Riemann Hypothesis
+(g) Yang-Mills Theory
+
+More information can be found on its official website http://www.claymath.org/millennium/.
+As far as this as an HMMT problem goes, it's probably a good idea to submit something that you think is least likely for another team to think of (or to spell correctly). Though, this may easily turn into a contest of who can still remember the names of the user ranks from the Art of Problem Solving forum.
+35. NUMB3RS. The RSA Factoring Challenge, which ended in 2007, challenged computational mathematicians to factor extremely large numbers that were the product of two prime numbers. The largest number successfully factored in this challenge was RSA-640, which has 193 decimal digits and carried a prize of $\$ 20,000$. The next challenge number carried prize of $\$ 30,000$, and contains $N$ decimal digits. Your task is to submit a guess for $N$. Only the team(s) that have the closest guess(es) receives points. If $k$ teams all have the closest guesses, then each of them receives $\left\lceil\frac{20}{k}\right\rceil$ points.
+Answer: 212 For more information, see the Wikipedia entry at http://en.wikipedia.org/wiki/ RSA_Factoring_Challenge.
+RSA-640 was factored in November 2005, and the effort took approximately 302.2 GHz -Opteron-CPU years over five months of calendar time.
+36. The History Channel. Below is a list of famous mathematicians. Your task is to list a subset of them in the chronological order of their birth dates. Your submission should be a sequence of letters. If your sequence is not in the correct order, then you get 0 points. Otherwise your score will be $\min \{\max \{5(N-4), 0\}, 25\}$, where $N$ is the number of letters in your sequence.
+(A) Niels Abel (B) Arthur Cayley (C) Augustus De Morgan (D) Gustav Dirichlet (E) Leonhard Euler (F) Joseph Fourier (G) Évariste Galois (H) Carl Friedrich Gauss (I) Marie-Sophie Germain (J) Joseph Louis Lagrange (K) Pierre-Simon Laplace (L) Henri Poincaré (N) Bernhard Riemann
+Answer: any subsequence of EJKFIHADCGBNL The corresponding birth dates are listed below:
+(A) Niels Abel (1802-1829)
+(B) Arthur Cayley (1821-1895)
+(C) Augustus De Morgan (1806-1871)
+(D) Gustav Dirichlet (1805-1859)
+(E) Leonhard Euler (1707-1783)
+(F) Joseph Fourier (1768-1830)
+(G) Évariste Galois (1811-1832)
+(H) Carl Friedrich Gauss (1777-1855)
+(I) Marie-Sophie Germain (1776-1831)
+(J) Joseph Louis Lagrange (1736-1813)
+(K) Pierre-Simon Laplace (1749-1827)
+(L) Henri Poincaré (1854-1912)
+(N) Bernhard Riemann (1826-1866)
+
diff --git a/HarvardMIT/md/en-112-2008-feb-team1-solutions.md b/HarvardMIT/md/en-112-2008-feb-team1-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..ab93caaaa3588e14fff65e0353a6047f15690600
--- /dev/null
+++ b/HarvardMIT/md/en-112-2008-feb-team1-solutions.md
@@ -0,0 +1,170 @@
+# $11^{\text {th }}$ Annual Harvard-MIT Mathematics Tournament
Saturday 23 February 2008
+
+## Team Round: A Division
+
+## Lattice Walks [90]
+
+1. [20] Determine the number of ways of walking from $(0,0)$ to $(5,5)$ using only up and right unit steps such that the path does not pass through any of the following points: $(1,1),(1,4),(4,1),(4,4)$.
+
+
+Answer: 34
+Solution: In the following figure, each lattice point (with the bottom-left-most point $(0,0)$ ) is labeled with the number of ways of reaching there from $(0,0)$. With the exception of the forbidden points, the labels satisfy the recursion formula $f(x, y)=f(x-1, y)+f(x, y-1)$. We see from the diagram that there are 34 ways to reach $(5,5)$.
+
+| 1 | 1 | 5 | 17 | 17 | 34 |
+| :--- | :--- | :--- | :--- | :--- | :--- | :--- |
+| 1 | 0 | 4 | 12 | 0 | 17 |
+| 1 | 2 | 4 | 8 | 12 | 17 |
+| 1 | 1 | 2 | 4 | 4 | 5 |
+| 1 | 0 | 1 | 2 | 0 | 1 |
+| 1 | 1 | 1 | 1 | 1 | 1 |
+
+2. [20] Let $n>2$ be a positive integer. Prove that there are $\frac{1}{2}(n-2)(n+1)$ ways to walk from $(0,0)$ to $(n, 2)$ using only up and right unit steps such that the walk never visits the line $y=x$ after it leaves the origin.
+
+Solution: The first two steps can only go to the right. Then we need to compute the number of ways of walking from $(2,0)$ to $(n, 2)$ which does not pass through the point $(2,2)$. There are $\binom{n}{2}$ ways to walk from $(2,0)$ to $(n, 2)$, and exactly one of those paths passes through the point (2,2). So the number of valid paths is $\binom{n}{2}-1=\frac{1}{2} n(n-1)-1=\frac{1}{2}(n-2)(n+1)$.
+
+Remark: We used the well-known fact that there are $\binom{a+b}{a}$ ways to walk from $(0,0)$ to $(a, b)$ using only up and right unit steps. This is true because there are $a+b$ steps, and we need to choose $a$ of them to be right steps, and the rest up steps.
+3. [20] Let $n>4$ be a positive integer. Determine the number of ways to walk from $(0,0)$ to $(n, 2)$ using only up and right unit steps such that the path does not meet the lines $y=x$ or $y=x-n+2$ except at the start and at the end.
+
+Answer: $\frac{1}{2}\left(n^{2}-5 n+2\right)$
+Solution: It is easy to see the the first two steps and the last two steps must all be right steps. So we need to compute the number of walks from $(2,0)$ to $(n-2,0)$ that does not pass through $(2,2)$ and $(n-2,0)$. There are $\binom{n-2}{2}$ paths from $(2,0)$ to $(n-2,0)$, and exactly two of them are invalid. So the answer is $\binom{n-2}{2}-2=\frac{1}{2}(n-2)(n-3)-2=\frac{1}{2}\left(n^{2}-5 n+2\right)$.
+4. [30] Let $n>6$ be a positive integer. Determine the number of ways to walk from $(0,0)$ to $(n, 3)$ using only up and right unit steps such that the path does not meet the lines $y=x$ or $y=x-n+3$ except at the start and at the end.
+Answer: $\quad \frac{1}{6}(n-6)(n-1)(n+1)$ Consider the first point of the path that lies on $x=3$. There are two possibilities for this point: $(3,0)$ and $(3,1)$, and there is exactly one valid way of getting to each point from the origin. Similarly, consider the last point of the path that lies on $x=n-3$. There are two possibilities: $(n-3,2)$ and $(n-3,3)$, and there is exactly one valid way of getting to the destination from each of the two points. Now we count the number of valid paths from each of $(3,0)$ and $(3,1)$, to each of $(n-3,2)$ and $(n-3,3)$, and the answer will be the sum.
+
+- From $(3,1)$ to $(n-3,2)$ : there are no forbidden points along the way, so there are $n-5$ ways.
+- From $(3,0)$ to $(n-3,2)$ : the path must not pass through $(n-3,0)$, and there is exactly one invalid path. So there are $\binom{n-4}{2}-1$ ways.
+- From $(3,1)$ to $(n-3,3)$ : the path must not pass through $(3,3)$, and there is exactly one invalid path. So there are $\binom{n-4}{2}-1$ ways.
+- From $(3,0)$ to $(n-3,3)$ : the path must not pass through $(n-3,0)$ and $(3,3)$, and there are exactly two invalid paths. So there are $\binom{n-3}{3}-2$ ways.
+
+Summing, we obtain the answer:
+$n-5+\binom{n-4}{2}-1+\binom{n-4}{2}-1+\binom{n-3}{3}-2=\frac{n^{3}-6 n^{2}-n+6}{6}=\frac{(n-6)(n-1)(n+1)}{6}$.
+
+## Lattice and Centroids [130]
+
+A d-dimensional lattice point is a point of the form $\left(x_{1}, x_{2}, \ldots, x_{d}\right)$ where $x_{1}, x_{2}, \ldots, x_{d}$ are all integers. For a set of $d$-dimensional points, their centroid is the point found by taking the coordinatewise average of the given set of points.
+Let $f(n, d)$ denote the minimal number $f$ such that any set of $f$ lattice points in the $d$-dimensional Euclidean space contains a subset of size $n$ whose centroid is also a lattice point.
+5. [10] Let $S$ be a set of 5 points in the 2 -dimensional lattice. Show that we can always choose a pair of points in $S$ whose midpoint is also a lattice point.
+
+Solution: Consider the parities of the coordinates. There are four possibilities: (odd, odd), (odd, even), (even, odd), (even, even). By the pigeonhole principle, two of the points must have the same parity in both coordinates (i.e., they are congruent in mod 2). Then, the midpoint of these two points must be a lattice point.
+6. [10] Construct a set of $2^{d} d$-dimensional lattice points so that for any two chosen points $A, B$, the line segment $A B$ does not pass through any other lattice point.
+
+Solution: The simplest example is the set of $2^{d}$ points of the form $\left(a_{1}, a_{2}, \ldots, a_{d}\right)$, where $a_{k} \in\{0,1\}$ for each $k$. This is the set of vertices of a $d$-dimensional cube.
+7. [35] Show that for positive integers $n$ and $d$,
+
+$$
+(n-1) 2^{d}+1 \leq f(n, d) \leq(n-1) n^{d}+1 .
+$$
+
+Solution: Note that taking the set of points to be a multiset does not affect $f(n, d)$ as adding multiples of $n$ to any of the coordinate values does not change the result. The lower bound is obtained by considering the multiset consisting of $n-1$ copies of each of the $2^{d}$ 0,1 -vectors of length $d$, as it contains no submultiset of size $n$ whose centroid is also a lattice point. By the pigeonhole principle, any multiset of $(n-1) n^{d}+1$ lattice points must contain $n$ points whose coordinates are congruent modulo $n$. The centroid of these $n$ points is also a lattice point, thus proving the upper bound.
+8. [40] Show that for positive integers $n_{1}, n_{2}$ and $d$,
+
+$$
+f\left(n_{1} n_{2}, d\right) \leq f\left(n_{1}, d\right)+n_{1}\left(f\left(n_{2}, d\right)-1\right)
+$$
+
+Solution: Given a multiset of $f\left(n_{1}, d\right)+n_{1}\left(f\left(n_{2}, d\right)-1\right)$ lattice points, we may select $l=f\left(n_{2}, d\right)$ pairwise disjoint submultisets $S_{1}, S_{2}, \ldots, S_{l}$, each consisting of $n_{1}$ points, whose centroid is a lattice point. Let $\varphi$ map each multiset $S_{i}$ to its centroid $g_{i}$. By the definition of $f\left(n_{2}, d\right)$, there exists a submultiset $T \subset\left\{g_{1}, g_{2}, \ldots, g_{l}\right\}$ satisfying $|T|=n_{2}$ whose centroid is a lattice point. Then $\bigcup_{i \in T} \varphi^{-1}\left(g_{i}\right)$ is a multiset of $n_{1} n_{2}$ lattice points whose centroid is also a lattice point.
+9. [35] Determine, with proof, a simple closed-form expression for $f\left(2^{a}, d\right)$.
+
+Answer: $\left(2^{a}-1\right) 2^{d}+1$
+Solution: From Problem ??, $f\left(2^{a}, d\right) \geq\left(2^{a}-1\right) 2^{d}+1$. We prove by induction on $a$ that $f\left(2^{a}, d\right) \leq\left(2^{a}-1\right) 2^{d}+1$. When $a=1$, Problem ?? shows that $f(2, d) \leq 2^{d}+1$. Fix $a>1$ and suppose that the assertion holds for smaller values of $a$. Using Problem ??,
+
+$$
+\begin{aligned}
+f\left(2^{a}, d\right) & \leq f(2, d)+2\left(f\left(2^{a-1}, d\right)-1\right) \\
+& \leq 2^{d}+1+2 \cdot\left(2^{a-1}-1\right) 2^{d} \\
+& =\left(2^{a}-1\right) 2^{d}+1 .
+\end{aligned}
+$$
+
+Thus $f\left(2^{a}, d\right)=\left(2^{a}-1\right) 2^{d}+1$.
+
+## Incircles [180]
+
+In the following problems, $A B C$ is a triangle with incenter $I$. Let $D, E, F$ denote the points where the incircle of $A B C$ touches sides $B C, C A, A B$, respectively.
+
+
+At the end of this section you can find some terminology and theorems that may be helpful to you.
+10. On the circumcircle of $A B C$, let $A^{\prime}$ be the midpoint of arc $B C$ (not containing $A$ ).
+(a) $[\mathbf{1 0}]$ Show that $A, I, A^{\prime}$ are collinear.
+(b) $[\mathbf{2 0}]$ Show that $A^{\prime}$ is the circumcenter of BIC.
+
+## Solution:
+
+
+(a) Since $A^{\prime}$ bisectors the arc $B C$, the two arcs $A^{\prime} B$ and $A^{\prime} C$ are equal, and so $\angle B A A^{\prime}=$ $\angle C A A^{\prime}$. Thus, $A^{\prime}$ lies on the angle bisector of $B A C$. Since $I$ also lies on the angle bisector of $B A C$, we see that $A, I, A^{\prime}$ are collinear.
+(b) We have
+
+$$
+\angle C I A^{\prime}=\angle A^{\prime} A C+\angle I C A=\angle A^{\prime} A B+\angle I C B=\angle A^{\prime} C B+\angle I C B=\angle I C A^{\prime} .
+$$
+
+Therefore, $A^{\prime} I=A^{\prime} C$. By similar arguments, $A^{\prime} I=A^{\prime} B$. So, $A^{\prime}$ is equidistant from $B, I, C$, and thus is its circumcenter.
+11. [30] Let lines $B I$ and $E F$ meet at $K$. Show that $I, K, E, C, D$ are concyclic.
+
+Solution: First, note that there are two possible configurations, as $K$ could lie inside segment $E F$, or on its extension. The following proof works for both cases. We have
+
+
+$$
+\angle K I C=\angle I B C+\angle I C B=\frac{1}{2} \angle A B C+\frac{1}{2} \angle A C B=90^{\circ}-\frac{1}{2} \angle B A C=\angle A E F .
+$$
+
+It follows that $I, K, E, C$ are concyclic. The point $D$ also lies on this circle because $\angle I D C=$ $\angle I E C=90^{\circ}$. Thus, all five points are concyclic.
+12. [40] Let $K$ be as in the previous problem. Let $M$ be the midpoint of $B C$ and $N$ the midpoint of $A C$. Show that $K$ lies on line $M N$.
+
+Solution: Since $I, K, E, C$ are concyclic, we have $\angle I K C=\angle I E C=90^{\circ}$. Let $C^{\prime}$ be the reflection of $C$ across $B I$, then $C^{\prime}$ must lie on $A B$. Then, $K$ is the midpoint of $C C^{\prime}$. Consider a dilation centered at $C$ with factor $\frac{1}{2}$. Since $C^{\prime}$ lies on $A B$, it follows that $K$ lies on $M N$.
+
+13. [40] Let $M$ be the midpoint of $B C$, and $T$ diametrically opposite to $D$ on the incircle of $A B C$. Show that $D T, A M, E F$ are concurrent.
+
+Solution: If $A B=A C$, then the result is clear as $A M$ and $D T$ coincide. So, assume that $A B \neq A C$.
+
+
+Let lines $D T$ and $E F$ meet at $Z$. Construct a line through $Z$ parallel to $B C$, and let it meet $A B$ and $A C$ at $X$ and $Y$, respectively. We have $\angle X Z I=90^{\circ}$, and $\angle X F I=90^{\circ}$. Therefore, $F, Z, I, X$ are concyclic, and thus $\angle I X Z=\angle I F Z$. By similar arguments, we also have $\angle I Y Z=\angle I E Z$. Thus, triangles $I F E$ and $I X Y$ are similar. Since $I E=I F$, we must also have $I X=I Y$. Since $I Z$ is an altitude of the isosceles triangle $I X Y, Z$ is the midpoint of $X Y$.
+
+Since $X Y$ and $B C$ are parallel, there is a dilation centered at $A$ that sends $X Y$ to $B C$. So it must send the midpoint $Z$ to the midpoint $M$. Therefore, $A, Z, M$ are collinear. It follows that $D T, A M, E F$ are concurrent.
+14. [40] Let $P$ be a point inside the incircle of $A B C$. Let lines $D P, E P, F P$ meet the incircle again at $D^{\prime}, E^{\prime}, F^{\prime}$. Show that $A D^{\prime}, B E^{\prime}, C F^{\prime}$ are concurrent.
+
+Solution: Using the trigonometric version of Ceva's theorem, it suffices to prove that
+
+$$
+\frac{\sin \angle B A D^{\prime}}{\sin \angle D^{\prime} A C} \cdot \frac{\sin \angle C B E^{\prime}}{\sin \angle E^{\prime} B A} \cdot \frac{\sin \angle A C F^{\prime}}{\sin \angle F^{\prime} C B}=1 .
+$$
+
+
+
+Using sine law, we have
+
+$$
+\sin \angle B A D^{\prime}=\frac{F D^{\prime}}{A D^{\prime}} \cdot \sin \angle A F D^{\prime}=\frac{F D^{\prime}}{A D^{\prime}} \cdot \sin \angle F D D^{\prime}
+$$
+
+Let $r$ be the inradius of $A B C$. Using the extended sine law, we have $F D^{\prime}=2 r \sin \angle F D D^{\prime}$. Therefore,
+
+$$
+\sin \angle B A D^{\prime}=\frac{2 r}{A D^{\prime}} \cdot \sin ^{2} \angle F D D^{\prime}
+$$
+
+Do this for all the factors in ( $\dagger$ ), and we get
+
+$$
+\frac{\sin \angle B A D^{\prime}}{\sin \angle D^{\prime} A C} \cdot \frac{\sin \angle C B E^{\prime}}{\sin \angle E^{\prime} B A} \cdot \frac{\sin \angle A C F^{\prime}}{\sin \angle F^{\prime} C B}=\left(\frac{\sin \angle F D D^{\prime}}{\sin \angle D^{\prime} D E} \cdot \frac{\sin \angle D E E^{\prime}}{\sin \angle E^{\prime} E F} \cdot \frac{\sin \angle E F F^{\prime}}{\sin \angle F^{\prime} F D}\right)^{2}
+$$
+
+Since $D D^{\prime}, E E^{\prime}, F F^{\prime}$ are concurrent, the above expression equals to 1 by using trig Ceva on triangle $D E F$. The result follows.
+
+Remark: This result is known as Steinbart Theorem. Beware that its converse is not completely true. For more information and discussion, see Darij Grinberg's paper "Variations of the Steinbart Theorem" at http://de.geocities.com/darij_grinberg/.
+
+## Glossary and some possibly useful facts
+
+- A set of points is collinear if they lie on a common line. A set of lines is concurrent if they pass through a common point. A set of points are concyclic if they lie on a common circle.
+- Given $A B C$ a triangle, the three angle bisectors are concurrent at the incenter of the triangle. The incenter is the center of the incircle, which is the unique circle inscribed in $A B C$, tangent to all three sides.
+- Ceva's theorem states that given $A B C$ a triangle, and points $X, Y, Z$ on sides $B C, C A, A B$, respectively, the lines $A X, B Y, C Z$ are concurrent if and only if
+
+$$
+\frac{B X}{X B} \cdot \frac{C Y}{Y A} \cdot \frac{A Z}{Z B}=1
+$$
+
+- "Trig" Ceva states that given $A B C$ a triangle, and points $X, Y, Z$ inside the triangle, the lines $A X, B Y, C Z$ are concurrent if and only if
+
+$$
+\frac{\sin \angle B A X}{\sin \angle X A C} \cdot \frac{\sin \angle C B Y}{\sin \angle Y B A} \cdot \frac{\sin \angle A C Z}{\sin \angle Z C B}=1 .
+$$
+
diff --git a/HarvardMIT/md/en-112-2008-feb-team2-solutions.md b/HarvardMIT/md/en-112-2008-feb-team2-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..b530de62e0f7f1d9fa238d71f4ec62cf410c839d
--- /dev/null
+++ b/HarvardMIT/md/en-112-2008-feb-team2-solutions.md
@@ -0,0 +1,239 @@
+# $11^{\text {th }}$ Annual Harvard-MIT Mathematics Tournament Saturday 23 February 2008
+
+Team Round: B Division
+Tropical Mathematics [95]
+
+For real numbers $x$ and $y$, let us consider the two operations $\oplus$ and $\odot$ defined by
+
+$$
+x \oplus y=\min (x, y) \quad \text { and } \quad x \odot y=x+y .
+$$
+
+We also include $\infty$ in our set, and it satisfies $x \oplus \infty=x$ and $x \odot \infty=\infty$ for all $x$. When unspecified, $\odot$ precedes $\oplus$ in the order of operations.
+
+1. [10] (Distributive law) Prove that $(x \oplus y) \odot z=x \odot z \oplus y \odot z$ for all $x, y, z \in \mathbb{R} \cup\{\infty\}$.
+
+Solution: This is equivalent to proving that
+
+$$
+\min (x, y)+z=\min (x+z, y+z) .
+$$
+
+Consider two cases. If $x \leq y$, then $L H S=x+z$ and $R H S=x+z$. If $x>y$, then $L H S=y+z$ and $R H S=y+z$. It follows that $L H S=R H S$.
+2. [10] (Freshman's Dream) Let $z^{n}$ denote $z \odot z \odot z \odot \cdots \odot z$ with $z$ appearing $n$ times. Prove that $(x \oplus y)^{n}=x^{n} \oplus y^{n}$ for all $x, y \in \mathbb{R} \cup\{\infty\}$ and positive integer $n$.
+
+Solution: Without loss of generality, suppose that $x \leq y$, then $L H S=\min (x, y)^{n}=x^{n}=$ $n x$, and RHS $=\min \left(x^{n}, y^{n}\right)=\min (n x, n y)=n x$.
+3. [35] By a tropical polynomial we mean a function of the form
+
+$$
+p(x)=a_{n} \odot x^{n} \oplus a_{n-1} \odot x^{n-1} \oplus \cdots \oplus a_{1} \odot x \oplus a_{0}
+$$
+
+where exponentiation is as defined in the previous problem.
+Let $p$ be a tropical polynomial. Prove that
+
+$$
+p\left(\frac{x+y}{2}\right) \geq \frac{p(x)+p(y)}{2}
+$$
+
+for all $x, y \in \mathbb{R} \cup\{\infty\}$. (This means that all tropical polynomials are concave.)
+Solution: First, note that for any $x_{1}, \ldots, x_{n}, y_{1}, \ldots, y_{n}$, we have
+
+$$
+\min \left\{x_{1}+y_{1}, x_{2}+y_{2}, \ldots, x_{n}+y_{n}\right\} \geq \min \left\{x_{1}, x_{2}, \ldots, x_{n}\right\}+\min \left\{y_{1}, y_{2}, \ldots, y_{n}\right\} .
+$$
+
+Indeed, suppose that $x_{m}+y_{m}=\min _{i}\left\{x_{i}+y_{i}\right\}$, then $x_{m} \geq \min _{i} x_{i}$ and $y_{m} \geq \min _{i} y_{i}$, and so $\min _{i}\left\{x_{i}+y_{i}\right\}=x_{m}+y_{m} \geq \min _{i} x_{i}+\min _{i} y_{i}$.
+Now, let us write a tropical polynomial in a more familiar notation. We have
+
+$$
+p(x)=\min _{0 \leq k \leq n}\left\{a_{k}+k x\right\} .
+$$
+
+So
+
+$$
+\begin{aligned}
+p\left(\frac{x+y}{2}\right) & =\min _{0 \leq k \leq n}\left\{a_{k}+k\left(\frac{x+y}{2}\right)\right\} \\
+& =\frac{1}{2} \min _{0 \leq k \leq n}\left\{\left(a_{k}+k x\right)+\left(a_{k}+k y\right)\right\} \\
+& \geq \frac{1}{2}\left(\min _{0 \leq k \leq n}\left\{a_{k}+k x\right\}+\min _{0 \leq k \leq n}\left\{a_{k}+k y\right\}\right) \\
+& =\frac{1}{2}(p(x)+p(y)) .
+\end{aligned}
+$$
+
+4. [40] (Fundamental Theorem of Algebra) Let $p$ be a tropical polynomial:
+
+$$
+p(x)=a_{n} \odot x^{n} \oplus a_{n-1} \odot x^{n-1} \oplus \cdots \oplus a_{1} \odot x \oplus a_{0}, \quad a_{n} \neq \infty
+$$
+
+Prove that we can find $r_{1}, r_{2}, \ldots, r_{n} \in \mathbb{R} \cup\{\infty\}$ so that
+
+$$
+p(x)=a_{n} \odot\left(x \oplus r_{1}\right) \odot\left(x \oplus r_{2}\right) \odot \cdots \odot\left(x \oplus r_{n}\right)
+$$
+
+for all $x$.
+Solution: Again, we have
+
+$$
+p(x)=\min _{0 \leq k \leq n}\left\{a_{k}+k x\right\} .
+$$
+
+So the graph of $y=p(x)$ can be drawn as follows: first, draw all the lines $y=a_{k}+k x$, $k=0,1, \ldots, n$, then trace out the lowest broken line, which then is the graph of $y=p(x)$.
+So $p(x)$ is piecewise linear and continuous, and has slopes from the set $\{0,1,2, \ldots, n\}$. We know from the previous problem that $p(x)$ is concave, and so its slope must be decreasing (this can also be observed simply from the drawing of the graph of $y=p(x)$ ). Then, let $r_{k}$ denote the $x$-coordinate of the leftmost kink such that the slope of the graph is less than $k$ to the right of this kink. Then, $r_{n} \leq r_{n-1} \leq \cdots \leq r_{1}$, and for $r_{k-1} \leq x \leq r_{k}$, the graph of $p$ is linear with slope $k$. Note that is if possible that $r_{k-1}=r_{k}$, if no segment of $p$ has slope $k$. Also, since $a_{n} \neq \infty$, the leftmost piece of $p(x)$ must have slope $n$, and thus $r_{n}$ exists, and thus all $r_{i}$ exist.
+Now, compare $p(x)$ with
+
+$$
+\begin{aligned}
+q(x) & =a_{n} \odot\left(x \oplus r_{1}\right) \odot\left(x \oplus r_{2}\right) \odot \cdots \odot\left(x \oplus r_{n}\right) \\
+& =a_{n}+\min \left(x, r_{1}\right)+\min \left(x, r_{2}\right)+\cdots+\min \left(x, r_{n}\right) .
+\end{aligned}
+$$
+
+For $r_{k-1} \leq x \leq r_{k}$, the slope of $q(x)$ is $k$, and for $x \leq r_{n}$ the slope of $q$ is $n$ and for $x \geq r_{1}$ the slope of $q$ is 0 . So $q$ is piecewise linear, and of course it is continuous. It follows that the graph of $q$ coincides with that of $p$ up to a translation. By taking any $x
General Test
+
+
General Test}
+
+1. [2] Evaluate the sum:
+
+$$
+11^{2}-1^{2}+12^{2}-2^{2}+13^{2}-3^{2}+\ldots+20^{2}-10^{2}
+$$
+
+Answer: 2100 This sum can be written as $\sum_{a=1}^{10}(a+10)^{2}-a^{2}=\sum_{a=1}^{10} 10(2 a+10)=10 * 10 *$ $11+10 * 10 * 10=2100$.
+2. [3] Given that $a+b+c=5$ and that $1 \leq a, b, c \leq 2$, what is the minimum possible value of $\frac{1}{a+b}+\frac{1}{b+c}$ ?
+
+Answer: | $\frac{4}{7}$ | If $a>1$ and $b<2$, we can decrease the sum by decreasing $a$ and increasing $b$. You can |
+| :---: | :---: | follow a similar procedure if $c>1$ and $b<2$. Therefore, the sum is minimized when $b=2$. We can then cross-multiply the two fractions and see that we are trying to minimize $\frac{a+c+4}{(a+2)(c+2)}=\frac{7}{(a+2)(c+2)}$. The product of two numbers with a fixed sum is maximized when those two numbers are equal, so $\frac{7}{(a+2)(c+2)}$ is minimized for $a=c=\frac{3}{2}$, which gives us an answer of $\frac{4}{7}$.
+
+3. [3] What is the period of the function $f(x)=\cos (\cos (x))$ ?
+
+Answer: $\pi$ Since $f(x)$ never equals $\cos (1)$ for $x \in(0, \pi)$ but $f(0)=\cos (1)$, the period is at least $\pi$. However, $\cos (x+\pi)=-\cos (x)$, so $\cos (\cos (x+\pi))=\cos (\cos (x))$.
+4. [4] How many subsets $A$ of $\{1,2,3,4,5,6,7,8,9,10\}$ have the property that no two elements of $A$ sum to 11 ?
+Answer: 243 For each element listed, there is exactly one other element such that the two elements sum to 11. Thus, we can list all the 10 numbers above as 5 pairs of numbers, such that each pair sums to 11. The problem then can be solved as follows: in any given subset with no two elements summing to 11 , at most one element from each pair can be present. Thus, there are 3 ways in which each pair can contribute to a given subset (no element, the first element in the pair, or the second element in the pair). Since there are 5 pairs, the total number of ways to construct a subset with no two elements summing to 11 is $3^{5}=243$.
+5. [5] A polyhedron has faces that are all either triangles or squares. No two square faces share an edge, and no two triangular faces share an edge. What is the ratio of the number of triangular faces to the number of square faces?
+
+Answer: | $\frac{4}{3}$ | Let $s$ be the number of square faces and $t$ be the number of triangular faces. Every |
+| :---: | :---: | :---: | edge is adjacent to exactly one square face and one triangular face. Therefore, the number of edges is equal to $4 s$, and it is also equal to $3 t$. Thus $4 s=3 t$ and $\frac{t}{s}=\frac{4}{3}$
+
+6. [5] Find the maximum value of $x+y$, given that $x^{2}+y^{2}-3 y-1=0$.
+
+Answer: $\frac{\sqrt{26}+3}{2}$ We can rewrite $x^{2}+y^{2}-3 y-1=0$ as $x^{2}+\left(y-\frac{3}{2}\right)^{2}=\frac{13}{4}$. We then see that the set of solutions to $x^{2}-y^{2}-3 y-1=0$ is the circle of radius $\frac{\sqrt{13}}{2}$ and center $\left(0, \frac{3}{2}\right)$. This can be written as $x=\frac{\sqrt{13}}{2} \cos (\theta)$ and $y=\frac{\sqrt{13}}{2} \sin (\theta)+\frac{3}{2}$. Thus, $x+y=\frac{3}{2}+\frac{\sqrt{13}}{2}(\cos (\theta)+\sin (\theta))=\frac{3}{2}+\frac{\sqrt{13}}{2} \sqrt{2} \sin \left(\theta+45^{\circ}\right)$, which is maximized for $\theta=45^{\circ}$ and gives $\frac{\sqrt{26}+3}{2}$. (We could also solve this geometrically by noting that if $x+y$ attains a maximum value of $s$ then the line $x+y=s$ is tangent to the circle.)
+7. [6] There are 15 stones placed in a line. In how many ways can you mark 5 of these stones so that there are an odd number of stones between any two of the stones you marked?
+Answer: 77 Number the stones 1 through 15 in order. We note that the condition is equivalent to stipulating that the stones have either all odd numbers or all even numbers. There are $\binom{8}{5}$ ways to choose 5 odd-numbered stones, and $\binom{7}{5}$ ways to choose all even-numbered stones, so the total number
+of ways to pick the stones is $\binom{8}{5}+\binom{7}{5}=77$. $\binom{n}{k}$ is the number of ways to choose $k$ out of $n$ items. It equals $\left.\frac{n!}{k!(n-k)!}\right)$.
+8. [7] Let $\triangle A B C$ be an equilateral triangle with height 13 , and let $O$ be its center. Point $X$ is chosen at random from all points inside $\triangle A B C$. Given that the circle of radius 1 centered at $X$ lies entirely inside $\triangle A B C$, what is the probability that this circle contains $O$ ?
+Answer: $\frac{\sqrt{3} \pi}{100}$ The set of points $X$ such that the circle of radius 1 centered at $X$ lies entirely inside $\triangle A B C$ is itself a triangle, $A^{\prime} B^{\prime} C^{\prime}$, such that $A B$ is parallel to $A^{\prime} B^{\prime}, B C$ is parallel to $B^{\prime} C^{\prime}$, and $C A$ is parallel to $C^{\prime} A^{\prime}$, and furthermore $A B$ and $A^{\prime} B^{\prime}, B C$ and $B^{\prime} C^{\prime}$, and $C A$ and $C^{\prime} A^{\prime}$ are all 1 unit apart. We can use this to calculate that $A^{\prime} B^{\prime} C^{\prime}$ is an equilateral triangle with height 10, and hence has area $\frac{100}{\sqrt{3}}$. On the other hand, the set of points $X$ such that the circle of radius 1 centered at $X$ contains $O$ is a circle of radius 1 , centered at $O$, and hence has area $\pi$. The probability that the circle centered at $X$ contains $O$ given that it also lies in $A B C$ is then the ratio of the two areas, that is, $\frac{\pi}{\frac{100}{\sqrt{3}}}=\frac{\sqrt{3} \pi}{100}$.
+9. [7] A set of points is convex if the points are the vertices of a convex polygon (that is, a non-selfintersecting polygon with all angles less than or equal to $180^{\circ}$ ). Let $S$ be the set of points $(x, y)$ such that $x$ and $y$ are integers and $1 \leq x, y \leq 26$. Find the number of ways to choose a convex subset of $S$ that contains exactly 98 points.
+Answer: 4958 For this problem, let $n=26$. A convex set may be divided into four subsets: a set of points with maximal $y$ coordinate, a set of points with minimal $y$ coordinate, the points to the left of one of these subsets, and the points to the right of one of these subsets (the left, top, right, and bottom of the corresponding convex polygon). Each of these four parts contains at most $n$ points. (All points in the top or bottom have distinct $x$ coordinates while all points in the left or right have distinct $y$ coordinates.) Moreover, there are four corners each of which is contained in two of these regions. This implies that at most $4 n-4$ distinct points are in any convex set. To find a set of size $4 n-6$ we can remove 2 additional points. Either exactly one of the top, bottom, left, or right contains exactly $n-2$ points or some two of them each contain exactly $n-1$ points.
+Any of the $\binom{100}{98}=4950$ sets of 98 points with either $x$ or $y$ coordinate either 1 or 26 have this property. Suppose instead that some of the points have $x$ coordinate and $y$ coordinate both different from 1 and from 26. In this case we can check that it is impossible for one side to have $n-2$ points. If two opposite sides (top/bottom or left/right) have $n-1$ points, then we obtain all the points on the boundary of an $n-1$ by $n$ rectangle (of which there are four). If two adjacent sides (any of the other pairs) have $n-1$ points, then we obtain the points on the boundary of an $n$ by $n$ square with the points $(1,1),(1,2)$, $(2,1)$ missing and the point $(2,2)$ added (or one of its rotations). There are an additional 4 such sets, for a total of 4958.
+10. [8] Compute
+
+$$
+\prod_{n=0}^{\infty}\left(1-\left(\frac{1}{2}\right)^{3^{n}}+\left(\frac{1}{4}\right)^{3^{n}}\right)
+$$
+
+Answer: | $\frac{2}{3}$ |
+| :---: |
+| We can rewrite each term as $\frac{1+\left(\frac{1}{2}\right)^{3^{n+1}}}{1+\left(\frac{1}{2}\right)^{3^{n}}}$. In the infinite product, each term of the form | $1+\left(\frac{1}{2}\right)^{3^{n}}$ with $n>0$ appears once in the numerator and once in the denominator. The only remaining term is $1+\left(\frac{1}{2}\right)^{1}$ in the first denominator.
+
diff --git a/HarvardMIT/md/en-131-2009-nov-gen2-solutions.md b/HarvardMIT/md/en-131-2009-nov-gen2-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..0ec33e6452f165f6a3287dbcc400803027d1fbc9
--- /dev/null
+++ b/HarvardMIT/md/en-131-2009-nov-gen2-solutions.md
@@ -0,0 +1,61 @@
+# $2^{\text {nd }}$ Annual Harvard-MIT November Tournament Saturday 7 November 2009
Theme Round
+
+## Shortest Paths
+
+1. [3] Paul starts with the number 19. In one step, he can add 1 to his number, divide his number by 2 , or divide his number by 3 . What is the minimum number of steps Paul needs to get to 1 ?
+Answer: 6 One possible path is $19 \rightarrow 20 \rightarrow 10 \rightarrow 5 \rightarrow 6 \rightarrow 2 \rightarrow 1$.
+2. [4] You start with a number. Every second, you can add or subtract any number of the form $n$ ! to your current number to get a new number. In how many ways can you get from 0 to 100 in 4 seconds? ( $n!$ is defined as $n \times(n-1) \times(n-2) \times \cdots \times 2 \times 1$, so $1!=1,2!=2,3!=6,4!=24$, etc.)
+Answer: 36 To get to 100 , you have to use one number which is at least $5!=120$, because $24 \times 4=96$, which is less than 100 . If you use $6!=720$ or anything larger, you need to get back from 720 to 100 (or further) in three seconds. Since $3 \cdot 5!<620$, there is no way to do this in 3 seconds. This means you have to use 5 ! at least once. The remaining numbers must get you from 120 to 100 . If you use three numbers all at most 3 !, you can move by at most $3 \cdot 3!=18<120-100$. This means you have to use 4 !. From $120-24=96$, there are two ways to get to 100: adding 6 then subtracting 2 , or adding 2 twice. So, to get to 100 from 0 in four seconds, you must either add 120 , subtract 24 , add 6 , and subtract 2 , or add 120 , subtract 24 , and add 2 twice. You can do these steps in any order, so the first sequence yields 24 paths and the second sequence yields 12 .
+3. [5] Let $C$ be the circle of radius 12 centered at $(0,0)$. What is the length of the shortest path in the plane between $(8 \sqrt{3}, 0)$ and $(0,12 \sqrt{2})$ that does not pass through the interior of $C$ ?
+Answer: $12+4 \sqrt{3}+\pi$ The shortest path consists of a tangent to the circle, a circular arc, and then another tangent. The first tangent, from $(8 \sqrt{3}, 0)$ to the circle, has length $4 \sqrt{3}$, because it is a leg of a 30-60-90 right triangle. The $15^{\circ}$ arc has length $\frac{15}{360}(24 \pi)$, or $\pi$, and the final tangent, to $(0,12 \sqrt{2})$, has length 12.
+4. [6] You are given a $5 \times 6$ checkerboard with squares alternately shaded black and white. The bottomleft square is white. Each square has side length 1 unit. You can normally travel on this board at a speed of 2 units per second, but while you travel through the interior (not the boundary) of a black square, you are slowed down to 1 unit per second. What is the shortest time it takes to travel from the bottom-left corner to the top-right corner of the board?
+Answer: $\frac{1+5 \sqrt{2}}{2}$ It is always faster to take a path around a black square than through it, since the length of the hypotenuse of any right triangle is greater than half the sum of the length of its legs. Therefore, an optimal path always stays on white squares or on boundaries, and the shortest such path has length $1+5 \sqrt{2}$.
+5. [7] The following grid represents a mountain range; the number in each cell represents the height of the mountain located there. Moving from a mountain of height $a$ to a mountain of height $b$ takes $(b-a)^{2}$ time. Suppose that you start on the mountain of height 1 and that you can move up, down, left, or right to get from one mountain to the next. What is the minimum amount of time you need to get to the mountain of height 49 ?
+
+| 1 | 3 | 6 | 10 | 15 | 21 | 28 |
+| :---: | :---: | :---: | :---: | :---: | :---: | :---: |
+| 2 | 5 | 9 | 14 | 20 | 27 | 34 |
+| 4 | 8 | 13 | 19 | 26 | 33 | 39 |
+| 7 | 12 | 18 | 25 | 32 | 38 | 43 |
+| 11 | 17 | 24 | 31 | 37 | 42 | 46 |
+| 16 | 23 | 30 | 36 | 41 | 45 | 48 |
+| 22 | 29 | 35 | 40 | 44 | 47 | 49 |
+
+Answer: 212 Consider the diagonals of the board running up and to the right - so the first diagonal is the square 1 , the second diagonal is the squares 2 and 3 , and so on. The $i$ th ascent is the largest step taken from a square in the $i$ th diagonal to a square in the $i+1$ st. Since you must climb from square 1 to square 49 , the sum of the ascents is at least 48 . Since there are 12 ascents, the average ascent is at least 4.
+
+The 1 st and 12 th ascents are at most 2 , and the 2 nd and 11 th ascents are at most 3 . The 6 th and 7 th ascents are at least 6 , and the 5 th and 8 th ascents are at least 5 . Because $f(x)=x^{2}$ is convex, the sum of squares of the ascents is minimized when they are as close together as possible. One possible shortest path is then $1 \rightarrow 3 \rightarrow 6 \rightarrow 10 \rightarrow 14 \rightarrow 19 \rightarrow 25 \rightarrow 31 \rightarrow 36 \rightarrow 40 \rightarrow 44 \rightarrow 47 \rightarrow 49$, which has ascents of size $2,3,4,4,5,6,6,5,4,4,3$, and 2 . Thus, our answer is 212 , the sums of the squares of these ascents. There are other solutions to this problem. One alternative problem involves computing the shortest path to each square of the graph, recursively, starting from squares 2 and 3 .
+
+## Five Guys
+
+6. [3] There are five guys named Alan, Bob, Casey, Dan, and Eric. Each one either always tells the truth or always lies. You overhear the following discussion between them:
+```
+Alan: "All of us are truth-tellers."
+Bob: "No, only Alan and I are truth-tellers."
+Casey: "You are both liars."
+Dan: "If Casey is a truth-teller, then Eric is too."
+Eric: "An odd number of us are liars."
+```
+
+Who are the liars?
+Answer: Alan, Bob, Dan, and Eric Alan and Bob each claim that both of them are telling the truth, but they disagree on the others. Therefore, they must both be liars, and Casey must be a truth-teller. If Dan is a truth-teller, then so is Eric, but then there would only be two truth-tellers, contradicting Eric's claim. Therefore, Dan is a liar, and so is Eric.
+7. [4] Five guys are eating hamburgers. Each one puts a top half and a bottom half of a hamburger bun on the grill. When the buns are toasted, each guy randomly takes two pieces of bread off of the grill. What is the probability that each guy gets a top half and a bottom half?
+Answer: $\frac{8}{63}$ Say a guy is content if he gets a top half and a bottom half. Suppose, without loss of generality, that the first guy's first piece of bread is a top. Then there is a $\frac{5}{9}$ chance that his second piece of bread is a bottom. By the same reasoning, given that the first guy is content, there is a $\frac{4}{7}$ chance that the second guy is content. Given that the first two guys are content, there is a $\frac{3}{5}$ chance that the third guy is content, and so on. Our final answer is $\frac{5}{9} \cdot \frac{4}{7} \cdot \frac{3}{5} \cdot \frac{2}{3} \cdot \frac{1}{1}=\frac{8}{63}$.
+8. [5] A single burger is not enough to satisfy a guy's hunger. The five guys go to Five Guys' Restaurant, which has 20 different meals on the menu. Each meal costs a different integer dollar amount between $\$ 1$ and $\$ 20$. The five guys have $\$ 20$ to split between them, and they want to use all the money to order five different meals. How many sets of five meals can the guys choose?
+Answer: 7 Suppose the meals, sorted in descending order, cost $5+x_{1}, 4+x_{2}, \ldots, 1+x_{5}$. To satisfy the conditions in the problem, the $x_{i}$ must be a non-increasing sequence of non-negative integers which sums to 5 . Therefore, there is exactly one order for each partition of 5 : order the elements of the partition from largest to smallest and use these parts as the $x_{i}$. For example, the partition $3+2$ corresponds to the order $5+3,4+2,3,2,1$. There are thus 7 orders, corresponding to the 7 partitions of 5 below.
+
+$$
+1+1+1+1+1,1+1+1+2,1+2+2,1+1+3,2+3,1+4,5
+$$
+
+These partitions yield the following seven orders:
+
+$$
+(2,3,4,5,6),(1,3,4,5,7),(1,2,4,6,7),(1,2,3,5,7)
+$$
+
+$(1,2,3,6,8),(1,2,3,5,9),(1,2,3,4,10)$
+9. [6] Five guys each have a positive integer (the integers are not necessarily distinct). The greatest common divisor of any two guys' numbers is always more than 1 , but the greatest common divisor of all the numbers is 1 . What is the minimum possible value of the product of the numbers?
+Answer: 32400 Let $\omega(n)$ be the number of distinct prime divisors of a number. Each of the guys' numbers must have $\omega(n) \geq 2$, since no prime divides all the numbers. Therefore, if the answer has prime factorization $p_{1}^{e_{1}} p_{2}^{e_{2}} \ldots p_{k}^{e_{k}}$, then $e_{1}+e_{2}+\ldots+e_{k} \geq 10$. If $p^{2}$ divided any of the guys' numbers, we could divide their number by $p$ to reduce the product. Therefore we may assume $e_{i} \leq 4$ for each $i$, so the smallest possible product is $2^{4} 3^{4} 5^{2}$. This bound is achievable: give the guys the numbers $10,6,6,6$, and 15 .
+10. [7] Five guys join five girls for a night of bridge. Bridge games are always played by a team of two guys against a team of two girls. The guys and girls want to make sure that every guy and girl play against each other an equal number of times. Given that at least one game is played, what is the least number of games necessary to accomplish this?
+Answer: 25 Suppose that each guy plays each girl $t$ times. Since each guy plays against two girls in one game, the total number of games each guy plays is $\frac{5 t}{2}$. Then the total number of games is $\frac{25 t}{4}$, which is a multiple of 25 and therefore at least 25 . To check that 25 games is enough, we arrange the guys and girls in two circles. A good pair of guys is a pair of guys who are adjacent in the circle; a good pair of girls is defined similarly. There are 5 good pairs of guys and girls - making each good pair of guys play each good pair of girls works.
+
diff --git a/HarvardMIT/md/en-131-2009-nov-guts-solutions.md b/HarvardMIT/md/en-131-2009-nov-guts-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..18a9b84920dace128e80dc7b6d8ea0c496626dc3
--- /dev/null
+++ b/HarvardMIT/md/en-131-2009-nov-guts-solutions.md
@@ -0,0 +1,212 @@
+# $2^{\text {nd }}$ Annual Harvard-MIT November Tournament Saturday 7 November 2009
+
+## Guts Round
+
+$2^{\text {nd }}$ ANNUAL HARVARD-MIT NOVEMBER TOURNAMENT, 7 NOVEMBER 2009 - GUTS ROUND
+
+1. [5] If $f(x)=x /(x+1)$, what is $f(f(f(f(2009))))$ ?
+
+Answer: $\frac{2009}{8037} f(f(x))=\frac{(x /(x+1))}{(x /(x+1))+1}=x / 2 x+1, f(f(f(f(x))))=x / 4 x+1=\frac{2009}{8037}$
+2. [5] A knight begins on the lower-left square of a standard chessboard. How many squares could the knight end up at after exactly 2009 legal knight's moves? (A knight's move is 2 squares either horizontally or vertically, followed by 1 square in a direction perpendicular to the first.)
+Answer: 32 The knight goes from a black square to a white square on every move, or vice versa, so after 2009 moves he must be on a square whose color is opposite of what he started on. So he can only land on half the squares after 2009 moves. Note that he can access any of the 32 squares (there are no other parity issues) because any single jump can also be accomplished in 3 jumps, so with 2009 jumps, he can land on any of the squares of the right color.
+3. [5] Consider a square, inside which is inscribed a circle, inside which is inscribed a square, inside which is inscribed a circle, and so on, with the outermost square having side length 1. Find the difference between the sum of the areas of the squares and the sum of the areas of the circles.
+Answer: $2-\frac{\pi}{2}$
+
+
+The ratio of the area of each square and the circle immediately inside it is $\frac{4}{\pi}$. The total sum of the areas of the squares is $1+\frac{1}{2}+\frac{1}{4}+\ldots=2$. Difference in area is then $2-2 \cdot \frac{4}{\pi}$.
+$2^{\text {nd }}$ ANNUAL HARVARD-MIT NOVEMBER TOURNAMENT, 7 NOVEMBER $2009 —$ GUTS ROUND
+4. [6] A cube has side length 1. Find the product of the lengths of the diagonals of this cube (a diagonal is a line between two vertices that is not an edge).
+Answer: 576 There are 12 diagonals that go along a face and 4 that go through the center of the cube, so the answer is $\sqrt{2}^{12} \cdot \sqrt{3}^{4}=576$.
+5. [6] Tanks has a pile of 5 blue cards and 5 red cards. Every morning, he takes a card and throws it down a well. What is the probability that the first card he throws down and the last card he throws down are the same color?
+
+Answer: | $\frac{4}{9}$ | Once he has thrown the first card down the well, there are 9 remaining cards, and only |
+| :---: | :---: | 4 have the same color as the card that was thrown down. Therefore, the probability that the last card he throws down has the same color is $\frac{4}{9}$.
+
+6. [6] Find the last two digits of $1032^{1032}$. Express your answer as a two-digit number.
+
+Answer: 76 The last two digits of $1032^{1032}$ is the same as the last two digits of $32^{1032}$. The last two digits of $32^{n}$ repeat with a period of four as $32,24,68,76,32,24,68,76, \ldots$.
+$2^{\text {nd }}$ ANNUAL HARVARD-MIT NOVEMBER TOURNAMENT, 7 NOVEMBER 2009 - GUTS ROUND
+7. [7] A computer program is a function that takes in 4 bits, where each bit is either a 0 or a 1 , and outputs TRUE or FALSE. How many computer programs are there?
+Answer: 65536 The function has $2^{4}$ inputs and 2 outputs for each possible input, so the answer is $2^{2^{4}}=2^{16}=65536$.
+8. [7] The angles of a convex $n$-sided polygon form an arithmetic progression whose common difference (in degrees) is a non-zero integer. Find the largest possible value of $n$ for which this is possible. (A polygon is convex if its interior angles are all less than $180^{\circ}$.)
+Answer: 27 The exterior angles form an arithmetic sequence too (since they are each $180^{\circ}$ minus the corresponding interior angle). The sum of this sequence must be $360^{\circ}$. Let the smallest exterior angle be $x$ and the common difference be $d$. The sum of the exterior angles is then $x+(x+a)+(x+$ $2 a)+\ldots+(x+(n-1) a)=\frac{n(n-1)}{2} \cdot a+n x$. Setting this to 360 , and using $n x>0$, we get $n(n-1)<720$, so $n \leq 27$.
+9. [7] Daniel wrote all the positive integers from 1 to $n$ inclusive on a piece of paper. After careful observation, he realized that the sum of all the digits that he wrote was exactly 10,000 . Find $n$.
+Answer: 799 Let $S(n)$ denote the sum of the digits of $n$, and let $f(x)=\sum_{n=0}^{x} S(n)$. (We may add $n=0$ because $S(0)=0$.) Observe that:
+
+$$
+f(99)=\sum_{a=0}^{9}\left(\sum_{b=0}^{9}(a+b)\right)=10 \sum_{b=0}^{9} b+10 \sum_{a=0}^{9} a=900
+$$
+
+If $a$ is an integer between 1 and 9 inclusive, then:
+
+$$
+\sum_{n=100 a}^{100 a+99} S(n)=\sum_{n=100 a}^{100 a+99}(a+S(n-100 a))=100 a+f(99)=100 a+900
+$$
+
+Summing, we get:
+
+$$
+f(100 a+99)=\sum_{n=0}^{a}(100 a+900)=900(a+1)+50 a(a+1)
+$$
+
+This formula can be used to find benchmarks. However, it turns out that this formula alone will suffice, as things turn out rather nicely:
+
+$$
+\begin{aligned}
+900(a+1)+50 a(a+1) & =10000 \\
+50 a^{2}+950 a+900 & =10000 \\
+50 a^{2}+950 a-9100 & =0 \\
+50(a+26)(a-7) & =0 \\
+a & =7
+\end{aligned}
+$$
+
+Therefore $f(799)=10000$, and our answer is 799 .
+
+## $2^{\text {nd }}$ ANNUAL HARVARD-MIT NOVEMBER TOURNAMENT, 7 NOVEMBER 2009 - GUTS ROUND
+
+10. [8] Admiral Ackbar needs to send a 5-character message through hyperspace to the Rebels. Each character is a lowercase letter, and the same letter may appear more than once in a message. When the message is beamed through hyperspace, the characters come out in a random order. Ackbar chooses his message so that the Rebels have at least a $\frac{1}{2}$ chance of getting the same message he sent. How many distinct messages could he send?
+Answer: 26 If there is more than one distinct letter sent in the message, then there will be at most a $1 / 5$ chance of transmitting the right message. So the message must consist of one letter repeated five times, so there are 26 possible messages.
+11. [8] Lily and Sarah are playing a game. They each choose a real number at random between -1 and 1 . They then add the squares of their numbers together. If the result is greater than or equal to 1 , Lily wins, and if the result is less than 1, Sarah wins. What is the probability that Sarah wins?
+Answer: $\frac{\pi}{4}$ If we let $x$ denote Lily's choice of number and $y$ denote Sarah's, then all possible outcomes are represented by the square with vertices $(-1,-1),(-1,1),(1,-1)$, and $(1,1)$. Sarah wins if $x^{2}+y^{2} \leq 1$, which is the area inside the unit circle. Since this has an area of $\pi$ and the entire square has an area of 4 , the probability that Sarah wins is $\frac{\pi}{4}$.
+12. [8] Let $\omega$ be a circle of radius 1 centered at $O$. Let $B$ be a point on $\omega$, and let $l$ be the line tangent to $\omega$ at $B$. Let $A$ be on $l$ such that $\angle A O B=60^{\circ}$. Let $C$ be the foot of the perpendicular from $B$ to $O A$. Find the length of line segment $O C$.
+Answer: $\frac{1}{2}$ We have $O C / O B=\cos \left(60^{\circ}\right)$. Since $O B=1, O C=\frac{1}{2}$.
+$2^{\text {nd }}$ ANNUAL HARVARD-MIT NOVEMBER TOURNAMENT, 7 NOVEMBER 2009 - GUTS ROUND
+13. [8] 8 students are practicing for a math contest, and they divide into pairs to take a practice test. In how many ways can they be split up?
+Answer: 105 We create the pairs one at a time. The first person has 7 possible partners. Set this pair aside. Of the remaining six people, pick a person. He or she has 5 possible partners. Set this pair aside. Of the remaining four people, pick a person. He or she has 3 possible partners. Set this pair aside. Then the last two must be partners. So there are $7 \cdot 5 \cdot 3=105$ possible groupings. Alternatively, we can consider the 8 ! permutations of the students in a line, where the first two are a pair, the next two are a pair, etc. Given a grouping, there are 4 ! ways to arrange the four pairs in order, and in each pair, 2 ways to order the students. So our answer is $\frac{8!}{4!2^{4}}=7 \cdot 5 \cdot 3=105$.
+14. [8] Let $f(x)=x^{4}+a x^{3}+b x^{2}+c x+d$ be a polynomial whose roots are all negative integers. If $a+b+c+d=2009$, find $d$.
+Answer: 528 Call the roots $-x_{1},-x_{2},-x_{3}$, and $-x_{4}$. Then $f(x)$ must factor as $\left(x+x_{1}\right)\left(x+x_{2}\right)(x+$ $\left.x_{3}\right)\left(x+x_{4}\right)$. If we evaluate $f$ at 1 , we get $\left(1+x_{1}\right)\left(1+x_{2}\right)\left(1+x_{3}\right)\left(1+x_{4}\right)=a+b+c+d+1=$ $2009+1=2010$. $2010=2 \cdot 3 \cdot 5 \cdot 67$. $d$ is the product of the four roots, so $d=(-1) \cdot(-2) \cdot(-4) \cdot(-66)$.
+15. [8] The curves $x^{2}+y^{2}=36$ and $y=x^{2}-7$ intersect at four points. Find the sum of the squares of the $x$-coordinates of these points.
+Answer: 26 If we use the system of equations to solve for $y$, we get $y^{2}+y-29=0$ (since $x^{2}=y+7$ ). The sum of the roots of this equation is -1 . Combine this with $x^{2}=y+7$ to see that the sum of the square of the possible values of $x$ is $2 \cdot(-1+7 \cdot 2)=26$.
+16. [9] Pick a random digit in the decimal expansion of $\frac{1}{99999}$. What is the probability that it is 0 ?
+
+Answer: | $\frac{4}{5}$ |
+| :---: |
+| The decimal expansion of $\frac{1}{99999}$ | is $0 . \overline{00001}$.
+
+17. [9] A circle passes through the points $(2,0)$ and $(4,0)$ and is tangent to the line $y=x$. Find the sum of all possible values for the $y$-coordinate of the center of the circle.
+Answer: -6 First, we see that the x coordinate must be 3. Let the y coordinate be y. Now, we see that the radius is $r=\sqrt{1+y^{2}}$. The line from the center of the circle to the point of tangency with the line $x=y$ is perpendicular to the line $x=y$. Hence, the distance from the center of the circle to the line $x=y$ is $d=\sqrt{2}(3-y)$. Letting $r=d$ we see that the two possible values for y are 1 and -7 , which sum to -6 .
+18. [9] Let $f$ be a function that takes in a triple of integers and outputs a real number. Suppose that $f$ satisfies the equations
+
+$$
+\begin{aligned}
+f(a, b, c) & =\frac{f(a+1, b, c)+f(a-1, b, c)}{2} \\
+f(a, b, c) & =\frac{f(a, b+1, c)+f(a, b-1, c)}{2} \\
+f(a, b, c) & =\frac{f(a, b, c+1)+f(a, b, c-1)}{2}
+\end{aligned}
+$$
+
+for all integers $a, b, c$. What is the minimum number of triples at which we need to evaluate $f$ in order to know its value everywhere?
+Answer: 8 Note that if we have the value of $f$ at the 8 points: $(0,0,0),(1,0,0),(0,1,0),(0,0,1),(0,1,1),(1,0,1),(1,1,0),(1,1,1)$, we can calculate the value for any triple of points because we have that $f(a+1, b, c)-(a, b, c)$ constant for any $a$, if $b$ and $c$ are fixed (and similarly for the other coordinates). To see why we cannot do this with less points, notice that we need to determine what the value of these 8 points anyways, and there is no "more efficient" way to determine them all in fewer evaluations.
+$2^{\text {nd }}$ ANNUAL HARVARD-MIT NOVEMBER TOURNAMENT, 7 NOVEMBER 2009 - GUTS ROUND
+19. [11] You are trapped in ancient Japan, and a giant enemy crab is approaching! You must defeat it by cutting off its two claws and six legs and attacking its weak point for massive damage. You cannot cut off any of its claws until you cut off at least three of its legs, and you cannot attack its weak point until you have cut off all of its claws and legs. In how many ways can you defeat the giant enemy crab? (Note that the legs are distinguishable, as are the claws.)
+
+Answer: 14400 The answer is given by $6!2!\binom{5}{2}$, because we can cut off the claws and legs in any order and there are $\binom{5}{2}$ ways to decide when to cut off the two claws (since we can do it at any time among the last 5 cuts).
+20. [11] Consider an equilateral triangle and a square both inscribed in a unit circle such that one side of the square is parallel to one side of the triangle. Compute the area of the convex heptagon formed by the vertices of both the triangle and the square.
+Answer: $\frac{3+\sqrt{3}}{2}$
+
+
+Consider the diagram above. We see that the shape is a square plus 3 triangles. The top and bottom triangles have base $\sqrt{2}$ and height $\frac{1}{2}(\sqrt{3}-\sqrt{2})$, and the triangle on the side has the same base and height $1-\frac{\sqrt{2}}{2}$ Adding their areas, we get the answer.
+21. [11] Let $f(x)=x^{2}+2 x+1$. Let $g(x)=f(f(\cdots f(x)))$, where there are $2009 f \mathrm{~s}$ in the expression for $g(x)$. Then $g(x)$ can be written as
+
+$$
+g(x)=x^{2^{2009}}+a_{2^{2009}-1} x^{2^{2009}-1}+\cdots+a_{1} x+a_{0}
+$$
+
+where the $a_{i}$ are constants. Compute $a_{2^{2009}-1}$.
+Answer: $2^{2009} f(x)=(x+1)^{2}$, so $f\left(x^{n}+c x^{n-1}+\ldots\right)=\left(x^{n}+c x^{n-1}+\ldots+1\right)^{2}=x^{2 n}+2 c x^{2 n-1}+\ldots$. Applying the preceding formula repeatedly shows us that the coefficient of the term of second highest degree in the polynomial doubles each time, so after 2009 applications of $f$ it is $2^{2009}$.
+$2^{\text {nd }}$ ANNUAL HARVARD-MIT NOVEMBER TOURNAMENT, 7 NOVEMBER 2009 - GUTS ROUND
+22. [12] Five cards labeled A, B, C, D, and E are placed consecutively in a row. How many ways can they be re-arranged so that no card is moved more than one position away from where it started? (Not moving the cards at all counts as a valid re-arrangement.)
+Answer: 8 The only things we can do is leave cards where they are or switch them with adjacent cards. There is 1 way to leave them all where they are, 4 ways to switch just one adjacent pair, and 3 ways to switch two different adjacent pairs, for 8 possibilities total.
+23. [12] Let $a_{0}, a_{1}, \ldots$ be a sequence such that $a_{0}=3, a_{1}=2$, and $a_{n+2}=a_{n+1}+a_{n}$ for all $n \geq 0$. Find
+
+$$
+\sum_{n=0}^{8} \frac{a_{n}}{a_{n+1} a_{n+2}}
+$$
+
+Answer: $\frac{105}{212}$ We can re-write $\frac{a_{n}}{a_{n+1} a_{n+2}}$ as $\frac{a_{n+2}-a_{n+1}}{a_{n+1} a_{n+2}}=\frac{1}{a_{n+1}}-\frac{1}{a_{n+2}}$. We can thus re-write the sum as
+
+$$
+\left(\frac{1}{a_{1}}-\frac{1}{a_{2}}\right)+\left(\frac{1}{a_{2}}-\frac{1}{a_{3}}\right)+\left(\frac{1}{a_{4}}-\frac{1}{a_{3}}\right)+\ldots+\left(\frac{1}{a_{9}}-\frac{1}{a_{10}}\right)=\frac{1}{a_{1}}-\frac{1}{a_{10}}=\frac{1}{2}-\frac{1}{212}=\frac{105}{212} .
+$$
+
+24. [12] Penta chooses 5 of the vertices of a unit cube. What is the maximum possible volume of the figure whose vertices are the 5 chosen points?
+Answer: $\frac{1}{2}$ Label the vertices of the cube $A, B, C, D, E, F, G, H$, such that $A B C D$ is the top face of the cube, $E$ is directly below $A, F$ is directly below $B, G$ is directly below $C$, and $H$ is directly
+below $D$. We can obtain a volume of $\frac{1}{2}$ by taking the vertices $A, B, C, F$, and $H$. To compute the volume of $A C B F H$, we will instead compute the volume of the parts of the cube that are not part of $A B C F H$. This is just the three tetrahedrons $C F G H, A E F H$, and $A C D H$, which each have volume $\frac{1}{6}$ (by using the $\frac{1}{3} b h$ formula for the area of a pyramid). Therefore, the volume not contained in $A C B F H$ is $3 \cdot \frac{1}{6}=\frac{1}{2}$, so the volume contained in $A C B F H$ is $1-\frac{1}{2}=\frac{1}{2}$.
+$2^{\text {nd }}$ ANNUAL HARVARD-MIT NOVEMBER TOURNAMENT, 7 NOVEMBER 2009 - GUTS ROUND
+25. [14] Find all solutions to $x^{4}+2 x^{3}+2 x^{2}+2 x+1=0$ (including non-real solutions).
+
+Answer: $-1, i,-i$ We can factor the polynomial as $(x+1)^{2}\left(x^{2}+1\right)$.
+26. [14] In how many ways can the positive integers from 1 to 100 be arranged in a circle such that the sum of every two integers placed opposite each other is the same? (Arrangements that are rotations of each other count as the same.) Express your answer in the form $a!\cdot b^{c}$.
+Answer: $49!\cdot 2^{49}$ Split the integers up into pairs of the form $(x, 101-x)$. In the top half of the circle, exactly one element from each pair occurs, and there are thus 50 ! ways to arrange them. and also $2^{50}$ ways to decide whether the larger or smaller number in each pair occurs in the top half of the circle. We then need to divide by 100 since rotations are not considered distinct, so we get $\frac{50!2^{50}}{100}=49!\cdot 2^{49}$.
+27. [14] $A B C D$ is a regular tetrahedron of volume 1. Maria glues regular tetrahedra $A^{\prime} B C D, A B^{\prime} C D$, $A B C^{\prime} D$, and $A B C D^{\prime}$ to the faces of $A B C D$. What is the volume of the tetrahedron $A^{\prime} B^{\prime} C^{\prime} D^{\prime}$ ?
+Answer: $\frac{125}{27}$ Consider the tetrahedron with vertices at $W=(1,0,0), X=(0,1,0), Y=(0,0,1)$, and $Z=(1,1,1)$. This tetrahedron is similar to $A B C D$. It has center $O=\left(\frac{1}{2}, \frac{1}{2}, \frac{1}{2}\right)$. We can construct a tetrahedron $W^{\prime} X^{\prime} Y^{\prime} Z^{\prime}$ in the same way that $A^{\prime} B^{\prime} C^{\prime} D^{\prime}$ was constructed by letting $W^{\prime}$ be the reflection of $W$ across $X Y Z$ and so forth. Then we see that $Z^{\prime}=\left(-\frac{1}{3},-\frac{1}{3},-\frac{1}{3}\right)$, so $O Z^{\prime}$ has length $\frac{5}{6} \sqrt{3}$, whereas $O Z$ has length $\frac{1}{2} \sqrt{3}$. We thus see that $W^{\prime} X^{\prime} Y^{\prime} Z^{\prime}$ has a side length $\frac{\frac{5}{6}}{\frac{1}{2}}=\frac{5}{3}$ that of $W X Y Z$, so by similarity the same is true of $A^{\prime} B^{\prime} C^{\prime} D^{\prime}$ and $A B C D$. In particular, the volume of $A^{\prime} B^{\prime} C^{\prime} D^{\prime}$ is $\left(\frac{5}{3}\right)^{3}$ that of $A B C D$, so it is $\frac{125}{27}$.
+
+## $2^{\text {nd }}$ ANNUAL HARVARD-MIT NOVEMBER TOURNAMENT, 7 NOVEMBER 2009 - GUTS ROUND
+
+28. [17] Six men and their wives are sitting at a round table with 12 seats. These men and women are very jealous - no man will allow his wife to sit next to any man except for himself, and no woman will allow her husband to sit next to any woman except for herself. In how many distinct ways can these 12 people be seated such that these conditions are satisfied? (Rotations of a valid seating are considered distinct.)
+
+Answer: 288000 Think of this problem in terms of "blocks" of men and women, that is, groups of men and women sitting together. Each block must contain at least two people; otherwise you have a man sitting next to two women (or vice-versa).
+We will define the notation $\left[a_{1}, b_{1}, a_{2}, b_{2}, \ldots\right]$ to mean a seating arrangement consisting of, going in order, $a_{1}$ men, $b_{1}$ women, $a_{2}$ men, $b_{2}$ women, and so on.
+
+Split the problem into three cases, each based on the number of blocks of men and women:
+Case 1: One block of each, $[6,6]$.
+There are 12 ways to choose the seats where the men sit, and $6!$ ways to arrange those men. The two women on either side of the men are uniquely determined by the men they sit next to. There are 4 ! ways to arrange the other four women. This gives $6!\cdot 288$ ways.
+Case 2: Two blocks of each.
+
+The arrangement is $[a, b, c, d]$, where $a+c=b+d=6$. There are five distinct block schematics: $[2,2,4,4],[2,3,4,3],[2,4,4,2],[3,2,3,4]$, and $[3,3,3,3]$. (The others are rotations of one of the above.) For each of these, there are 6 ! ways to arrange the men. In addition, four women are uniquely determined because they sit next to a man. There are 2 ways to arrange the other two women. Each of the first four possible block schematics gives 12 distinct rotations, while the fifth one gives 6 . This gives $6!(2)(12+12+12+12+6)=6!\cdot 108$ ways.
+Case 3: Three blocks of each, $[2,2,2,2,2,2]$.
+There are 4 ways to choose where the men sit and 6 ! ways to arrange those men. Each placement of men will uniquely determine the placement of each women. This gives $6!\cdot 4$ ways.
+Then we have a grand total of $6!\cdot(288+108+4)=6!\cdot 400=288000$ seating arrangements.
+29. [17] For how many integer values of $b$ does there exist a polynomial function with integer coefficients such that $f(2)=2010$ and $f(b)=8$ ?
+Answer: 32 We can take $f(x)=-\frac{2002}{d}(x-b)+2010$ for all divisors $d$ of -2002 . To see that we can't get any others, note that $b-2$ must divide $f(b)-f(2)$, so $b-2$ divides -2002 (this is because $b-2$ divides $b^{n}-2^{n}$ and hence any sum of numbers of the form $b^{n}-2^{n}$ ).
+30. [17] Regular hexagon $A B C D E F$ has side length 2. A laser beam is fired inside the hexagon from point $A$ and hits $\overline{B C}$ at point $G$. The laser then reflects off $\overline{B C}$ and hits the midpoint of $\overline{D E}$. Find $B G$.
+Answer: $\frac{2}{5}$ Look at the diagram below, in which points $J, K, M, T$, and $X$ have been defined. $M$ is the midpoint of $\overline{D E}, B C J K$ is a rhombus with $J$ lying on the extension of $\overline{C D}, T$ is the intersection of lines $\overline{C D}$ and $\overline{G M}$ when extended, and $X$ is on $\overline{J T}$ such that $\overline{X M} \| \overline{J K}$.
+
+
+It can be shown that $m \angle M D X=m \angle M X D=60^{\circ}$, so $\triangle D M X$ is equilateral, which yields $X M=1$. The diagram indicates that $J X=5$. One can show by angle-angle similarity that $\triangle T X M \sim \triangle T J K$, which yields $T X=5$.
+One can also show by angle-angle similarity that $\triangle T J K \sim \triangle T C G$, which yields the proportion $\frac{T J}{J K}=\frac{T C}{C G}$. We know everything except $C G$, which we can solve for. This yields $C G=\frac{8}{5}$, so $B G=\frac{2}{5}$.
+$2^{\text {nd }}$ ANNUAL HARVARD-MIT NOVEMBER TOURNAMENT, 7 NOVEMBER 2009 - GUTS ROUND
+31. [20] There are two buildings facing each other, each 5 stories high. How many ways can Kevin string ziplines between the buildings so that:
+(a) each zipline starts and ends in the middle of a floor.
+(b) ziplines can go up, stay flat, or go down, but can't touch each other (this includes touching at their endpoints).
+
+Note that you can't string a zipline between two floors of the same building.
+Answer: 252 Associate with each configuration of ziplines a path in the plane as follows: Suppose there are $k$ ziplines. Let $a_{0}, \ldots, a_{k}$ be the distances between consecutive ziplines on the left building
+( $a_{0}$ is the floor on which the first zipline starts, and $a_{k}$ is the distance from the last zipline to the top of the building). Define $b_{0}, \ldots, b_{k}$ analogously for the right building. The path in the plane consists of starting at $(0,0)$ and going a distance $a_{0}$ to the right, $b_{0}$ up, $a_{1}$ to the right, $b_{1}$ up, etc. We thus go from $(0,0)$ to $(5,5)$ while traveling only up and to the right between integer coordinates. We can check that there is exactly one configuration of ziplines for each such path, so the answer is the number of paths from $(0,0)$ to $(5,5)$ where you only travel up and to the right. This is equal to $\binom{10}{5}=252$, since there are 10 total steps to make, and we must choose which 5 of them go to the right.
+32. [20] A circle $\omega_{1}$ of radius 15 intersects a circle $\omega_{2}$ of radius 13 at points $P$ and $Q$. Point $A$ is on line $P Q$ such that $P$ is between $A$ and $Q . R$ and $S$ are the points of tangency from $A$ to $\omega_{1}$ and $\omega_{2}$, respectively, such that the line $A S$ does not intersect $\omega_{1}$ and the line $A R$ does not intersect $\omega_{2}$. If $P Q=24$ and $\angle R A S$ has a measure of $90^{\circ}$, compute the length of $A R$.
+Answer: $\sqrt[{14+\sqrt{97}}]{ }$ Let $O_{1}$ be the center of $\omega_{1}$ and $O_{2}$ be the center of $\omega_{2}$. Then $O_{1} O_{2}$ and $P Q$ are perpendicular. Let their point of intersection be $X$. Using the Pythagorean theorem, the fact that $P Q=24$, and our knowledge of the radii of the circles, we can compute that $O_{1} X=9$ and $O_{2} X=5$, so $O_{1} O_{2}=14$. Let $S O_{1}$ and $R O_{2}$ meet at $Y$. Then $S A R Y$ is a square, say of side length $s$. Then $O_{1} Y=s-15$ and $O_{2} Y=s-13$. So, $O_{1} O_{2} Y$ is a right triangle with sides $14, s-15$, and $s-13$. By the Pythagorean theorem, $(s-13)^{2}+(s-15)^{2}=14^{2}$. We can write this as $2 s^{2}-4 \cdot 14 s+198=0$, or $s^{2}-28 s+99=0$. The quadratic formula then gives $s=\frac{28 \pm \sqrt{388}}{2}=14 \pm \sqrt{97}$. Since $14-\sqrt{97}<15$ and $Y O_{1}>15$, we can discard the root of $14-\sqrt{97}$, and the answer is therefore $14+\sqrt{97}$.
+33. [20] Compute
+
+$$
+\sum_{n=2009}^{\infty} \frac{1}{\binom{n}{2009}}
+$$
+
+Note that $\binom{n}{k}$ is defined as $\frac{n!}{k!(n-k)!}$.
+Answer: $\frac{2009}{2008}$ Observe that
+
+$$
+\begin{aligned}
+\frac{k+1}{k}\left(\frac{1}{\binom{n-1}{k}}-\frac{1}{\binom{n}{k}}\right) & =\frac{k+1}{k} \frac{\binom{n}{k}-\binom{n-1}{k}}{\binom{n}{k}\binom{n-1}{k}} \\
+& =\frac{k+1}{k} \frac{\binom{n-1}{k-1}}{\binom{n}{k}\binom{n-1}{k}} \\
+& =\frac{k+1}{k} \frac{(n-1)!k!k!(n-k-1)!(n-k)!}{n!(n-1)!(k-1)!(n-k)!} \\
+& =\frac{k+1}{k} \frac{k \cdot k!(n-k-1)!}{n!} \\
+& =\frac{(k+1)!(n-k-1)!}{n!} \\
+& =\frac{1}{\binom{n}{k+1}}
+\end{aligned}
+$$
+
+Now apply this with $k=2008$ and sum across all $n$ from 2009 to $\infty$. We get
+
+$$
+\sum_{n=2009}^{\infty} \frac{1}{\binom{n}{2009}}=\frac{2009}{2008} \sum_{n=2009}^{\infty} \frac{1}{\binom{n-1}{2008}}-\frac{1}{\binom{n}{2008}}
+$$
+
+All terms from the sum on the right-hand-side cancel, except for the initial $\frac{1}{\binom{2008}{2008}}$, which is equal to 1 , so we get $\sum_{n=2009}^{\infty} \frac{1}{\binom{n}{2009}}=\frac{2009}{2008}$.
+34. [25] How many hits does "3.1415" get on Google? Quotes are for clarity only, and not part of the search phrase. Also note that Google does not search substrings, so a webpage with 3.14159 on it will not match 3.1415 . If $A$ is your answer, and $S$ is the correct answer, then you will get $\max (25-\mid \ln (A)-$ $\ln (S) \mid, 0)$ points, rounded to the nearest integer.
+
+Answer: 422000
+35. [25] Call an integer $n>1$ radical if $2^{n}-1$ is prime. What is the 20 th smallest radical number? If $A$ is your answer, and $S$ is the correct answer, you will get $\max \left(25\left(1-\frac{|A-S|}{S}\right), 0\right)$ points, rounded to the nearest integer.
+Answer: 4423
+36. [25] Write down a pair of integers $(a, b)$, where $-100000 Saturday 7 November 2009
Team Round
Down the Infinite Corridor
+
+Consider an isosceles triangle $T$ with base 10 and height 12 . Define a sequence $\omega_{1}, \omega_{2}, \ldots$ of circles such that $\omega_{1}$ is the incircle of $T$ and $\omega_{i+1}$ is tangent to $\omega_{i}$ and both legs of the isosceles triangle for $i>1$.
+
+1. [3] Find the radius of $\omega_{1}$.
+
+Answer: $\frac{10}{3}$ Using the Pythagorean theorem, we see that the legs of $T$ each have length 13. Let $r$ be the radius of $\omega_{1}$. We can divide $T$ into three triangles, each with two vertices at vertices of $T$ and one vertex at the center of $\omega_{1}$. These triangles all have height $r$ and have bases 13,13 , and 10 . Thus their total area is $\frac{13 r}{2}+\frac{13 r}{2}+\frac{10 r}{2}=18 r$. However, $T$ has height 12 and base 10 , so its area is 60 . Thus $18 r=60$, so $r=\frac{10^{2}}{3}$.
+2. [3] Find the ratio of the radius of $\omega_{i+1}$ to the radius of $\omega_{i}$.
+3. [3] Find the total area contained in all the circles.
+
+Answer: $\frac{180 \pi}{13}$ Using the notation from the previous solution, the area contained in the $i$ th circle is equal to $\pi r_{i}^{2}$. Since the radii form a geometric sequence, the areas do as well. Specifically, the areas form a sequence with initial term $\pi \cdot \frac{100}{9}$ and common ratio $\frac{16}{81}$, so their sum is then $\pi \cdot \frac{\frac{100}{9}}{\frac{95}{81}}=\frac{180 \pi}{13}$.
+
+## Bouncy Balls
+
+In the following problems, you will consider the trajectories of balls moving and bouncing off of the boundaries of various containers. The balls are small enough that you can treat them as points. Let us suppose that a ball starts at a point $X$, strikes a boundary (indicated by the line segment $A B$ ) at $Y$, and then continues, moving along the ray $Y Z$. Balls always bounce in such a way that $\angle X Y A=\angle B Y Z$. This is indicated in the above diagram.
+
+
+Balls bounce off of boundaries in the same way light reflects off of mirrors - if the ball hits the boundary at point $P$, the trajectory after $P$ is the reflection of the trajectory before $P$ through the perpendicular to the boundary at $P$.
+
+A ball inside a rectangular container of width 7 and height 12 is launched from the lower-left vertex of the container. It first strikes the right side of the container after traveling a distance of $\sqrt{53}$ (and strikes no other sides between its launch and its impact with the right side).
+4. [2] Find the height at which the ball first contacts the right side.
+
+Answer: 2 Let $h$ be this height. Then, using the Pythagorean theorem, we see that $h^{2}+7^{2}=53$, so $h=2$.
+5. [3] How many times does the ball bounce before it returns to a vertex? (The final contact with a vertex does not count as a bounce.)
+Answer: 5 Every segment the ball traverses between bounces takes it 7 units horizontally and 2 units up. Thus, after 5 bounces it has traveled up 10 units, and the final segment traversed takes it directly to the upper right vertex of the rectangle.
+
+Now a ball is launched from a vertex of an equilateral triangle with side length 5 . It strikes the opposite side after traveling a distance of $\sqrt{19}$.
+6. [4] Find the distance from the ball's point of first contact with a wall to the nearest vertex.
+
+Answer: 2
+
+
+Consider the diagram above, where $M$ is the midpoint of $B C$. Then $A M$ is perpendicular to $B C$ since $A B C$ is equilateral, so by the Pythagorean theorem $A M=\frac{5 \sqrt{3}}{2}$. Then, using the Pythagorean theorem again, we see that $M Y=\frac{1}{2}$, so that $B Y=2$.
+7. [4] How many times does the ball bounce before it returns to a vertex? (The final contact with a vertex does not count as a bounce.)
+Answer: 7 The key idea is that, instead of reflecting the line $A Y$ off of $B C$, we will reflect $A B C$ about $B C$ and extend $A Y$ beyond $\triangle A B C$. We keep doing this until the extension of $A Y$ hits a vertex of one of our reflected triangles. This is illustrated in the diagram below:
+
+
+We can calculate that the line $A Y$ has slope $\frac{\frac{3 \sqrt{3}}{\frac{2}{2}}}{\frac{7}{2}}=\frac{3 \sqrt{3}}{7}$, so that (as indicated in the diagram), $A Y$ first intersects a vertex at the point $\left(\frac{35}{2}, \frac{15 \sqrt{3}}{2}\right)^{2}$. To get there, it has to travel through 2 horizontal lines, 1 upward sloping line, and 4 downward sloping lines, so it bounces $2+1+4=7$ times total.
+
+In this final problem, a ball is again launched from the vertex of an equilateral triangle with side length 5 .
+8. [6] In how many ways can the ball be launched so that it will return again to a vertex for the first time after 2009 bounces?
+Answer: 502 We will use the same idea as in the previous problem. We first note that every vertex of a triangle can be written uniquely in the form $a(5,0)+b\left(\frac{5}{2}, \frac{5 \sqrt{3}}{2}\right)$, where $a$ and $b$ are non-negative integers. Furthermore, if a ball ends at $a(5,0)+b\left(\frac{5}{2}, \frac{5 \sqrt{3}}{2}\right)$, then it bounches off of a wall $2(a+b)-3$ times. Therefore, the possible directions that you can launch the ball in correspond to solutions to $2(a+b)-3=2009$, or $a+b=1006$. However, if $a$ and $b$ have a common factor, say, $k$, then the ball will pass through the vertex corresponding to $\frac{a}{k}$ and $\frac{b}{k}$ before it passes through the vertex corresponding to $a$ and $b$. Therefore, we must discount all such pairs $a, b$. This corresponds to when $a$ is even or $a=503$, so after removing these we are left with 502 remaining possible values of $a$, hence 502 possible directions in which to launch the ball.
+
+## Super Mario 64!
+
+Mario is once again on a quest to save Princess Peach. Mario enters Peach's castle and finds himself in a room with 4 doors. This room is the first in a sequence of 2 indistinugishable rooms. In each room, 1 door leads to the next room in the sequence (or, for the second room, into Bowser's level), while the other 3 doors lead to the first room.
+9. [3] Suppose that in every room, Mario randomly picks a door to walk through. What is the expected number of doors (not including Mario's initial entrance to the first room) through which Mario will pass before he reaches Bowser's level?
+Answer: 20 Let $E_{i}$ be the expected number of doors through which Mario will pass in the future if he is currently in room $i$ for $i=1,2,3$ (we will set $E_{3}=0$ ). We claim that $E_{i}=1+\frac{3}{4} E_{1}+\frac{1}{4} E_{i+1}$. Indeed, the 1 at the beginning comes from the fact that we need to pass through a door to leave the room, the $\frac{3}{4} E_{1}$ comes from the fact that there is a $\frac{3}{4}$ chance of ending up in room 1 , and the $\frac{1}{4} E_{i+1}$ corresponds to the fact that there is a $\frac{1}{4}$ chance of ending up in $E_{i+1}$. Using this, we get $E_{1}=1+\frac{3}{4} E_{1}+\frac{1}{4} E_{2}$, or $E_{1}=4+E_{2}$. We also get $E_{2}=1+\frac{3}{4} E_{1}$. Solving this system of equations yields $E_{1}=20$.
+10. [4] Suppose that instead there are 6 rooms with 4 doors. In each room, 1 door leads to the next room in the sequence (or, for the last room, Bowser's level), while the other 3 doors lead to the first room. Now what is the expected number of doors through which Mario will pass before he reaches Bowser's level?
+
+Answer: 5460 This problem works in the same general way as the last problem, but it can be more succintly solved using the general formula, which is provided below in the solution to the next problem.
+11. [5] In general, if there are $d$ doors in every room (but still only 1 correct door) and $r$ rooms, the last of which leads into Bowser's level, what is the expected number of doors through which Mario will pass before he reaches Bowser's level?
+Answer: $\frac{d\left(d^{r}-1\right)}{d-1}$ Let $E_{i}$ be the expected number of doors through which Mario will pass in the future if he is currently in room $i$ for $i=1,2, \ldots, r+1$ (we will set $E_{r+1}=0$ ). We claim that $E_{i}=1+\frac{d-1}{d} E_{1}+\frac{1}{d} E_{i+1}$. This is because, as before, there is a $\frac{d-1}{d}$ chance of ending up in room 1, and a $\frac{1}{d}$ chance of ending up in room $i+1$. Note that we can re-write this equation as $d E_{i}=d+(d-1) E_{1}+E_{i+1}$.
+We can solve this system of equation as follows: let $E_{1}=E_{i}+c_{i}$. Then we can re-write each equation as $d E_{1}-d \cdot c_{i}=d+(d-1) E_{1}+E_{1}-c_{i+1}$, so $c_{i+1}=d \cdot c_{i}+d$, and $c_{1}=0$. We can then see that $c_{i}=d \frac{d^{i-1}-1}{d-1}$ (either by finding the pattern or by using more advanced techniques, such as those given at http://en.wikipedia.org/wiki/Recurrence_relation). Solving for $E_{1}$ using $E_{1}=E_{r}+c_{r}$ and $E_{r}=1+\frac{d-1}{d} E_{1}$, we get $E_{1}=\frac{d\left(d^{r}-1\right)}{d-1}$.
+
diff --git a/HarvardMIT/md/en-132-2010-feb-alg-solutions.md b/HarvardMIT/md/en-132-2010-feb-alg-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..9c87927a2c995ac59000d55afd63ab214d9a12a9
--- /dev/null
+++ b/HarvardMIT/md/en-132-2010-feb-alg-solutions.md
@@ -0,0 +1,147 @@
+# $13^{\text {th }}$ Annual Harvard-MIT Mathematics Tournament
+
+Saturday 20 February 2010
+Algebra Subject Test
+
+1. [3] Suppose that $x$ and $y$ are positive reals such that
+
+$$
+x-y^{2}=3, \quad x^{2}+y^{4}=13
+$$
+
+Find $x$.
+Answer: $\frac{3+\sqrt{17}}{2}$ Squaring both sides of $x-y^{2}=3$ gives $x^{2}+y^{4}-2 x y^{2}=9$. Subtract this equation from twice the second given to get $x^{2}+2 x y^{2}+y^{4}=17 \Longrightarrow x+y^{2}= \pm 17$. Combining this equation with the first given, we see that $x=\frac{3 \pm \sqrt{17}}{2}$. Since $x$ is a positive real, $x$ must be $\frac{3+\sqrt{17}}{2}$.
+2. [3] The rank of a rational number $q$ is the unique $k$ for which $q=\frac{1}{a_{1}}+\cdots+\frac{1}{a_{k}}$, where each $a_{i}$ is the smallest positive integer such that $q \geq \frac{1}{a_{1}}+\cdots+\frac{1}{a_{i}}$. Let $q$ be the largest rational number less than $\frac{1}{4}$ with rank 3 , and suppose the expression for $q$ is $\frac{1}{a_{1}}+\frac{1}{a_{2}}+\frac{1}{a_{3}}$. Find the ordered triple $\left(a_{1}, a_{2}, a_{3}\right)$.
+Answer: $(5,21,421)$ Suppose that $A$ and $B$ were rational numbers of rank 3 less than $\frac{1}{4}$, and let $a_{1}, a_{2}, a_{3}, b_{1}, b_{2}, b_{3}$ be positive integers so that $A=\frac{1}{a_{1}}+\frac{1}{a_{2}}+\frac{1}{a_{3}}$ and $B=\frac{1}{b_{1}}+\frac{1}{b_{2}}+\frac{1}{b_{3}}$ are the expressions for $A$ and $B$ as stated in the problem. If $b_{1}
Calculus Subject Test
+
+1. [3] Suppose that $p(x)$ is a polynomial and that $p(x)-p^{\prime}(x)=x^{2}+2 x+1$. Compute $p(5)$.
+
+Answer: 50 Observe that $p(x)$ must be quadratic. Let $p(x)=a x^{2}+b x+c$. Comparing coefficients gives $a=1, b-2 a=2$, and $c-b=1$. So $b=4, c=5, p(x)=x^{2}+4 x+5$ and $p(5)=25+20+5=50$.
+2. [3] Let $f$ be a function such that $f(0)=1, f^{\prime}(0)=2$, and
+
+$$
+f^{\prime \prime}(t)=4 f^{\prime}(t)-3 f(t)+1
+$$
+
+for all $t$. Compute the 4th derivative of $f$, evaluated at 0 .
+Answer: 54 Putting $t=0$ gives $f^{\prime \prime}(0)=6$. By differentiating both sides, we get $f^{(3)}(t)=4 f^{\prime \prime}(t)-$ $3 f^{\prime}(t)$ and $f^{(3)}(0)=4 \cdot 6-3 \cdot 2=18$. Similarly, $f^{(4)}(t)=4 f^{(3)}(t)-3 f^{\prime \prime}(t)$ and $f^{(4)}(0)=4 \cdot 18-3 \cdot 6=54$.
+3. [4] Let $p$ be a monic cubic polynomial such that $p(0)=1$ and such that all the zeros of $p^{\prime}(x)$ are also zeros of $p(x)$. Find $p$. Note: monic means that the leading coefficient is 1 .
+Answer: $(x+1)^{3}$ A root of a polynomial $p$ will be a double root if and only if it is also a root of $p^{\prime}$. Let $a$ and $b$ be the roots of $p^{\prime}$. Since $a$ and $b$ are also roots of $p$, they are double roots of $p$. But $p$ can have only three roots, so $a=b$ and $a$ becomes a double root of $p^{\prime}$. This makes $p^{\prime}(x)=3 c(x-a)^{2}$ for some constant $3 c$, and thus $p(x)=c(x-a)^{3}+d$. Because $a$ is a root of $p$ and $p$ is monic, $d=0$ and $c=1$. From $p(0)=1$ we get $p(x)=(x+1)^{3}$.
+4. [4] Compute $\lim _{n \rightarrow \infty} \frac{\sum_{k=1}^{n}|\cos (k)|}{n}$.
+
+Answer: $\frac{2}{\pi}$ The main idea lies on the fact that positive integers are uniformly distributed modulo $\pi$. (In the other words, if each integer $n$ is written as $q \pi+r$ where $q$ is an integer and $0 \leq r<\pi$, the value of $r$ will distribute uniformly in the interval $[0, \pi]$.) Using this fact, the summation is equivalent to the average value (using the Riemann summation) of the function $|\cos (k)|$ over the interval $[0, \pi]$. Therefore, the answer is $\frac{1}{\pi} \int_{0}^{\pi}|\cos (k)|=\frac{2}{\pi}$.
+5. [4] Let the functions $f(\alpha, x)$ and $g(\alpha)$ be defined as
+
+$$
+f(\alpha, x)=\frac{\left(\frac{x}{2}\right)^{\alpha}}{x-1} \quad g(\alpha)=\left.\frac{d^{4} f}{d x^{4}}\right|_{x=2}
+$$
+
+Then $g(\alpha)$ is a polynomial in $\alpha$. Find the leading coefficient of $g(\alpha)$.
+Answer: $\frac{1}{16}$ Write the first equation as $(x-1) f=\left(\frac{x}{2}\right)^{\alpha}$. For now, treat $\alpha$ as a constant. From this equation, repeatedly applying derivative with respect to $x$ gives
+
+$$
+\begin{aligned}
+(x-1) f^{\prime}+f & =\left(\frac{\alpha}{2}\right)\left(\frac{x}{2}\right)^{\alpha-1} \\
+(x-1) f^{\prime \prime}+2 f^{\prime} & =\left(\frac{\alpha}{2}\right)\left(\frac{\alpha-1}{2}\right)\left(\frac{x}{2}\right)^{\alpha-2} \\
+(x-1) f^{(3)}+3 f^{\prime \prime} & =\left(\frac{\alpha}{2}\right)\left(\frac{\alpha-1}{2}\right)\left(\frac{\alpha-2}{2}\right)\left(\frac{x}{2}\right)^{\alpha-3} \\
+(x-1) f^{(4)}+4 f^{(3)} & =\left(\frac{\alpha}{2}\right)\left(\frac{\alpha-1}{2}\right)\left(\frac{\alpha-2}{2}\right)\left(\frac{\alpha-3}{2}\right)\left(\frac{x}{2}\right)^{\alpha-4}
+\end{aligned}
+$$
+
+Substituting $x=2$ to all equations gives $g(\alpha)=f^{(4)}(\alpha, 2)=\left(\frac{\alpha}{2}\right)\left(\frac{\alpha-1}{2}\right)\left(\frac{\alpha-2}{2}\right)\left(\frac{\alpha-3}{2}\right)-4 f^{(3)}(\alpha, 2)$. Because $f^{(3)}(\alpha, 2)$ is a cubic polynomial in $\alpha$, the leading coefficient of $g(\alpha)$ is $\frac{1}{16}$.
+6. [5] Let $f(x)=x^{3}-x^{2}$. For a given value of $c$, the graph of $f(x)$, together with the graph of the line $c+x$, split the plane up into regions. Suppose that $c$ is such that exactly two of these regions have finite area. Find the value of $c$ that minimizes the sum of the areas of these two regions.
+Answer: $-\frac{11}{27}$ Observe that $f(x)$ can be written as $\left(x-\frac{1}{3}\right)^{3}-\frac{1}{3}\left(x-\frac{1}{3}\right)-\frac{2}{27}$, which has $180^{\circ}$ symmetry around the point $\left(\frac{1}{3},-\frac{2}{27}\right)$. Suppose the graph of $f$ cuts the line $y=c+x$ into two segments of lengths $a$ and $b$. When we move the line toward point $P$ with a small distance $\Delta x$ (measured along the line perpendicular to $y=x+c)$, the sum of the enclosed areas will increase by $|a-b|(\Delta x)$. As long as the line $x+c$ does not passes through $P$, we can find a new line $x+c^{*}$ that increases the sum of the enclosed areas. Therefore, the sum of the areas reaches its maximum when the line passes through $P$. For that line, we can find that $c=y-x=-\frac{2}{27}-\frac{1}{3}=-\frac{11}{27}$.
+7. [6] Let $a_{1}, a_{2}$, and $a_{3}$ be nonzero complex numbers with non-negative real and imaginary parts. Find the minimum possible value of
+
+$$
+\frac{\left|a_{1}+a_{2}+a_{3}\right|}{\sqrt[3]{\left|a_{1} a_{2} a_{3}\right|}}
+$$
+
+Answer: $\sqrt{3} \sqrt[3]{2}$ Write $a_{1}$ in its polar form $r e^{i \theta}$ where $0 \leq \theta \leq \frac{\pi}{2}$. Suppose $a_{2}, a_{3}$ and $r$ are fixed so that the denominator is constant. Write $a_{2}+a_{3}$ as $s e^{i \phi}$. Since $a_{2}$ and $a_{3}$ have non-negative real and imaginary parts, the angle $\phi$ lies between 0 and $\frac{\pi}{2}$. Consider the function
+
+$$
+f(\theta)=\left|a_{1}+a_{2}+a_{3}\right|^{2}=\left|r e^{i \theta}+s e^{i \phi}\right|^{2}=r^{2}+2 r s \cos (\theta-\phi)+s^{2}
+$$
+
+Its second derivative is $\left.f^{\prime \prime}(\theta)=-2 \operatorname{rs}(\cos (\theta-\phi))\right)$. Since $-\frac{\pi}{2} \leq(\theta-\phi) \leq \frac{\pi}{2}$, we know that $f^{\prime \prime}(\theta)<0$ and $f$ is concave. Therefore, to minimize $f$, the angle $\theta$ must be either 0 or $\frac{\pi}{2}$. Similarly, each of $a_{1}, a_{2}$ and $a_{3}$ must be either purely real or purely imaginary to minimize $f$ and the original fraction.
+By the AM-GM inequality, if $a_{1}, a_{2}$ and $a_{3}$ are all real or all imaginary, then the minimum value of the fraction is 3 . Now suppose only two of the $a_{i}$ 's, say, $a_{1}$ and $a_{2}$ are real. Since the fraction is homogenous, we may fix $a_{1}+a_{2}$ - let the sum be 2 . The term $a_{1} a_{2}$ in the denominator acheives its maximum only when $a_{1}$ and $a_{2}$ are equal, i.e. when $a_{1}=a_{2}=1$. Then, if $a_{3}=k i$ for some real number $k$, then the expression equals
+
+$$
+\frac{\sqrt{k^{2}+4}}{\sqrt[3]{k}}
+$$
+
+Squaring and taking the derivative, we find that the minimum value of the fraction is $\sqrt{3} \sqrt[3]{2}$, attained when $k=\sqrt{2}$. With similar reasoning, the case where only one of the $a_{i}$ 's is real yields the same minimum value.
+8. [6] Let $f(n)=\sum_{k=2}^{\infty} \frac{1}{k^{n} \cdot k!}$. Calculate $\sum_{n=2}^{\infty} f(n)$.
+
+Answer: $3-e$
+
+$$
+\begin{aligned}
+\sum_{n=2}^{\infty} f(n) & =\sum_{k=2}^{\infty} \sum_{n=2}^{\infty} \frac{1}{k^{n} \cdot k!} \\
+& =\sum_{k=2}^{\infty} \frac{1}{k!} \sum_{n=2}^{\infty} \frac{1}{k^{n}} \\
+& =\sum_{k=2}^{\infty} \frac{1}{k!} \cdot \frac{1}{k(k-1)} \\
+& =\sum_{k=2}^{\infty} \frac{1}{(k-1)!} \cdot \frac{1}{k^{2}(k-1)}
+\end{aligned}
+$$
+
+$$
+\begin{aligned}
+& =\sum_{k=2}^{\infty} \frac{1}{(k-1)!}\left(\frac{1}{k-1}-\frac{1}{k^{2}}-\frac{1}{k}\right) \\
+& =\sum_{k=2}^{\infty}\left(\frac{1}{(k-1)(k-1)!}-\frac{1}{k \cdot k!}-\frac{1}{k!}\right) \\
+& =\sum_{k=2}^{\infty}\left(\frac{1}{(k-1)(k-1)!}-\frac{1}{k \cdot k!}\right)-\sum_{k=2}^{\infty} \frac{1}{k!} \\
+& =\frac{1}{1 \cdot 1!}-\left(e-\frac{1}{0!}-\frac{1}{1!}\right) \\
+& =3-e
+\end{aligned}
+$$
+
+9. [7] Let $x(t)$ be a solution to the differential equation
+
+$$
+\left(x+x^{\prime}\right)^{2}+x \cdot x^{\prime \prime}=\cos t
+$$
+
+with $x(0)=x^{\prime}(0)=\sqrt{\frac{2}{5}}$. Compute $x\left(\frac{\pi}{4}\right)$.
+Answer: $\frac{\sqrt[4]{450}}{5}$ Rewrite the equation as $x^{2}+2 x x^{\prime}+\left(x x^{\prime}\right)^{\prime}=\cos t$. Let $y=x^{2}$, so $y^{\prime}=2 x x^{\prime}$ and the equation becomes $y+y^{\prime}+\frac{1}{2} y^{\prime \prime}=\cos t$. The term $\cos t$ suggests that the particular solution should be in the form $A \sin t+B \cos t$. By substitution and coefficient comparison, we get $A=\frac{4}{5}$ and $B=\frac{2}{5}$. Since the function $y(t)=\frac{4}{5} \sin t+\frac{2}{5} \cos t$ already satisfies the initial conditions $y(0)=x(0)^{2}=\frac{2}{5}$ and $y^{\prime}(0)=2 x(0) x^{\prime}(0)=\frac{4}{5}$, the function $y$ also solves the initial value problem. Note that since $x$ is positive at $t=0$ and $y=x^{2}$ never reaches zero before $t$ reaches $\frac{\pi}{4}$, the value of $x\left(\frac{\pi}{4}\right)$ must be positive. Therefore, $x\left(\frac{\pi}{4}\right)=+\sqrt{y\left(\frac{\pi}{4}\right)}=\sqrt{\frac{6}{5} \cdot \frac{\sqrt{2}}{2}}=\frac{\sqrt[4]{450}}{5}$.
+10. [8] Let $f(n)=\sum_{k=1}^{n} \frac{1}{k}$. Then there exists constants $\gamma, c$, and $d$ such that
+
+$$
+f(n)=\ln (n)+\gamma+\frac{c}{n}+\frac{d}{n^{2}}+O\left(\frac{1}{n^{3}}\right)
+$$
+
+where the $O\left(\frac{1}{n^{3}}\right)$ means terms of order $\frac{1}{n^{3}}$ or lower. Compute the ordered pair $(c, d)$.
+Answer: $\left(\frac{1}{2},-\frac{1}{12}\right)$ From the given formula, we pull out the term $\frac{k}{n^{3}}$ from $O\left(\frac{1}{n^{4}}\right)$, making $f(n)=$ $\log (n)+\gamma+\frac{c}{n}+\frac{d}{n^{2}}+\frac{k}{n^{3}}+O\left(\frac{1}{n^{4}}\right)$. Therefore,
+$f(n+1)-f(n)=\log \left(\frac{n+1}{n}\right)-c\left(\frac{1}{n}-\frac{1}{n+1}\right)-d\left(\frac{1}{n^{2}}-\frac{1}{(n+1)^{2}}\right)-k\left(\frac{1}{n^{3}}-\frac{1}{(n+1)^{3}}\right)+O\left(\frac{1}{n^{4}}\right)$.
+For the left hand side, $f(n+1)-f(n)=\frac{1}{n+1}$. By substituting $x=\frac{1}{n}$, the formula above becomes
+
+$$
+\frac{x}{x+1}=\log (1+x)-c x^{2} \cdot \frac{1}{x+1}-d x^{3} \cdot \frac{x+2}{(x+1)^{2}}-k x^{4} \cdot \frac{x^{2}+3 x+3}{(x+1)^{3}}+O\left(x^{4}\right)
+$$
+
+Because $x$ is on the order of $\frac{1}{n}, \frac{1}{(x+1)^{3}}$ is on the order of a constant. Therefore, all the terms in the expansion of $k x^{4} \cdot \frac{x^{2}+3 x+3}{(x+1)^{3}}$ are of order $x^{4}$ or higher, so we can collapse it into $O\left(x^{4}\right)$. Using the Taylor expansions, we get
+
+$$
+x\left(1-x+x^{2}\right)+O\left(x^{4}\right)=\left(x-\frac{1}{2} x^{2}+\frac{1}{3} x^{3}\right)-c x^{2}(1-x)-d x^{3}(2)+O\left(x^{4}\right) .
+$$
+
+Coefficient comparison gives $c=\frac{1}{2}$ and $d=-\frac{1}{12}$.
+
diff --git a/HarvardMIT/md/en-132-2010-feb-comb-solutions.md b/HarvardMIT/md/en-132-2010-feb-comb-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..11715a21ba8d573ee142b5977fc500c78ea7bad7
--- /dev/null
+++ b/HarvardMIT/md/en-132-2010-feb-comb-solutions.md
@@ -0,0 +1,107 @@
+## $13^{\text {th }}$ Annual Harvard-MIT Mathematics Tournament Saturday 20 February 2010
+
+## Combinatorics Subject Test
+
+1. [2] Let $S=\{1,2,3,4,5,6,7,8,9,10\}$. How many (potentially empty) subsets $T$ of $S$ are there such that, for all $x$, if $x$ is in $T$ and $2 x$ is in $S$ then $2 x$ is also in $T$ ?
+Answer: 180 We partition the elements of $S$ into the following subsets: $\{1,2,4,8\},\{3,6\},\{5,10\}$, $\{7\},\{9\}$. Consider the first subset, $\{1,2,4,8\}$. Say 2 is an element of $T$. Because $2 \cdot 2=4$ is in $S, 4$ must also be in $T$. Furthermore, since $4 \cdot 2=8$ is in $S, 8$ must also be in $T$. So if $T$ contains 2 , it must also contain 4 and 8 . Similarly, if $T$ contains 1 , it must also contain 2,4 , and 8 . So $T$ can contain the following subsets of the subset $\{1,2,4,8\}$ : the empty set, $\{8\},\{4,8\},\{2,4,8\}$, or $\{1,2,4,8\}$. This gives 5 possibilities for the first subset. In general, we see that if $T$ contains an element $q$ of one of these subsets, it must also contain the elements in that subset that are larger than $q$, because we created the subsets for this to be true. So there are 3 possibilities for $\{3,6\}, 3$ for $\{5,10\}, 2$ for $\{7\}$, and 2 for $\{9\}$. This gives a total of $5 \cdot 3 \cdot 3 \cdot 2 \cdot 2=180$ possible subsets $T$.
+2. [3] How many positive integers less than or equal to 240 can be expressed as a sum of distinct factorials? Consider 0! and 1! to be distinct.
+Answer: 39 Note that $1=0!, 2=0!+1!, 3=0!+2$ !, and $4=0!+1!+2$ !. These are the only numbers less than 6 that can be written as the sum of factorials. The only other factorials less than 240 are $3!=6,4!=24$, and $5!=120$. So a positive integer less than or equal to 240 can only contain 3 !, 4 !, 5 !, and/or one of $1,2,3$, or 4 in its sum. If it contains any factorial larger than 5 !, it will be larger than 240 . So a sum less than or equal to 240 will will either include 3 ! or not ( 2 ways), 4 ! or not ( 2 ways), 5 ! or not ( 2 ways), and add an additional $0,1,2,3$ or 4 ( 5 ways). This gives $2 \cdot 2 \cdot 2 \cdot 5=40$ integers less than 240 . However, we want only positive integers, so we must not count 0 . So there are 39 such positive integers.
+3. [4] How many ways are there to choose 2010 functions $f_{1}, \ldots, f_{2010}$ from $\{0,1\}$ to $\{0,1\}$ such that $f_{2010} \circ f_{2009} \circ \cdots \circ f_{1}$ is constant? Note: a function $g$ is constant if $g(a)=g(b)$ for all $a, b$ in the domain of $g$.
+Answer: $4^{2010}-2^{2010}$ If all 2010 functions are bijective ${ }^{1}$, then the composition $f_{2010} \circ f_{2009} \circ \cdots \circ f_{1}$ will be bijective also, and therefore not constant. If, however, one of $f_{1}, \ldots, f_{2010}$ is not bijective, say $f_{k}$, then $f_{k}(0)=f_{k}(1)=q$, so $f_{2010} \circ f_{2009} \circ \cdots \circ f_{k+1} \circ f_{k} \circ \cdots f_{1}(0)=f_{2010} \circ f_{2009} \circ \cdots \circ f_{k+1}(q)=$ $f_{2010} \circ f_{2009} \circ \cdots \circ f_{k+1} \circ f_{k} \circ \cdots f_{1}(1)$. So the composition will be constant unless all $f_{i}$ are bijective. Since there are 4 possible functions ${ }^{2}$ from $\{0,1\}$ to $\{0,1\}$ and 2 of them are bijective, we subtract the cases where all the functions are bijective from the total to get $4^{2010}-2^{2010}$.
+4. [4] Manya has a stack of $85=1+4+16+64$ blocks comprised of 4 layers (the $k$ th layer from the top has $4^{k-1}$ blocks; see the diagram below). Each block rests on 4 smaller blocks, each with dimensions half those of the larger block. Laura removes blocks one at a time from this stack, removing only blocks that currently have no blocks on top of them. Find the number of ways Laura can remove precisely 5 blocks from Manya's stack (the order in which they are removed matters).
+
+Answer: 3384 Each time Laura removes a block, 4 additional blocks are exposed, increasing the total number of exposed blocks by 3 . She removes 5 blocks, for a total of $1 \cdot 4 \cdot 7 \cdot 10 \cdot 13$ ways. However, the stack originally only has 4 layers, so we must subtract the cases where removing a block on the bottom layer does not expose any new blocks. There are $1 \cdot 4 \cdot 4 \cdot 4 \cdot 4=256$ of these (the last factor of 4 is from the 4 blocks that we counted as being exposed, but were not actually). So our final answer is $1 \cdot 4 \cdot 7 \cdot 10 \cdot 13-1 \cdot 4 \cdot 4 \cdot 4 \cdot 4=3384$.
+5. [5] John needs to pay 2010 dollars for his dinner. He has an unlimited supply of 2, 5, and 10 dollar notes. In how many ways can he pay?
+Answer: 20503
+Let the number of 2,5 , and 10 dollar notes John can use be $x, y$, and $z$ respectively. We wish to find the number of nonnegative integer solutions to $2 x+5 y+10 z=2010$. Consider this equation $\bmod 2$. Because $2 x, 10 z$, and 2010 are even, $5 y$ must also be even, so $y$ must be even. Now consider the equation mod 5 . Because $5 y, 10 z$, and 2010 are divisible by $5,2 x$ must also be divisible by 5 , so $x$ must be divisible by 5 . So both $2 x$ and $5 y$ are divisible by 10 . So the equation is equivalent to $10 x^{\prime}+10 y^{\prime}+10 z=2010$, or $x^{\prime}+y^{\prime}+z=201$, with $x^{\prime}, y^{\prime}$, and $z$ nonnegative integers. There is a well-known bijection between solutions of this equation and picking 2 of 203 balls in a row on the table (explained in further detail below), so there are $\binom{203}{2}=20503$ ways.
+The bijection between solutions of $x^{\prime}+y^{\prime}+z=201$ and arrangements of 203 balls in a row is as follows. Given a solution of the equation, we put $x^{\prime}$ white balls in a row, then a black ball, then $y^{\prime}$ white balls, then a black ball, then $z$ white balls. This is like having 203 balls in a row on a table and picking two of them to be black. To go from an arrangement of balls to a solution of the equation, we just read off $x^{\prime}, y^{\prime}$, and $z$ from the number of white balls in a row. There are $\binom{203}{2}$ ways to choose 2 of 203 balls to be black, so there are $\binom{203}{2}$ solutions to $x^{\prime}+y^{\prime}+z=201$.
+6. [5] An ant starts out at $(0,0)$. Each second, if it is currently at the square $(x, y)$, it can move to $(x-1, y-1),(x-1, y+1),(x+1, y-1)$, or $(x+1, y+1)$. In how many ways can it end up at $(2010,2010)$ after 4020 seconds?
+Answer: $\binom{4020}{1005}^{2}$ Note that each of the coordinates either increases or decreases the $x$ and $y$ coordinates by 1. In order to reach 2010 after 4020 steps, each of the coordinates must be increased 3015 times and decreased 1005 times. A permutation of 3015 plusses and 1005 minuses for each of $x$ and $y$ uniquely corresponds to a path the ant could take to $(2010,2010)$, because we can take ordered pairs from the two lists and match them up to a valid step the ant can take. So the number of ways the ant can end up at $(2010,2010)$ after 4020 seconds is equal to the number of ways to arrange plusses and minuses for both $x$ and $y$, or $\left(\binom{4020}{1005}\right)^{2}$.
+7. [6] For each integer $x$ with $1 \leq x \leq 10$, a point is randomly placed at either $(x, 1)$ or $(x,-1)$ with equal probability. What is the expected area of the convex hull of these points? Note: the convex hull of a finite set is the smallest convex polygon containing it.
+Answer: $\frac{1793}{\frac{1728}{128}}$ Let $n=10$. Given a random variable $X$, let $\mathbb{E}(X)$ denote its expected value. If all points are collinear, then the convex hull has area zero. This happens with probability $\frac{2}{2^{n}}$ (either all points are at $y=1$ or all points are at $y=-1$ ). Otherwise, the points form a trapezoid with height 2 (the trapezoid is possibly degenerate, but this won't matter for our calculation). Let $x_{1, l}$ be the $x$-coordinate of the left-most point at $y=1$ and $x_{1, r}$ be the $x$-coordinate of the right-most point at $y=1$. Define $x_{-1, l}$ and $x_{-1, r}$ similarly for $y=-1$. Then the area of the trapezoid is
+
+$$
+2 \cdot \frac{\left(x_{1, r}-x_{1, l}\right)+\left(x_{-1, r}-x_{-1, l}\right)}{2}=x_{1, r}+x_{-1, r}-x_{1, l}-x_{-1, l} .
+$$
+
+The expected area of the convex hull (assuming the points are not all collinear) is then, by linearity of expectation,
+
+$$
+\mathbb{E}\left(x_{1, r}+x_{-1, r}-x_{1, l}-x_{-1, l}\right)=\mathbb{E}\left(x_{1, r}\right)+\mathbb{E}\left(x_{-1, r}\right)-\mathbb{E}\left(x_{1, l}\right)-\mathbb{E}\left(x_{-1, l}\right) .
+$$
+
+We need only compute the expected values given in the above equation. Note that $x_{1, r}$ is equal to $k$ with probability $\frac{2^{k-1}}{2^{n}-2}$, except that it is equal to $n$ with probability $\frac{2^{n-1}-1}{2^{n}-2}$ (the denominator is $2^{n}-2$ instead of $2^{n}$ because we need to exclude the case where all points are collinear). Therefore, the expected value of $x_{1, r}$ is equal to
+
+$$
+\begin{aligned}
+& \frac{1}{2^{n}-2}\left(\left(\sum_{k=1}^{n} k \cdot 2^{k-1}\right)-n \cdot 1\right) \\
+& \quad=\frac{1}{2^{n}-2}\left(\left(1+2+\cdots+2^{n-1}\right)+\left(2+4+\cdots+2^{n-1}\right)+\cdots+2^{n-1}-n\right) \\
+& =\frac{1}{2^{n}-2}\left(\left(2^{n}-1\right)+\left(2^{n}-2\right)+\cdots+\left(2^{n}-2^{n-1}\right)-n\right) \\
+& =\frac{1}{2^{n}-2}\left(n \cdot 2^{n}-\left(2^{n}-1\right)-n\right) \\
+& \quad=(n-1) \frac{2^{n}-1}{2^{n}-2}
+\end{aligned}
+$$
+
+Similarly, the expected value of $x_{-1, r}$ is also $(n-1) \frac{2^{n}-1}{2^{n}-2}$. By symmetry, the expected value of both $x_{1, l}$ and $x_{-1, l}$ is $n+1-(n-1) \frac{\frac{2}{n}^{n}-1}{2^{n}-2}$. This says that if the points are not all collinear then the expected area is $2 \cdot\left((n-1) \frac{2^{n}-1}{2^{n-1}-1}-(n+1)\right)$. So, the expected area is
+
+$$
+\begin{aligned}
+\frac{2}{2^{n}} \cdot 0+(1- & \left.\frac{2}{2^{n}}\right) \cdot 2 \cdot\left((n-1) \frac{2^{n}-1}{2^{n-1}-1}-(n+1)\right) \\
+& =2 \cdot \frac{2^{n-1}-1}{2^{n-1}} \cdot\left((n-1) \frac{2^{n}-1}{2^{n-1}-1}-(n+1)\right) \\
+& =2 \cdot \frac{(n-1)\left(2^{n}-1\right)-(n+1)\left(2^{n-1}-1\right)}{2^{n-1}} \\
+& =2 \cdot \frac{((2 n-2)-(n+1)) 2^{n-1}+2}{2^{n-1}} \\
+& =2 n-6+\frac{1}{2^{n-3}}
+\end{aligned}
+$$
+
+Plugging in $n=10$, we get $14+\frac{1}{128}=\frac{1793}{128}$.
+8. [6] How many functions $f$ from $\{-1005, \ldots, 1005\}$ to $\{-2010, \ldots, 2010\}$ are there such that the following two conditions are satisfied?
+
+- If $a Saturday 20 February 2010
General Test, Part 1
+
+
General Test, Part 1}
+
+1. [3] Suppose that $x$ and $y$ are positive reals such that
+
+$$
+x-y^{2}=3, \quad x^{2}+y^{4}=13
+$$
+
+Find $x$.
+Answer: $\frac{3+\sqrt{17}}{2}$ Squaring both sides of $x-y^{2}=3$ gives $x^{2}+y^{4}-2 x y^{2}=9$. Subtract this equation from twice the second given to get $x^{2}+2 x y^{2}+y^{4}=17 \Longrightarrow x+y^{2}= \pm 17$. Combining this equation with the first given, we see that $x=\frac{3 \pm \sqrt{17}}{2}$. Since $x$ is a positive real, $x$ must be $\frac{3+\sqrt{17}}{2}$.
+2. [3] Let $S=\{1,2,3,4,5,6,7,8,9,10\}$. How many (potentially empty) subsets $T$ of $S$ are there such that, for all $x$, if $x$ is in $T$ and $2 x$ is in $S$ then $2 x$ is also in $T$ ?
+Answer: 180 We partition the elements of $S$ into the following subsets: $\{1,2,4,8\},\{3,6\},\{5,10\}$, $\{7\},\{9\}$. Consider the first subset, $\{1,2,4,8\}$. Say 2 is an element of $T$. Because $2 \cdot 2=4$ is in $S, 4$ must also be in $T$. Furthermore, since $4 \cdot 2=8$ is in $S, 8$ must also be in $T$. So if $T$ contains 2 , it must also contain 4 and 8 . Similarly, if $T$ contains 1 , it must also contain 2,4 , and 8 . So $T$ can contain the following subsets of the subset $\{1,2,4,8\}$ : the empty set, $\{8\},\{4,8\},\{2,4,8\}$, or $\{1,2,4,8\}$. This gives 5 possibilities for the first subset. In general, we see that if $T$ contains an element $q$ of one of these subsets, it must also contain the elements in that subset that are larger than $q$, because we created the subsets for this to be true. So there are 3 possibilities for $\{3,6\}, 3$ for $\{5,10\}, 2$ for $\{7\}$, and 2 for $\{9\}$. This gives a total of $5 \cdot 3 \cdot 3 \cdot 2 \cdot 2=180$ possible subsets $T$.
+3. [4] A rectangular piece of paper is folded along its diagonal (as depicted below) to form a non-convex pentagon that has an area of $\frac{7}{10}$ of the area of the original rectangle. Find the ratio of the longer side of the rectangle to the shorter side of the rectangle.
+
+
+Answer: $\sqrt{5}$
+
+
+Given a polygon $P_{1} P_{2} \cdots P_{k}$, let $\left[P_{1} P_{2} \cdots P_{k}\right]$ denote its area. Let $A B C D$ be the rectangle. Suppose we fold $B$ across $\overline{A C}$, and let $E$ be the intersection of $\overline{A D}$ and $\overline{B^{\prime} C}$. Then we end up with the pentagon $A C D E B^{\prime}$, depicted above. Let's suppose, without loss of generality, that $A B C D$ has area 1. Then $\triangle A E C$ must have area $\frac{3}{10}$, since
+
+$$
+\begin{aligned}
+{[A B C D] } & =[A B C]+[A C D] \\
+& =\left[A B^{\prime} C\right]+[A C D] \\
+& =\left[A B^{\prime} E\right]+2[A E C]+[E D C] \\
+& =\left[A C D E B^{\prime}\right]+[A E C] \\
+& =\frac{7}{10}[A B C D]+[A E C],
+\end{aligned}
+$$
+
+That is, $[A E C]=\frac{3}{10}[A B C D]=\frac{3}{10}$.
+Since $\triangle E C D$ is congruent to $\triangle E A B^{\prime}$, both triangles have area $\frac{1}{5}$. Note that $\triangle A B^{\prime} C, \triangle A B C$, and $\triangle C D A$ are all congruent, and all have area $\frac{1}{2}$. Since $\triangle A E C$ and $\triangle E D C$ share altitude $\overline{D C}$, $\frac{D E}{E A}=\frac{[D E C]}{[A E C]}=\frac{2}{3}$. Because $\triangle C A E$ is isosceles, $C E=E A$. Let $A E=3 x$. The $C E=3 x, D E=2 x$, and $C D=x \sqrt{9-4}=x \sqrt{5}$. Then $\frac{A D}{D C}=\frac{A E+E D}{D C}=\frac{3+2}{\sqrt{5}}=\sqrt{5}$.
+4. [4] Let $S_{0}=0$ and let $S_{k}$ equal $a_{1}+2 a_{2}+\ldots+k a_{k}$ for $k \geq 1$. Define $a_{i}$ to be 1 if $S_{i-1}1$, because we may hold all but one of the $\pm$ choices constant, and change the remaining one).
+9. [7] Three unit circles $\omega_{1}, \omega_{2}$, and $\omega_{3}$ in the plane have the property that each circle passes through the centers of the other two. A square $S$ surrounds the three circles in such a way that each of its four sides is tangent to at least one of $\omega_{1}, \omega_{2}$ and $\omega_{3}$. Find the side length of the square $S$.
+Answer: $\frac{\sqrt{6}+\sqrt{2}+8}{4}$
+
+
+By the Pigeonhole Principle, two of the sides must be tangent to the same circle, say $\omega_{1}$. Since $S$ surrounds the circles, these two sides must be adjacent, so we can let $A$ denote the common vertex of the two sides tangent to $\omega_{1}$. Let $B, C$, and $D$ be the other vertices of $S$ in clockwise order, and let $P, Q$, and $R$ be the centers of $\omega_{1}, \omega_{2}$, and $\omega_{3}$ respectively, and suppose WLOG that they are also in clockwise order. Then $A C$ passes through the center of $\omega_{1}$, and by symmetry ( since $A B=A D$ ) it
+must also pass through the other intersection point of $\omega_{2}$ and $\omega_{3}$. That is, $A C$ is the radical axis of $\omega_{2}$ and $\omega_{3}$.
+Now, let $M$ and $N$ be the feet of the perpendiculars from $P$ and $R$, respectively, to side $A D$. Let $E$ and $F$ be the feet of the perpendiculars from $P$ to $A B$ and from $R$ to $D C$, respectively. Then $P E A M$ and $N R F D$ are rectangles, and $P E$ and $R F$ are radii of $\omega_{1}$ and $\omega_{2}$ respectively. Thus $A M=E P=1$ and $N D=R F=1$. Finally, we have
+
+$$
+\begin{aligned}
+M N & =P R \cdot \cos \left(180^{\circ}-\angle E P R\right) \\
+& =\cos \left(180^{\circ}-E P Q-R P Q\right) \\
+& =-\cos \left(\left(270^{\circ}-60^{\circ}\right) / 2+60^{\circ}\right) \\
+& =-\cos \left(165^{\circ}\right) \\
+& =\cos \left(15^{\circ}\right) \\
+& =\frac{\sqrt{6}+\sqrt{2}}{4} .
+\end{aligned}
+$$
+
+Thus $A D=A M+M N+N D=1+\frac{\sqrt{6}+\sqrt{2}}{4}+1=\frac{\sqrt{6}+\sqrt{2}+8}{4}$ as claimed.
+10. [8] Let $a, b, c, x, y$, and $z$ be complex numbers such that
+
+$$
+a=\frac{b+c}{x-2}, \quad b=\frac{c+a}{y-2}, \quad c=\frac{a+b}{z-2} .
+$$
+
+If $x y+y z+z x=67$ and $x+y+z=2010$, find the value of $x y z$.
+Answer: -5892 Manipulate the equations to get a common denominator: $a=\frac{b+c}{x-2} \Longrightarrow x-2=$ $\frac{b+c}{a} \Longrightarrow x-1=\frac{a+b+c}{a} \Longrightarrow \frac{1}{x-1}=\frac{a}{a+b+c}$; similarly, $\frac{1}{y-1}=\frac{b}{a+b+c}$ and $\frac{1}{z-1}=\frac{c}{a+b+c}$. Thus
+
+$$
+\begin{aligned}
+\frac{1}{x-1}+\frac{1}{y-1}+\frac{1}{z-1} & =1 \\
+(y-1)(z-1)+(x-1)(z-1)+(x-1)(y-1) & =(x-1)(y-1)(z-1) \\
+x y+y z+z x-2(x+y+z)+3 & =x y z-(x y+y z+z x)+(x+y+z)-1 \\
+x y z-2(x y+y z+z x)+3(x+y+z)-4 & =0 \\
+x y z-2(67)+3(2010)-4 & =0 \\
+x y z & =-5892
+\end{aligned}
+$$
+
diff --git a/HarvardMIT/md/en-132-2010-feb-gen2-solutions.md b/HarvardMIT/md/en-132-2010-feb-gen2-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..ed4918f4faad6d671d156a8d6c20b295cd8aff77
--- /dev/null
+++ b/HarvardMIT/md/en-132-2010-feb-gen2-solutions.md
@@ -0,0 +1,126 @@
+## $13^{\text {th }}$ Annual Harvard-MIT Mathematics Tournament
Saturday 20 February 2010
+
+## General Test, Part 2
+
+1. [3] Below is pictured a regular seven-pointed star. Find the measure of angle $a$ in radians.
+
+
+Answer: | $\frac{3 \pi}{7}$ |
+| :---: | The measure of the interior angle of a point of the star is $\frac{\pi}{7}$ because it is an inscribed angle on the circumcircle which intercepts a seventh of the circle ${ }^{1}$
+
+
+
+Consider the triangle shown above in bold. Because the sum of the angles in any triangle is $\pi$,
+
+$$
+2 \varphi+3\left(\frac{\pi}{7}\right)=\pi=2 \varphi+a
+$$
+
+Canceling the $2 \varphi$ on the right-hand side and on the left-hand side, we obtain
+
+$$
+a=\frac{3 \pi}{7} .
+$$
+
+2. [3] The rank of a rational number $q$ is the unique $k$ for which $q=\frac{1}{a_{1}}+\cdots+\frac{1}{a_{k}}$, where each $a_{i}$ is the smallest positive integer such that $q \geq \frac{1}{a_{1}}+\cdots+\frac{1}{a_{i}}$. Let $q$ be the largest rational number less than $\frac{1}{4}$ with rank 3 , and suppose the expression for $q$ is $\frac{1}{a_{1}}+\frac{1}{a_{2}}+\frac{1}{a_{3}}$. Find the ordered triple $\left(a_{1}, a_{2}, a_{3}\right)$.
+Answer: $(5,21,421)$ Suppose that $A$ and $B$ were rational numbers of rank 3 less than $\frac{1}{4}$, and let $a_{1}, a_{2}, a_{3}, b_{1}, b_{2}, b_{3}$ be positive integers so that $A=\frac{1}{a_{1}}+\frac{1}{a_{2}}+\frac{1}{a_{3}}$ and $B=\frac{1}{b_{1}}+\frac{1}{b_{2}}+\frac{1}{b_{3}}$ are the expressions for $A$ and $B$ as stated in the problem. If $b_{1}
Geometry Subject Test
+
+1. [3] Below is pictured a regular seven-pointed star. Find the measure of angle $a$ in radians.
+
+
+Answer: | $3 \pi$ |
+| :---: |
+| 7 | The measure of the interior angle of a point of the star is $\frac{\pi}{7}$ because it is an inscribed angle on the circumcircle which intercepts a seventh of the circle ${ }^{1}$
+
+
+
+Consider the triangle shown above in bold. Because the sum of the angles in any triangle is $\pi$,
+
+$$
+2 \varphi+3\left(\frac{\pi}{7}\right)=\pi=2 \varphi+a
+$$
+
+Canceling the $2 \varphi$ on the right-hand side and on the left-hand side, we obtain
+
+$$
+a=\frac{3 \pi}{7} .
+$$
+
+2. [3] A rectangular piece of paper is folded along its diagonal (as depicted below) to form a non-convex pentagon that has an area of $\frac{7}{10}$ of the area of the original rectangle. Find the ratio of the longer side of the rectangle to the shorter side of the rectangle.
+
+
+Answer: $\sqrt{5}$
+
+[^0]
+
+Given a polygon $P_{1} P_{2} \cdots P_{k}$, let $\left[P_{1} P_{2} \cdots P_{k}\right]$ denote its area. Let $A B C D$ be the rectangle. Suppose we fold $B$ across $\overline{A C}$, and let $E$ be the intersection of $\overline{A D}$ and $\overline{B^{\prime} C}$. Then we end up with the pentagon $A C D E B^{\prime}$, depicted above. Let's suppose, without loss of generality, that $A B C D$ has area 1. Then $\triangle A E C$ must have area $\frac{3}{10}$, since
+
+$$
+\begin{aligned}
+{[A B C D] } & =[A B C]+[A C D] \\
+& =\left[A B^{\prime} C\right]+[A C D] \\
+& =\left[A B^{\prime} E\right]+2[A E C]+[E D C] \\
+& =\left[A C D E B^{\prime}\right]+[A E C] \\
+& =\frac{7}{10}[A B C D]+[A E C]
+\end{aligned}
+$$
+
+That is, $[A E C]=\frac{3}{10}[A B C D]=\frac{3}{10}$.
+Since $\triangle E C D$ is congruent to $\triangle E A B^{\prime}$, both triangles have area $\frac{1}{5}$. Note that $\triangle A B^{\prime} C, \triangle A B C$, and $\triangle C D A$ are all congruent, and all have area $\frac{1}{2}$. Since $\triangle A E C$ and $\triangle E D C$ share altitude $\overline{D C}$, $\frac{D E}{E A}=\frac{[D E C]}{[A E C]}=\frac{2}{3}$. Because $\triangle C A E$ is isosceles, $C E=E A$. Let $A E=3 x$. The $C E=3 x, D E=2 x$, and $C D=x \sqrt{9-4}=x \sqrt{5}$. Then $\frac{A D}{D C}=\frac{A E+E D}{D C}=\frac{3+2}{\sqrt{5}}=\sqrt{5}$.
+3. [4] For $0 \leq y \leq 2$, let $D_{y}$ be the half-disk of diameter 2 with one vertex at $(0, y)$, the other vertex on the positive $x$-axis, and the curved boundary further from the origin than the straight boundary. Find the area of the union of $D_{y}$ for all $0 \leq y \leq 2$.
+Answer: $\pi$
+
+
+From the picture above, we see that the union of the half-disks will be a quarter-circle with radius 2 , and therefore area $\pi$. To prove that this is the case, we first prove that the boundary of every half-disk intersects the quarter-circle with radius 2 , and then that the half-disk is internally tangent to the quarter-circle at that point. This is sufficient because it is clear from the diagram that we need not worry about covering the interior of the quarter-circle.
+
+Let $O$ be the origin. For a given half-disk $D_{y}$, label the vertex on the $y$-axis $A$ and the vertex on the $x$-axis $B$. Let $M$ be the midpoint of line segment $\overline{A B}$. Draw segment $O M$, and extend it until it intersects the curved boundary of $D_{y}$. Label the intersection point $C$. This construction is shown in the diagram below.
+
+
+We first prove that $C$ lies on the quarter-circle, centered at the origin, with radius 2 . Since $M$ is the midpoint of $\overline{A B}$, and $A$ is on the $y$-axis, $M$ is horizontally halfway between $B$ and the $y$-axis. Since $O$ and $B$ are on the $x$-axis (which is perpendicular to the $y$-axis), segments $\overline{O M}$ and $\overline{M B}$ have the same length. Since $M$ is the midpoint of $\overline{A B}$, and $A B=2, O M=1$. Since $D_{y}$ is a half-disk with radius 1 , all points on its curved boundary are 1 away from its center, $M$. Then $C$ is 2 away from the origin, and the quarter-circle consists of all points which are 2 away from the origin. Thus, $C$ is an intersection of the half-disk $D_{y}$ with the positive quarter-circle of radius 2 .
+It remains to show that the half-disk $D_{y}$ is internally tangent to the quarter-circle. Since $\overline{O C}$ is a radius of the quarter-circle, it is perpendicular to the tangent of the quarter-circle at $C$. Since $\overline{M C}$ is a radius of the half-disk, it is perpendicular to the tangent of the half-disk at $C$. Then the tangents lines of the half-disk and the quarter-circle coincide, and the half-disk is tangent to the quarter-circle. It is obvious from the diagram that the half-disk lies at least partially inside of the quarter-circle, the half-disk $D_{y}$ is internally tangent to the quarter-circle.
+Then the union of the half-disks is be a quarter-circle with radius 2 , and has area $\pi$.
+4. [4] Let $A B C D$ be an isosceles trapezoid such that $A B=10, B C=15, C D=28$, and $D A=15$. There is a point $E$ such that $\triangle A E D$ and $\triangle A E B$ have the same area and such that $E C$ is minimal. Find $E C$.
+Answer: $\frac{216}{\sqrt{145}}$
+
+
+Geometry Subject Test
+
+The locus of points $E$ such that $[A E D]=[A E B]$ forms a line, since area is a linear function of the coordinates of $E$; setting the areas equal gives a linear equation in the coordinates $E^{2}$. Note that $A$ and $M$, the midpoint of $\overline{D B}$, are on this line; $A$ because both areas are 0 , and $M$ because the triangles share an altitude, and bases $\overline{D M}$ and $\overline{M B}$ are equal in length. Then $\overline{A M}$ is the set of points satisfying the area condition. The point $E$, then, is such that $\triangle A E C$ is a right angle (to make the distance minimal) and $E$ lies on $\overline{A M}$.
+Let $X$ be the point of intersection of $\overline{A M}$ and $\overline{C D}$. Then $\triangle A M B \sim \triangle X M D$, and since $M D=B M$, they are in fact congruent. Thus $D X=A B=10$, and $X C=18$. Similarly, $B X=15$, so $A B X D$ is a parallelogram. Let $Y$ be the foot of the perpendicular from $A$ to $\overline{D C}$, so that $D Y=\frac{D C-A B}{2}=9$. Then $A Y=\sqrt{A D^{2}-D Y^{2}}=\sqrt{225-81}=12$. Then $Y X=D X-D Y=1$ and $A X=\sqrt{A Y^{2}+Y X^{2}}=$ $\sqrt{144+1}=\sqrt{145}$. Since both $\triangle A X Y$ and $\triangle C X E$ have a right angle, and $\angle E X C$ and $\angle Y X A$ are congruent because they are vertical angles, $\triangle A X Y \sim \triangle C X E$. Then $\frac{C E}{A Y}=\frac{C X}{A X}$, so $C E=12 \cdot \frac{18}{\sqrt{145}}=$ $\frac{216}{\sqrt{145}}$.
+5. [4] A sphere is the set of points at a fixed positive distance $r$ from its center. Let $\mathcal{S}$ be a set of 2010dimensional spheres. Suppose that the number of points lying on every element of $\mathcal{S}$ is a finite number $n$. Find the maximum possible value of $n$.
+Answer: 2 The answer is 2 for any number of dimensions. We prove this by induction on the dimension.
+Note that 1-dimensional spheres are pairs of points, and 2-dimensional spheres are circles.
+Base case, $d=2$ : The intersection of two circles is either a circle (if the original circles are identical, and in the same place), a pair of points, a single point (if the circles are tangent), or the empty set. Thus, in dimension 2, the largest finite number of intersection points is 2 , because the number of pairwise intersection points is 0,1 , or 2 for distinct circles.
+We now prove that the intersection of two $k$-dimensional spheres is either the empty set, a $(k-1)$ dimensional sphere, a $k$-dimensional sphere (which only occurs if the original spheres are identical and coincident). Consider two spheres in $k$-dimensional space, and impose a coordinate system such that the centers of the two spheres lie on one coordinate axis. Then the equations for the two spheres become identical in all but one coordinate:
+
+$$
+\begin{aligned}
+& \left(x_{1}-a_{1}\right)^{2}+x_{2}^{2}+\ldots+x_{k}^{2}=r_{1}^{2} \\
+& \left(x_{1}-a_{2}\right)^{2}+x_{2}^{2}+\ldots+x_{k}^{2}=r_{2}^{2}
+\end{aligned}
+$$
+
+If $a_{1}=a_{2}$, the spheres are concentric, and so they are either nonintersecting or coincident, intersecting in a $k$-dimensional sphere. If $a_{1} \neq a_{2}$, then subtracting the equations and solving for $x_{1}$ yields $x_{1}=\frac{r_{1}^{2}-a_{1}^{2}-r_{2}^{2}+a_{2}^{2}}{2\left(a_{2}-a_{2}\right)}$. Plugging this in to either equation above yields a single equation equation that describes a $(k-1)$-dimensional sphere.
+Assume we are in dimension $d$, and suppose for induction that for all $k$ less than $d$, any two distinct $k$-dimensional spheres intersecting in a finite number of points intersect in at most two points. Suppose we have a collection of $d$-dimensional spheres $s_{1}, s_{2}, \ldots, s_{m}$. Without loss of generality, suppose the $s_{i}$ are distinct. Let $t_{i}$ be the intersection of $s_{i}$ and $s_{i+1}$ for $1 \leq i
1 1 3
2 3 1 | 2 | 3 |
+
+The next two can be flipped diagonally to create different arrangements:
+
+| 6 | 1 | 2 | | | |
+| :--- | :--- | :--- | :--- | :--- | :--- |
+| 1 | 2 | 3 | 6 1 | 2 | |
+| 1 | 2 | 3 | | | |
+| 1 | 3 | 2 | 3 | 1 | 2 |
+
+Those seven arrangements can be rotated 90, 180, and 270 degrees about the center to generate a total of 28 arrangements. $28 \cdot 3!3!2!=2016$.
+15. [8] Pick a random integer between 0 and 4095, inclusive. Write it in base 2 (without any leading zeroes). What is the expected number of consecutive digits that are not the same (that is, the expected number of occurrences of either 01 or 10 in the base 2 representation)?
+Answer: $\frac{20481}{4096}$ Note that every number in the range can be written as a 12-digit binary string. For $i=1,2, \ldots 11$, let $R_{i}$ be a random variable which is 1 if the $i$ th and $(i+1)$ st digits differ in a randomly chosen number in the range. By linearity of expectation, $E\left(\sum_{i} R_{i}\right)=\sum E\left(R_{i}\right)$.
+Since we choose every binary string of length 12 with equal probability, the sum of the expectations is $\frac{11}{2}$. However, this is not the expected number of 01 s and $10 s$ - we need to subtract the occasions where the leading digit is zero. There is a $\frac{1}{2}$ chance that the number starts with a 0 , in which case we must ignore the first digit change - unless the number was 0 , in which case there are no digit changes. Therefore, our answer is $\frac{11}{2}-\frac{1}{2}+\frac{1}{4096}=\frac{20481}{4096}$.
+$13^{\text {th }}$ ANNUAL HARVARD-MIT MATHEMATICS TOURNAMENT, 20 FEBRUARY 2010 - GUTS ROUND
+16. [9] Jessica has three marbles colored red, green, and blue. She randomly selects a non-empty subset of them (such that each subset is equally likely) and puts them in a bag. You then draw three marbles from the bag with replacement. The colors you see are red, blue, red. What is the probability that the only marbles in the bag are red and blue?
+
+Answer: | $\frac{27}{35}$ |
+| :---: |
+| There are two possible sets of marbles in the bag, $\{$ red,blue\} and \{red,blue,green\}. | Initially, both these sets are equally likely to be in the bag. However, the probability of red, blue, red being drawn from a set $S$ of marbles is proportional to $|S|^{-3}$, as long as red and blue are both in $S$. By Bayes's Rule, we must weight the probability of these two sets by $|S|^{-3}$. The answer is $\frac{(1 / 2)^{3}}{(1 / 2)^{3}+(1 / 3)^{3}}$.
+
+17. [9] An ant starts at the origin, facing in the positive $x$-direction. Each second, it moves 1 unit forward, then turns counterclockwise by $\sin ^{-1}\left(\frac{3}{5}\right)$ degrees. What is the least upper bound on the distance between the ant and the origin? (The least upper bound is the smallest real number $r$ that is at least as big as every distance that the ant ever is from the origin.)
+Answer: $\sqrt{10}$ We claim that the points the ant visits lie on a circle of radius $\frac{\sqrt{10}}{2}$. We show this by saying that the ant stays a constant distance $\frac{\sqrt{10}}{2}$ from the point $\left(\frac{1}{2}, \frac{3}{2}\right)$.
+Suppose the ant moves on a plane $P$. Consider a transformation of the plane $P^{\prime}$ such that after the first move, the ant is at the origin of $P^{\prime}$ and facing in the direction of the $x^{\prime}$ axis (on $P^{\prime}$ ). The transformation to get from $P$ to $P^{\prime}$ can be gotten by rotating $P$ about the origin counterclockwise through an angle $\sin ^{-1}\left(\frac{3}{5}\right)$ and then translating it 1 unit to the right. Observe that the point $\left(\frac{1}{2}, \frac{3}{2}\right)$ is fixed under this transformation, which can be shown through the expression $\left(\frac{1}{2}+\frac{3}{2} i\right)\left(\frac{4}{5}+\frac{3}{5} i\right)+1=\frac{1}{2}+\frac{3}{2} i$. It follows that at every point the ant stops, it will always be the same distance from $\left(\frac{1}{2}, \frac{3}{2}\right)$. Since it starts at $(0,0)$, this fixed distance is $\frac{\sqrt{10}}{2}$.
+
+
+Since $\sin ^{-1}\left(\frac{3}{5}\right)$ is not a rational multiple of $\pi$, the points the ant stops at form a dense subset of the circle in question. As a result, the least upper bound on the distance between the ant and the origin is the diameter of the circle, which is $\sqrt{10}$.
+18. [9] Find two lines of symmetry of the graph of the function $y=x+\frac{1}{x}$. Express your answer as two equations of the form $y=a x+b$.
+Answer: $y=(1+\sqrt{2}) x$ and $y=(1-\sqrt{2}) x$ The graph of the function $y=x+\frac{1}{x}$ is a hyperbola. We can see this more clearly by writing it out in the standard form $x^{2}-x y+1=0$ or $\left(\frac{y}{2}\right)^{2}-\left(x-\frac{1}{2} y\right)^{2}=1$. The hyperbola has asymptotes given by $x=0$ and $y=x$, so the lines of symmetry will be the (interior and exterior) angle bisectors of these two lines. This means that they will be $y=\tan \left(67.5^{\circ}\right) x$ and $y=-\cot \left(67.5^{\circ}\right) x$, which, using the tangent half-angle formula $\tan \left(\frac{x}{2}\right)=\sqrt{\frac{1+\cos (x)}{1-\cos (x)}}$, gives the two lines $y=(1+\sqrt{2}) x$ and $y=(1-\sqrt{2}) x$.
+$13^{\text {th }}$ ANNUAL HARVARD-MIT MATHEMATICS TOURNAMENT, 20 FEBRUARY 2010 - GUTS ROUND
+19. [10] A 5-dimensional ant starts at one vertex of a 5 -dimensional hypercube of side length 1 . A move is when the ant travels from one vertex to another vertex at a distance of $\sqrt{2}$ away. How many ways can the ant make 5 moves and end up on the same vertex it started at?
+Answer: 6240 We let the cube lie in $\mathbb{R}^{5}$ with each corner with coordinates 1 or 0 . Assume the ant starts at $(0,0,0,0,0)$. Every move the ant adds or subtracts 1 to two of the places. Note that this means the ant can only land on a vertex with the sum of its coordinates an even number. Every move the ant has $\binom{5}{2}=10$ choices.
+From any vertex there are 10 two-move sequences that put the ant at the same vertex it started at.
+There are 6 two-move sequences to move from one vertex to a different, chosen vertex. If your chosen vertex differs from your current vertex by 2 of the 5 coordinates, your first move corrects for one of these two. There are 2 ways to choose which coordinate to correct for on the first move, and there are 3 ways to choose the second coordinate you change, yielding 6 sequences. If your chosen vertex differs from your current vertex by 4 of the 5 coordinates, each move corrects for two of these four. This yields $\binom{4}{2}=6$ sequences.
+Finally, there are 60 three-move sequences that put the ant at the same vertex it started at. There are 10 ways to choose the first move, and there are 6 ways to make two moves to return to your original position.
+The motion of the ant can be split into two cases.
+Case 1: After the 3rd move the ant is on the vertex it started at. There are $(60)(10)=600$ different possible paths.
+Case 2: After the third move the ant is on a vertex different from the one it started on. There are $\left(10^{3}-60\right)(6)=(940)(6)=5640$ different possible paths.
+So there are 6240 total possible paths.
+20. [10] Find the volume of the set of points $(x, y, z)$ satisfying
+
+$$
+\begin{aligned}
+x, y, z & \geq 0 \\
+x+y & \leq 1 \\
+y+z & \leq 1 \\
+z+x & \leq 1
+\end{aligned}
+$$
+
+Answer: $\frac{1}{4}$ Without loss of generality, assume that $x \geq y$ - half the volume of the solid is on this side of the plane $x=y$. For each value of $c$ from 0 to $\frac{1}{2}$, the region of the intersection of this half of the solid with the plane $y=c$ is a trapezoid. The trapezoid has height $1-2 c$ and average base $\frac{1}{2}$, so it has an area of $\frac{1}{2}-c$.
+The total volume of this region is $\frac{1}{2}$ times the average area of the trapezoids, which is $\frac{1}{2} \cdot \frac{1}{4}=\frac{1}{8}$. Double that to get the total volume, which is $\frac{1}{4}$.
+21. [10] Let $\triangle A B C$ be a scalene triangle. Let $h_{a}$ be the locus of points $P$ such that $|P B-P C|=|A B-A C|$. Let $h_{b}$ be the locus of points $P$ such that $|P C-P A|=|B C-B A|$. Let $h_{c}$ be the locus of points $P$ such that $|P A-P B|=|C A-C B|$. In how many points do all of $h_{a}, h_{b}$, and $h_{c}$ concur?
+Answer: 2 The idea is similar to the proof that the angle bisectors concur or that the perpendicular bisectors concur. Assume WLOG that $B C>A B>C A$. Note that $h_{a}$ and $h_{b}$ are both hyperbolas. Therefore, $h_{a}$ and $h_{b}$ intersect in four points (each branch of $h_{a}$ intersects exactly once with each branch of $h_{b}$ ). Note that the branches of $h_{a}$ correspond to the cases when $P B>P C$ and when $P B
Saturday 20 February 2010
Team Round A
+
+
Team Round A}
+
+1. You are trying to sink a submarine. Every second, you launch a missile at a point of your choosing on the $x$-axis. If the submarine is at that point at that time, you sink it. A firing sequence is a sequence of real numbers that specify where you will fire at each second. For example, the firing sequence $2,3,5,6, \ldots$ means that you will fire at 2 after one second, 3 after two seconds, 5 after three seconds, 6 after four seconds, and so on.
+(a) [5] Suppose that the submarine starts at the origin and travels along the positive $x$-axis with an (unknown) positive integer velocity. Show that there is a firing sequence that is guaranteed to hit the submarine eventually.
+Solution: The firing sequence $1,4,9, \ldots, n^{2}, \ldots$ works. If the velocity of the submarine is $v$, then after $v$ seconds it will be at $x=v^{2}$, the same location where the mine explodes at time $v$.
+(b) [10] Suppose now that the submarine starts at an unknown integer point on the non-negative $x$-axis and again travels with an unknown positive integer velocity. Show that there is still a firing sequence that is guaranteed to hit the submarine eventually.
+Solution: Represent the submarine's motion by an ordered pair ( $a, b$ ), where $a$ is the starting point of the submarine and $b$ is its velocity. We want to find a way to map each positive integer to a possible ordered pair so that every ordered pair is covered. This way, if we fire at $b_{n} n+a_{n}$ at time $n$, where $\left(a_{n}, b_{n}\right)$ is the point that $n$ maps to, then we will eventually hit the submarine. (Keep in mind that $b_{n} n+a_{n}$ would be the location of the submarine at time $n$.) There are many such ways to map the positive integers to possible points; here is one way:
+
+$$
+\begin{aligned}
+& 1 \rightarrow(1,1), 2 \rightarrow(2,1), 3 \rightarrow(1,2), 4 \rightarrow(3,1), 5 \rightarrow(2,2), 6 \rightarrow(1,3), 7 \rightarrow(4,1), 8 \rightarrow(3,2), \\
+& 9 \rightarrow(2,3), 10 \rightarrow(1,4), 11 \rightarrow(5,1), 12 \rightarrow(4,2), 13 \rightarrow(3,3), 14 \rightarrow(2,4), 15 \rightarrow(1,5), \ldots
+\end{aligned}
+$$
+
+(The path of points trace out diagonal lines that sweep every lattice point in the coordinate plane.) Since we cover every point, we will eventually hit the submarine.
+Remark: The mapping shown above is known as a bijection between the positive integers and ordered pairs of integers $(a, b)$ where $b>0$.
+2. [15] Consider the following two-player game. Player 1 starts with a number, $N$. He then subtracts a proper divisor of $N$ from $N$ and gives the result to player 2 (a proper divisor of $N$ is a positive divisor of $N$ that is not equal to 1 or $N)$. Player 2 does the same thing with the number she gets from player 1 , and gives the result back to player 1. The two players continue until a player is given a prime number or 1 , at which point that player loses. For which values of $N$ does player 1 have a winning strategy?
+Answer: All even numbers except for odd powers of 2 . First we show that if you are stuck with an odd number, then you are guaranteed to lose. Suppose you have an odd number $a b$, where $a$ and $b$ are odd numbers, and you choose to subtract $a$. You pass your opponent the number $a(b-1)$. This cannot be a power of 2 (otherwise $a$ is a power of 2 and hence $a=1$, which is not allowed), so your opponent can find an odd proper divisor of $a(b-1)$, and you will have a smaller odd number. Eventually you will get to an odd prime and lose.
+Now consider even numbers that aren't powers of 2. As with before, you can find an odd proper divisor of $N$ and pass your opponent an odd number, so you are guaranteed to win.
+Finally consider powers of 2 . If you have the number $N=2^{k}$, it would be unwise to choose a proper divisor other than $2^{k-1}$; otherwise you would give your opponent an even number that isn't a power of 2 . Therefore if $k$ is odd, you will end up with 2 and lose. If $k$ is even, though, your opponent will end up with 2 and you will win.
+Therefore player 1 has a winning strategy for all even numbers except for odd powers of 2.
+3. [15] Call a positive integer in base $10 k$-good if we can split it into two integers y and z , such that y is all digits on the left and z is all digits on the right, and such that $y=k \cdot z$. For example, 2010 is 2 -good because we can split it into 20 and 10 and $20=2 \cdot 10.20010$ is also 2 -good, because we can split it into 20 and 010 . In addition, it is 20 -good, because we can split it into 200 and 10 .
+Show that there exists a 48 -good perfect square.
+Solution: We wish to find integers $a, z$ such that $48 z \cdot 10^{a}+z=z\left(48 \cdot 10^{a}+1\right)$ a perfect square, where $z<10^{a}$. This would prove that there exists a 48 -good perfect square because we are pulling off the last $a$ digits of the number and get two integers $48 z$ and $z$. To make $z$ small by keeping the product a perfect square, we'd like $48 \cdot 10^{a}+1$ to be divisible by some reasonably large square. Take $a=42=\varphi(49)$. By Euler's theorem, $10^{42} \equiv 1(\bmod 49)$, so $48 \cdot 10^{a}+1$ is a multiple of 49 . Then we can take $z=\frac{48 \cdot 10^{a}+1}{49}$. (Clearly $z<10^{a}$, so we're fine.) Then we have $z\left(48 \cdot 10^{a}+1\right)=\left(\frac{48 \cdot 10^{42}+1}{7}\right)^{2}$.
+4. [20] Let
+
+$$
+\begin{gathered}
+e^{x}+e^{y}=A \\
+x e^{x}+y e^{y}=B \\
+x^{2} e^{x}+y^{2} e^{y}=C \\
+x^{3} e^{x}+y^{3} e^{y}=D \\
+x^{4} e^{x}+y^{4} e^{y}=E .
+\end{gathered}
+$$
+
+Prove that if $A, B, C$, and $D$ are all rational, then so is $E$.
+Solution: We can express $x+y$ in two ways:
+
+$$
+\begin{aligned}
+& x+y=\frac{A D-B C}{A C-B^{2}} \\
+& x+y=\frac{A E-C^{2}}{A D-B C}
+\end{aligned}
+$$
+
+(We have to be careful if $A C-B^{2}$ or $A D-B C$ is zero. We'll deal with that case later.) It is easy to check that these equations hold by substituting the expressions for $A, B, C, D$, and $E$. Setting these two expressions for $x+y$ equal to each other, we get
+
+$$
+\frac{A D-B C}{A C-B^{2}}=\frac{A E-C^{2}}{A D-B C}
+$$
+
+which we can easily solve for $E$ as a rational function of $A, B, C$, and $D$. Therefore if $A, B, C$, and $D$ are all rational, then $E$ will be rational as well.
+Now, we have to check what happens if $A C-B^{2}=0$ or $A D-B C=0$. If $A C-B^{2}=0$, then writing down the expressions for $A, B$, and $C$ gives us that $(x-y)^{2} e^{x+y}=0$, meaning that $x=y$. If $x=y$, and $x \neq 0, A$ and $D$ are also non-zero, and $\frac{B}{A}=\frac{E}{D}=x$. Since $\frac{B}{A}$ is rational and $D$ is rational, this implies that $E$ is rational. If $x=y=0$, then $E=0$ and so is certainly rational.
+We finally must check what happens if $A D-B C=0$. Since $A D-B C=(x+y)\left(A C-B^{2}\right)$, either $A C-B^{2}=0$ (a case we have already dealt with), or $x+y=0$. But if $x+y=0$ then $A E-C^{2}=0$, which implies that $E=\frac{C^{2}}{A}$ (we know that $A \neq 0$ because $e^{x}$ and $e^{y}$ are both positive). Since $A$ and $C$ are rational, this implies that $E$ is also rational.
+So, we have shown $E$ to be rational in all cases, as desired.
+5. [20] Show that, for every positive integer $n$, there exists a monic polynomial of degree $n$ with integer coefficients such that the coefficients are decreasing and the roots of the polynomial are all integers.
+Solution: We claim we can find values $a$ and $b$ such that $p(x)=(x-a)(x+b)^{n}$ is a polynomial of degree $n+1$ that satisfies these constraints. We show that its coefficients are decreasing by finding a general formula for the coefficient of $x^{k}$.
+
+The coefficient of $x^{k}$ is $b^{k}\binom{n}{k}-a b^{k-1}\binom{n}{k-1}$, which can be seen by expanding out $(x+b)^{n}$ and then multiplying by $(x-a)$. Then we must prove that
+
+$$
+b^{k+1}\binom{n}{k+1}-a b^{k}\binom{n}{k}b^{k}\left(b\binom{n}{k+1}-\binom{n}{k}\right) .
+$$
+
+Choose $b>\max \left(\frac{\binom{n}{k}}{\binom{n}{k-1}}\right)$ in order to make sure the right-hand term in each product on each side of the inequality sign is positive (we'll be dividing by it, so this makes things much easier), and choose $a>\max \left(\frac{b\left(b\binom{n}{k+1}-\binom{n}{k}\right)}{b\binom{n}{k}-\binom{n}{k-1}}\right)$ to make sure the inequality always holds. Since there are only finite values that $k$ can take on given a fixed $n$ (namely, integers between 0 and $n$ inclusive), we can always find values of $a$ and $b$ that satisfy these constraints.
+6. [20] Let $S$ be a convex set in the plane with a finite area $a$. Prove that either $a=0$ or $S$ is bounded. Note: a set is bounded if it is contained in a circle of finite radius. Note: a set is convex if, whenever two points $A$ and $B$ are in the set, the line segment between them is also in the set.
+Solution: If all points in $S$ lie on a straight line, then $a=0$.
+Otherwise we may pick three points $A, B$, and $C$ that are not collinear. Let $\omega$ be the incircle of $\triangle A B C$, with $I$ its center and $r$ its radius. Since $S$ is convex, $S$ must contain $\omega$.
+
+
+Suppose $S$ also contains a point $X$ at a distance $d$ from $I$, with $d>R$. We will show that $d \leq \sqrt{r^{2}+\frac{a^{2}}{r^{2}}}$, which implies that the $S$ is bounded since all points are contained within the circle centered at $I$ of radius $\sqrt{r^{2}+\frac{a^{2}}{r^{2}}}$.
+Let $Y$ and $Z$ be on $\omega$ such that $\overline{X Y}$ and $\overline{X Z}$ are tangents to $\omega$. Because $S$ is convex, it must contain kite $I Y X Z$, whose area we can compute in terms of $d$ and $r$.
+Let $M$ be the midpoint of $\overline{Y Z}$. Since $\triangle I Y X \sim \triangle I M Y$, we know that $\frac{I M}{I Y}=\frac{I Y}{I X}$, that is, $I M=$ $\frac{(I Y)^{2}}{I X}=\frac{r^{2}}{d}$. Then $M Y=\sqrt{r^{2}-\frac{r^{4}}{d^{2}}}=r \sqrt{1-\left(\frac{r}{d}\right)^{2}}=\frac{1}{2} Y Z$.
+The area of $I Y X Z$ is $\frac{1}{2}(Y Z)(I X)=r d \sqrt{1-\left(\frac{r}{d}\right)^{2}}=r \sqrt{d^{2}-r^{2}}$. This must be less than or equal to $a$, the area of $S$. This yields $a^{2} \geq r^{2} d^{2}-r^{4}$ or $d^{2} \leq r^{2}+\frac{a^{2}}{r^{2}}$. It follows that $d \leq \sqrt{r^{2}+\frac{a^{2}}{r^{2}}}$, as desired.
+7. [25] Point $P$ lies inside a convex pentagon $A F Q D C$ such that $F P D Q$ is a parallelogram. Given that $\angle F A Q=\angle P A C=10^{\circ}$, and $\angle P F A=\angle P D C=15^{\circ}$. What is $\angle A Q C ?$
+Answer: $\frac{\pi}{12}$ Let $C^{\prime}$ be the point such that there is a spiral similarity between $\triangle A F P$ and $\triangle A Q C^{\prime}$. In other words, one triangle can be formed from the other by dilating and rotating about one of the
+triangle's vertices (in this case, $A$ ). We will show that $C^{\prime}$ is $C$, so our answer will be $\angle A Q C=$ $\angle A Q C^{\prime}=\angle A F P=15^{\circ}$. By the spiral similarity theorem, $\triangle A F Q \sim \triangle A P C^{\prime}$ (this is intuitive by looking at a diagram), so $\angle P A C=\angle F A Q=10^{\circ}$, so to show that $C^{\prime}$ is $C$, it is sufficient to show that $\angle P D C^{\prime}=15^{\circ}$.
+
+
+Let $X$ be the fourth point of the parallelogram $F P C^{\prime} X$ (see the above diagram). The angle between lines $\overline{F P}$ and $\overline{F A}$ is $15^{\circ}$. Since $\overline{X C^{\prime}} \| \overline{F P}$, the angle between $\overline{F A}$ and $\overline{X C^{\prime}}$ is $15^{\circ}$ as well. In addition, the angle between $\overline{Q A}$ and $\overline{Q C^{\prime}}$ is $\angle A Q C^{\prime}=15^{\circ}$, so $\angle X C^{\prime} Q=\angle F A Q$. Further, because $F P C^{\prime} X$ is a parallelogram, $\frac{Q C^{\prime}}{X C^{\prime}}=\frac{Q C^{\prime}}{F P}$. By similar triangles $\triangle A F P$ and $\triangle A Q C^{\prime}, \frac{Q C^{\prime}}{F P}=\frac{Q A}{F A}$. By SAS similarity, there is a spiral similarity between $\triangle X C^{\prime} Q$ and $\triangle F A Q$, so $\angle F Q X=\angle A Q C^{\prime}=15^{\circ}$.
+Note that the segments $\overline{F P}, \overline{X C^{\prime}}$, and $\overline{Q D}$ are all parallel and equal in length. Therefore, $\triangle F Q X \cong$ $\triangle P D C^{\prime}$ are congruent, and $\angle P D C^{\prime}=15^{\circ}$ as well. So $C^{\prime}$ is $C$, and $\angle A Q C=15^{\circ}$.
+8. [30] A knight moves on a two-dimensional grid. From any square, it can move 2 units in one axisparallel direction, then move 1 unit in an orthogonal direction, the way a regular knight moves in a game of chess. The knight starts at the origin. As it moves, it keeps track of a number $t$, which is initially 0 . When the knight lands at the point $(a, b)$, the number is changed from $x$ to $a x+b$.
+
+Show that, for any integers $a$ and $b$, it is possible for the knight to land at the points $(1, a)$ and $(-1, a)$ with $t$ equal to $b$.
+Solution: For convenience, we will refer to $(a, b)$ as $[a x+b]$, the function it represents. This will make it easier to follow the trajectory of $t$ over a given sequence of moves.
+Suppose we start at $[x+1]$ with $t=a$. Taking the path $[x+1] \rightarrow[-x] \rightarrow[x-1] \rightarrow[-x] \rightarrow[x+1]$ will yield $t=a+2$. So we can go from $t=a$ to $t=a+2$ at $[x+1]$.
+We can also move until we get to $[-3]$, then go $[-3] \rightarrow[x-1]$ to end up with $t=-4$ at $[x-1]$. But going $[x-1] \rightarrow[3 x] \rightarrow[x-1]$ means we can go from $t=a$ to $t=3 a-1$ at $x-1$. Since we can start with $t=-4$, this means we can therefore get arbitrarily small even and odd numbers at $[x-1]$, hence also $[3 x]$, hence also at $[x+1]$.
+This implies we can get any value of $t$ we want at $[x+1]$, so we can also get any value of $t$ we want at $[-x],[x-1],[-x-2],[x-3]$, etc., as well as $[-x+2],[x+3],[-x+4],[x+5]$, etc. We can do a similar thing starting at $[-x+1]$ to get from $t=a$ to $t=a+2$, and use the $[-x-1] \rightarrow[-3 x] \rightarrow[-x-1]$ loop to get arbitrarily small integers of both parities. So we can get any value of $t$ we want at all points of the form $[ \pm x+k]$ for any integer $k$.
+9. [30] Let $p(x)=a_{n} x^{n}+a_{n-1} x^{n-1}+\ldots+a_{0}$ be a polynomial with complex coefficients such that $a_{i} \neq 0$ for all $i$. Prove that $|r| \leq 2 \max _{i=0}^{n-1}\left|\frac{a_{i-1}}{a_{i}}\right|$ for all roots $r$ of all such polynomials $p$. Here we let $|z|$ denote the absolute value of the complex number $z$.
+Solution: If $r$ is a root, then $-a_{n} r^{n}=a_{n-1} r^{n-1}+\ldots+a_{0}$. By the Triangle Inequality, $\left|-a_{n} r^{n}\right| \leq$ $\left|a_{n-1} r^{n-1}\right|+\ldots+\left|a_{0}\right|$. Rearranging this inequality yields $\left|a_{n} r^{n}\right|-\left|a_{n-1} r^{n-1}\right|-\ldots-\left|a_{0}\right| \leq 0$.
+Now suppose $|r|=k \max \left|\frac{a_{i-1}}{a_{i}}\right|$. Applying this over values of $i$ ranging from $m+1$ to $n$ (assuming $m+1 \leq n$ ), we get $\left|a_{m} r^{m}\right| \leq \frac{\left|a_{n} r^{n}\right|}{k^{n-m}}$. This, along with the above equation, yields:
+
+$$
+\left|a_{n} r^{n}\right| \cdot\left(1-\frac{1}{k}-\frac{1}{k^{2}}-\frac{1}{k^{3}}-\ldots-\frac{1}{k^{n}}\right)=0
+$$
+
+This is only true when $a_{n}=0, r=0$, or $\left(1-\frac{1}{k}-\frac{1}{k^{2}}-\ldots\right)=0$. The first option is impossible by the constraints in the problem. The second option implies $k=0$. The third option implies that $k<2$; otherwise ( $1-\frac{1}{k}-\frac{1}{k^{2}}-\ldots-\frac{1}{k^{n}}$ ) would always remain positive. Either way, $|r| \leq 2 \max _{i=0}^{n-1}\left|\frac{a_{i-1}}{a_{i}}\right|$.
+10. Call an $2 n$-digit base-10 number special if we can split its digits into two sets of size $n$ such that the sum of the numbers in the two sets is the same. Let $p_{n}$ be the probability that a randomly-chosen $2 n$-digit number is special. (We allow leading zeros in $2 n$-digit numbers).
+(a) [20] The sequence $p_{n}$ converges to a constant $c$. Find $c$.
+
+Answer: $\frac{1}{2}$ We first claim that if a $2 n$-digit number $x$ has at least eight 0 's and at least eight 1's and the sum of its digits is even, then $x$ is special.
+Let $A$ be a set of eight 0 's and eight 1's and let $B$ be the set of all the other digits. We split $b$ arbitrily into two sets $Y$ and $Z$ of equal size. If $\left|\sum_{y \in Y} y-\sum_{z \in Z} z\right|>8$, then we swap the biggest element of the set with the bigger sum with the smallest element of the other set. This transposition always decreases the absolute value of the sum: in the worst case, a 9 from the bigger set is swapped for a 0 from the smaller set, which changes the difference by at most 18 . Therefore, after a finite number of steps, we will have $\left|\sum_{y \in Y} y-\sum_{z \in Z} z\right| \leq 8$.
+Note that this absolute value is even, since the sum of all the digits is even. Without loss of generality, suppose that $\sum_{y \in Y} y-\sum_{z \in Z} z$ is $2 k$, where $0 \leq k \leq 4$. If we add $k 0$ 's and $8-k$ 's to $Y$, and we add the other elements of $A$ to $Z$, then the two sets will balance, so $x$ is special.
+(b) [45] Let $q_{n}=p_{n}-c$. There exists a unique positive constant $r$ such that $\frac{q_{n}}{r^{n}}$ converges to a constant $d$. Find $r$ and $d$.
+Answer: $r=\frac{1}{4}, d=-1$ To get the next asymptotic term after the constant term of $\frac{1}{2}$, we need to consider what happens when the digit sum is even; we want to find the probability that such a number isn't balanced. We claim that the configuration that contributes the vast majority of unbalanced numbers is when all numbers are even and the sum is $2 \bmod 4$, or such a configuration with all numbers increased by 1. Clearly this gives $q_{n}$ being asymptotic to $-\frac{1}{2} \cdot 2 \cdot\left(\frac{1}{2}\right)^{2 n}=-\left(\frac{1}{4}\right)^{n}$, so $r=\frac{1}{4}$ and $d=-1$.
+To prove the claim, first note that the asymptotic probability that there are at most 4 digits that occur more than 10 times is asymptotically much smaller than $\left(\frac{1}{2}\right)^{n}$, so we can assume that there exist 5 digits that each occur at least 10 times. If any of those digits are consecutive, then the digit sum being even implies that the number is balanced (by an argument similar to part (a)).
+So, we can assume that none of the numbers are consecutive. We would like to say that this implies that the numbers are either $0,2,4,6,8$ or $1,3,5,7,9$. However, we can't quite say this yet, as we need to rule out possibilities like $0,2,4,7,9$. In this case, though, we can just pair 0 and 7 up with 2 and 4 ; by using the same argument as in part (a), except using 0 and 7 both (to get a sum of 7 ) and 2 and 4 both (to get a sum of 6 ) to balance out the two sets at the end.
+In general, if there is ever a gap of size 3 , consider the number right after it and the 3 numbers before it (so we have $k-4, k-2, k, k+3$ for some $k$ ), and pair them up such that one pair has a sum that's exactly one more than the other (i.e. pair $k-4$ with $k+3$ and $k-2$ with $k$ ). Since we again have pairs of numbers whose sums differ by 1 , we can use the technique from part (a) of balancing out the sets at the end.
+So, we can assume there is no gap of size 3 , which together with the condition that no two numbers are adjacent implies that the 5 digits are either $0,2,4,6,8$ or $1,3,5,7,9$. For the remainder of the solution, we will deal with the $0,2,4,6,8$ case, since it is symmetric with the other case under the transformation $x \mapsto 9-x$.
+If we can distribute the odd digits into two sets $S_{1}$ and $S_{2}$ such that (i) the differense in sums of $S_{1}$ and $S_{2}$ is small; and (ii) the difference in sums of $S_{1}$ and $S_{2}$, plus the sum of the even digits, is divisible by 4 , then the same argument as in part (a) implies that the number is good.
+
+In fact, if there are any odd digits, then we can use them at the beginning to fix the parity mod 4 (by adding them all in such that the sums of the two sets remain close, and then potentially switching one with an even digit). Therefore, if there are any odd digits then the number is good.
+Also, even if there are no odd digits, if the sum of the digits is divisible by 4 then the number is good.
+So, we have shown that almost all non-good numbers come from having all numbers being even with a digit sum that is $2 \bmod 4$, or the analogous case under the mapping $x \mapsto 9-x$. This formalizes the claim we made in the first paragraph, so $r=\frac{1}{4}$ and $d=-1$, as claimed.
+
diff --git a/HarvardMIT/md/en-132-2010-feb-team2-solutions.md b/HarvardMIT/md/en-132-2010-feb-team2-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..c2f2bbdf68e524305bbbd1633ab07a96d99802ed
--- /dev/null
+++ b/HarvardMIT/md/en-132-2010-feb-team2-solutions.md
@@ -0,0 +1,95 @@
+## $13^{\text {th }}$ Annual Harvard-MIT Mathematics Tournament
Saturday 20 February 2010
Team Round B
+
+1. [10] How many ways are there to place pawns on an $8 \times 8$ chessboard, so that there is at most 1 pawn in each horizontal row? Express your answer in the form $p_{1}^{e_{1}} \cdot p_{2}^{e_{2}} \cdots$, where the $p_{i}$ are distinct primes and the $e_{i}$ are positive integers.
+Answer: $3^{16}$ If there is at most 1 pawn in each row, then each row of the chessboard may have either 0 or 1 pawn somewhere in the row. There is 1 case if there are no pawns in the row. There are 8 possible cases if there is 1 pawn in the row, one case for each square in the row. Hence for each row, there are 9 possible pawn arrangements. There are 8 rows, thus we have $9^{8}=3^{16}$.
+2. [10] In the following figure, a regular hexagon of side length 1 is attached to a semicircle of diameter 1. What is the longest distance between any two points in the figure?
+
+
+Answer: $\frac{1+\sqrt{13}}{2}$ Inspection shows that one point must be on the semicircle and the other must be on the side of the hexagon directly opposite the edge with the semicircle, the bottom edge of the hexagon in the above diagram. Let $O$ be the center of the semicircle and let $M$ be the midpoint of the bottom edge.
+We will determine the longest distance between points in the figure by comparing the lengths of all the segments with one endpoint on the bottom edge and the other endpoint on the semicircle. Fix a point $A$ on the bottom edge of the hexagon. Suppose that $B$ is chosen on the semicircle such that $A B$ is as long as possible. Let $C$ be the circle centered at $A$ with radius $A B$. If $C$ is not tangent to the semicircle, then part of the semicircle is outside $C$, so we could pick a $B^{\prime}$ on the semicircle such that $A B^{\prime}$ is longer than $A B$. So $C$ must be tangent to the semicircle, and $A B$ must pass through $O$.
+Then $O B$ is always $\frac{1}{2}$, no matter which $A$ we choose on the bottom edge. All that remains is maximizing $A O$. This length is the hypotenuse of a right triangle with the fixed height $M O$, so it is maximized when $A M$ is as large as possible - when $A$ is an endpoint of the bottom edge. Note that $M O=2 \cdot \frac{\sqrt{3}}{2}$, and that $A M$ can be at most $\frac{1}{2}$, so $A O$ can be at most $\frac{\sqrt{13}}{2}$. So the maximum distance between two points in the diagram is $A O+O B=\frac{1+\sqrt{13}}{2}$.
+3. [15] Let $p(x)=a_{n} x^{n}+a_{n-1} x^{n-1}+\ldots+a_{0}$, where each $a_{i}$ is either 1 or -1 . Let $r$ be a root of $p$. If $|r|>\frac{15}{8}$, what is the minimum possible value of $n$ ?
+Answer: 4 We claim that $n=4$ is the answer. First, we show that $n>3$. Suppose that $n \leq 3$. Let $r$ be the root of the polynomial with $|r| \geq \frac{15}{8}$. Then, by the Triangle Inequality, we have:
+
+$$
+\begin{gathered}
+\left|a_{n} r^{n}\right|=\left|a_{n-1} r^{n-1}+a_{n-2} r^{n-2}+\ldots+a_{0}\right| \leq\left|a_{n-1} r^{n-1}\right|+\left|a_{n-2} r^{n-2}\right|+\ldots+\left|a_{0}\right| \\
+|r|^{n} \leq\left|r^{n-1}\right|+\left|r^{n-2}\right|+\ldots+|1|=\frac{|r|^{n}-1}{|r|-1} \\
+|r|^{n+1}-2|r|^{n}+1 \leq 0 \Rightarrow 1 \leq|r|^{n}(2-|r|)
+\end{gathered}
+$$
+
+The right-hand side is increasing in $n$, for $|r|>1$, so it is bounded by $|r|^{3}(2-|r|)$. This expression is decreasing in $r$ for $r \geq \frac{3}{2}$. When $|r|=\frac{15}{8}$, then the right-hand side is less than 1 , which violates the inequalities. Therefore $n>3$. Now, we claim that there is a 4 th degree polynomial with a root $r$ with $|r| \geq \frac{15}{8}$. Let $p(x)=x^{4}-x^{3}-x^{2}-x-1$. Then $p\left(\frac{15}{8}\right)<0$ and $p(2)>2$. By the Intermediate Value Theorem, $p(x)$ has such a root $r$.
+4. [20] Find all 4-digit integers of the form $a a b b$ (when written in base 10) that are perfect squares.
+
+Answer: 7744 Let $x$ be an integer such that $x^{2}$ is of the desired form. Then $1100 a+11 b=x^{2}$. Then $x^{2}$ is divisible by 11 , which means $x$ is divisible by 11 . Then for some integer, $y, x=11 y$. Then $1100 a+11 b=11^{2} y^{2} \Rightarrow 100 a+b=11 y^{2}$. This means that $100 a+b \equiv 0(\bmod 11) \Rightarrow a+b \equiv 0(\bmod 11)$. Because $a$ and $b$ must be nonzero digits, we have $2 \leq a, b \leq 9$, so we can write $b=11-a$.
+Replacing $b$ in the equation derived above, we obtain $99 a+11=11 y^{2} \Rightarrow 9 a+1=y^{2}$. We check the possible values of $a$ from 2 to 9 , and only $a=7$ yields a perfect square. When $a=7, b=4$, so the only perfect square of for $a a b b$ is 7744 .
+5. [25] Compute
+
+$$
+\sum_{n=1}^{98} \frac{2}{\sqrt{n}+\sqrt{n+2}}+\frac{1}{\sqrt{n+1}+\sqrt{n+2}}
+$$
+
+Answer: $\quad 3 \sqrt{11}-2 \sqrt{2}+19$ Rationalizing the denominator of both terms in the summation yields $\sqrt{n+2}-\sqrt{n}+\sqrt{n+2}-\sqrt{n+1}=2 \sqrt{n+2}-(\sqrt{n}+\sqrt{n+1})$. Then the sum $\sum_{n=1}^{98} 2 \sqrt{n+2}-(\sqrt{n}+\sqrt{n+1})$ telescopes. All terms cancel except for $-(\sqrt{1}+\sqrt{2})-\sqrt{2}+2 \sqrt{99}+2 \sqrt{100}-\sqrt{99}=3 \sqrt{11}-2 \sqrt{2}+19$.
+6. [25] Into how many regions can a circle be cut by 10 parabolas?
+
+Answer: 201 We will consider the general case of $n$ parabolas, for which the answer is $2 n^{2}+1$.
+We will start with some rough intuition, then fill in the details afterwards. The intuition is that, if we make the parabolas steep enough, we can basically treat them as two parallel lines. Furthermore, the number of regions is given in terms of the number of intersections of the parabolas that occur within the circle, since every time two parabolas cross a new region is created. Since two pairs of parallel lines intersect in 4 points, and pairs of parabolas also intersect in 4 points, as long as we can always make all 4 points of intersection lie inside the circle, the parallel lines case is the best we can do.
+In other words, the answer is the same as the answer if we were trying to add ten pairs of parallel lines. We can compute the answer for pairs of parallel lines as follows - when we add the $k$ th set of parallel lines, there are already $2 k-2$ lines that the two new lines can intersect, meaning that each of the lines adds $2 k-1$ new regions ${ }^{1}$. This means that we add $4 k-2$ regions when adding the $k$ th set of lines, making the answer $1+2+6+10+14+\cdots+(4 n-2)=1+2(1+3+5+7+\cdots+(2 n-1))=1+2 \cdot n^{2}=2 n^{2}+1$.
+Now that we have sketched out the solution, we will fill in the details more rigorously. First, if there are $n$ parabolas inside the circle, and the they intersect in $K$ points total, then we claim that the number of regions the circle is divided into will be at most $K+n+r+1$, where $r$ is the number of parabolas that intersect the circle itself in exactly four points.
+We will prove this by induction. In the base case of $n=0$, we are just saying that the circle itself consists of exactly one region.
+To prove the inductive step, suppose that we have $n$ parabolas with $K$ points of intersection. We want to show that if we add an additional parabola, and this parabola intersects the other parabolas in $p$ points, then this new parabola adds either $p+1$ or $p+2$ regions to the circle, and that we get $p+2$ regions if and only if the parabola intersects the circle in exactly four points.
+We will do this by considering how many regions the parabola cuts through, following its path from when it initially enters the circle to when it exits the circle for the last time. When it initially enters the circle, it cuts through one region, thereby increasing the number of regions by on ${ }^{2}$. Then, for each other parabola that this parabola crosses, we cut through one additional region. It is also possible for the parabola to leave and then re-enter the circle, which happens if and only if the parabola intersects
+
+[^0]the circle in four points, and also adds one additional region. Therefore, the number of regions is either $p+1$ or $p+2$, and it is $p+2$ if and only if the parabola intersects the circle in four points. This completes the induction and proves the claim.
+So, we are left with trying to maximize $K+n+r+1$. Since a pair of parabolas intersects in at most 4 points, and there are $\binom{n}{2}$ pairs of parabolas, we have $K \leq 4\binom{n}{2}=2 n^{2}-2 n$. Also, $r \leq n$, so $K+n+r+1 \leq 2 n^{2}+1$. On the other hand, as explained in the paragraphs giving the intuition, we can attain $2 n^{2}+1$ by making the parabolas sufficiently steep that they act like pairs of parallel lines. Therefore, the answer is $2 n^{2}+1$, as claimed.
+7. [30] Evaluate
+$$
+\sum_{k=1}^{2010} \cos ^{2}(k)
+$$
+
+Answer: $1005+\frac{\sin (4021)-\sin (1)}{4 \sin (1)}$ We use the identity $\cos ^{2}(k)=\frac{1+\cos (2 x)}{2}$. Then our expression evalutes to $1005+\frac{(\cos (2)+\ldots+\cos (4020))}{2}$.
+To evaluate $\cos (2)+\cdots+\cos (4020)$, let $y=\cos (2)+\cdots+\cos (4020) \Rightarrow y(\sin (1))=\cos (2) \sin (1)+$ $\ldots+\cos (4020) \sin (1)$. Observe that for any $x, \cos (x) \sin (1)=\frac{\sin (x+1)-\sin (x-1)}{2}$. Then $y(\sin (1))=$ $\frac{\sin (3)-\sin (1)}{2}+\frac{\sin (5)-\sin (3)}{2}+\ldots+\frac{\sin 4021-\sin (4019)}{2}$. This is clearly a telescoping sum; we get $y(\sin (1))=$ $\frac{\sin (4021)-\sin (1)}{2}$. Then we have the desired $y=\frac{\sin (4021)-\sin (1)}{2 \sin (1)}$. Then our original expression evaluates to $1005+\frac{\sin (4021)-\sin (1)}{4 \sin (1)}$.
+8. [30] Consider the following two-player game. Player 1 starts with a number, $N$. He then subtracts a proper divisor of $N$ from $N$ and gives the result to player 2 (a proper divisor of $N$ is a positive divisor of $N$ that is not equal to 1 or $N)$. Player 2 does the same thing with the number she gets from player 1 , and gives the result back to player 1. The two players continue until a player is given a prime number, at which point that player loses. For how many values of $N$ between 2 and 100 inclusive does player 1 have a winning strategy?
+Answer: 47 We claim that player 1 has a winning strategy if and only if $N$ is even and not an odd power of 2 .
+First we show that if you are stuck with an odd number, then you are guaranteed to lose. Suppose you have an odd number $a b$, where $a$ and $b$ are odd numbers, and you choose to subtract $a$. You pass your opponent the number $a(b-1)$. This cannot be a power of 2 (otherwise $a$ is a power of 2 and hence $a=1$, which is not allowed), so your opponent can find an odd proper divisor of $a(b-1)$ (such as $a$ ), and you will have a smaller odd number. Eventually you will get to an odd prime and lose.
+Now consider even numbers that aren't powers of 2. As with before, you can find an odd proper divisor of $N$ and pass your opponent an odd number, so you are guaranteed to win.
+Finally consider powers of 2 . If you have the number $N=2^{k}$, it would be unwise to choose a proper divisor other than $2^{k-1}$; otherwise you would give your opponent an even number that isn't a power of 2 . Therefore if $k$ is odd, you will end up with 2 and lose. If $k$ is even, though, your opponent will end up with 2 and you will win.
+Therefore player 1 has a winning strategy for all even numbers except for odd powers of 2 .
+9. [35] Let $S$ be the set of ordered pairs of integers $(x, y)$ with $1 \leq x \leq 5$ and $1 \leq y \leq 3$. How many subsets $R$ of $S$ have the property that all the points of $R$ lie on the graph of a single cubic? A cubic is a polynomial of the form $y=a x^{3}+b x^{2}+c x+d$, where $a, b, c$, and $d$ are real numbers (meaning that $a$ is allowed to be 0 ).
+Answer: 796 We observe that $R$ must contain at most 1 point from each column of $S$, because no function can contain more than 1 point with the same $x$-coordinate. Therefore, $|R| \leq 5(|R|$ denotes the number of elements of $R$ ). Note that 4 points determine a cubic, so if $R$ is any subset of points in distinct columns and $|R| \leq 4$, then $R$ has the desired property. There are $4^{5}$ ways to choose at most 1
+point from each column and $3^{5}$ ways to choose exactly 1 point from each column. There are therefore $4^{5}-3^{5}=781$ subsets $R$ of $S$ such that $|R| \leq 4$ and all points of $R$ lie in distinct columns. As noted, these sets all automatically have the desired property.
+Now we consider all sets $R$ of size 5 . As before, each point in $R$ must come from a different column. Let us shift our origin to $(3,2)$, and let $p$ be the polynomial containing all 5 points of $R$. Then $R=\{(-2, p(-2)),(-1, p(-1)),(0, p(0)),(1, p(1)),(2, p(2))\}$.
+By the method of finite differences $3^{3}$ or alternately by Lagrange Interpolation there is a unique polynomial $p$ of degree less than 5 going through 5 specified points, and this polynomial is of degree less than 4 if and only if $p(-2)-4 p(-1)+6 p(0)-4 p(1)+p(2)=0$.
+Then $p(-2)+p(2)+6 p(0)=4(p(-1)+p(1))$, where $p(-2)+p(2) \in\{-2-1,0,1,2\}, p(-1)+p(1) \in$ $\{-2,-1,0,1,2\}$, and $p(0) \in\{-1,0,1\}$. We know that $6 p(0)$ and $4(p(-1)+p(1))$ are necessarily even, thus we must have $p(-2)+p(2) \in\{-2,0,2\}$ in order for the equation to be satisfied.
+Let $(a, b, c)=(p(-2)+p(2), 6 p(0), 4(p(-1)+p(1)))$. The possible values of $(a, b, c)$ that are solutions to $a+b=c$ are then $\{(-2,-6,-8),(-2,6,4),(0,0,0),(2,-6,-4),(2,6,8)\}$.
+If $(a, b, c)=(-2,-6,-8)$, then we need $p(-2)+p(2)=-2, p(0)=-1, p(-1)+p(1)=-2$. There is only 1 possible solution to each of these equations: $(p(-2), p(2))=(-1,-1)$ for the first one, $p(0)=-1$ for the second, and $(p(1))=(-1,-1)$ for the third. Hence there is 1 possible subset $R$ for the case $(a, b, c)=(-2,-6,-8)$.
+If $(a, b, c)=(-2,6,4)$, then there is again 1 possible solution to $p(-2)+p(2)=1$. There are two solutions to $p(-1)+p(1)=1:(p(-1), p(1))=(0,1),(1,0)$. Also, $p(0)$ can only be 1 , so there are 2 possible subsets for this case.
+If $(a, b, c)=(0,0,0)$, then there there are 3 possible solutions to $p(-2)+p(2)=0:(p(-2), p(2))=$ $(-1,1),(0,0),(1,-1)$. Similarly, there are 3 possible solutions to $p(-1)+p(1)=0$. Also, $p(0)$ can only be 0 , so there are 9 possible subsets for this case.
+If $(a, b, c)=(2,-6,-4)$, then there is 1 possible solution to $p(-2)+p(2)=2:(p(-2), p(2))=(1,1)$. There are 2 possible solutions to $p(-1)+p(1)=-1:(p(-1), p(1))=(0,-1),(-1,0)$. Also, $p(0)$ can only be -1 , so there are 2 possible subsets for this case.
+If $(a, b, c)=(2,6,8)$, then there is 1 possible solution to $p(-2)+p(2)=2$, as shown above. There is 1 solution to $p(-1)+p(1)=2:(p(-1), p(1))=(1,1)$. Also, $p(0)$ can only be 1 , so there is 1 possible subset for this case.
+Then there are $1+2+9+2+1=15$ total possible subsets of size 5 that can be fit to a polynomial of degree less than 4 . Hence there are $781+15=796$ possible subsets total.
+10. Call an $2 n$-digit number special if we can split its digits into two sets of size $n$ such that the sum of the numbers in the two sets is the same. Let $p_{n}$ be the probability that a randomly-chosen $2 n$-digit number is special (we will allow leading zeros in the number).
+(a) [25] The sequence $p_{n}$ converges to a constant $c$. Find $c$.
+
+Answer: $\frac{1}{2}$ We first claim that if a $2 n$-digit number $x$ has at least eight 0 's and at least eight 1's and the sum of its digits is even, then $x$ is special.
+Let $A$ be a set of eight 0 's and eight 1 's and let $B$ be the set of all the other digits. We split $b$ arbitrily into two sets $Y$ and $Z$ of equal size. If $\left|\sum_{y \in Y} y-\sum_{z \in Z} z\right|>8$, then we swap the biggest element of the set with the bigger sum with the smallest element of the other set. This transposition always decreases the absolute value of the sum: in the worst case, a 9 from the bigger set is swapped for a 0 from the smaller set, which changes the difference by at most 18 . Therefore, after a finite number of steps, we will have $\left|\sum_{y \in Y} y-\sum_{z \in Z} z\right| \leq 8$.
+Note that this absolute value is even, since the sum of all the digits is even. Without loss of generality, suppose that $\sum_{y \in Y} y-\sum_{z \in Z} z$ is $2 k$, where $0 \leq k \leq 4$. If we add $k 0$ 's and $8-k$ 's to $Y$, and we add the other elements of $A$ to $Z$, then the two sets will balance, so $x$ is special.
+
+[^1](b) $[\mathbf{3 0}]$ Let $q_{n}=p_{n}-c$. There exists a unique positive constant $r$ such that $\frac{q_{n}}{r^{n}}$ converges to a constant $d$. Find $r$ and $d$.
+Answer: $\left(\frac{1}{4},-1\right)$ To get the next asymptotic term after the constant term of $\frac{1}{2}$, we need to consider what happens when the digit sum is even; we want to find the probability that such a number isn't balanced. We claim that the configuration that contributes the vast majority of unbalanced numbers is when all numbers are even and the sum is $2 \bmod 4$, or such a configuration with all numbers increased by 1. Clearly this gives $q_{n}$ being asymptotic to $-\frac{1}{2} \cdot 2 \cdot\left(\frac{1}{2}\right)^{2 n}=-\left(\frac{1}{4}\right)^{n}$, so $r=\frac{1}{4}$ and $d=-1$.
+To prove the claim, first note that the asymptotic probability that there are at most 4 digits that occur more than 10 times is asymptotically much smaller than $\left(\frac{1}{2}\right)^{n}$, so we can assume that there exist 5 digits that each occur at least 10 times. If any of those digits are consecutive, then the digit sum being even implies that the number is balanced (by an argument similar to part (a)).
+So, we can assume that none of the numbers are consecutive. We would like to say that this implies that the numbers are either $0,2,4,6,8$ or $1,3,5,7,9$. However, we can't quite say this yet, as we need to rule out possibilities like $0,2,4,7,9$. In this case, though, we can just pair 0 and 7 up with 2 and 4 ; by using the same argument as in part (a), except using 0 and 7 both (to get a sum of 7 ) and 2 and 4 both (to get a sum of 6 ) to balance out the two sets at the end.
+In general, if there is ever a gap of size 3 , consider the number right after it and the 3 numbers before it (so we have $k-4, k-2, k, k+3$ for some $k$ ), and pair them up such that one pair has a sum that's exactly one more than the other (i.e. pair $k-4$ with $k+3$ and $k-2$ with $k$ ). Since we again have pairs of numbers whose sums differ by 1 , we can use the technique from part (a) of balancing out the sets at the end.
+So, we can assume there is no gap of size 3 , which together with the condition that no two numbers are adjacent implies that the 5 digits are either $0,2,4,6,8$ or $1,3,5,7,9$. For the remainder of the solution, we will deal with the $0,2,4,6,8$ case, since it is symmetric with the other case under the transformation $x \mapsto 9-x$.
+If we can distribute the odd digits into two sets $S_{1}$ and $S_{2}$ such that (i) the differense in sums of $S_{1}$ and $S_{2}$ is small; and (ii) the difference in sums of $S_{1}$ and $S_{2}$, plus the sum of the even digits, is divisible by 4 , then the same argument as in part (a) implies that the number is good.
+In fact, if there are any odd digits, then we can use them at the beginning to fix the parity mod 4 (by adding them all in such that the sums of the two sets remain close, and then potentially switching one with an even digit). Therefore, if there are any odd digits then the number is good. Also, even if there are no odd digits, if the sum of the digits is divisible by 4 then the number is good.
+So, we have shown that almost all non-good numbers come from having all numbers being even with a digit sum that is $2 \bmod 4$, or the analogous case under the mapping $x \mapsto 9-x$. This formalizes the claim we made in the first paragraph, so $r=\frac{1}{4}$ and $d=-1$, as claimed.
+
+
+[^0]: ${ }^{1}$ This is the maximum possible number of new regions, but it's not too hard to see that this is always attainable.
+ ${ }^{2}$ While the fact that a curve going through a region splits it into two new regions is intuitively obvious, it is actually very difficult to prove. The proof relies on some deep results from algebraic topology and is known as the Jordan Curve Theorem. If you are interested in learning more about this, see http://en.wikipedia.org/wiki/Jordan_curve_theorem
+
+[^1]: ${ }^{3}$ See http://www.artofproblemsolving.com/Forum/weblog_entry.php?p=1263378
+ ${ }^{4}$ See http://en.wikipedia.org/wiki/Lagrange_polynomial
+
diff --git a/HarvardMIT/md/en-141-2010-nov-gen1-solutions.md b/HarvardMIT/md/en-141-2010-nov-gen1-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..b9e92c41987f18ace66a3aeae0d9db6836e47225
--- /dev/null
+++ b/HarvardMIT/md/en-141-2010-nov-gen1-solutions.md
@@ -0,0 +1,91 @@
+# $3{ }^{\text {rd }}$ Annual Harvard-MIT November Tournament
Sunday 7 November 2010
+
+## General Test
+
+1. [2] Jacob flips five coins, exactly three of which land heads. What is the probability that the first two are both heads?
+Answer: $\frac{3}{10}$ We can associate with each sequence of coin flips a unique word where $H$ represents heads, and T represents tails. For example, the word HHTTH would correspond to the coin flip sequence where the first two flips were heads, the next two were tails, and the last was heads. We are given that exactly three of the five coin flips came up heads, so our word must be some rearrangement of HHHTT. To calculate the total number of possibilities, any rearrangement corresponds to a choice of three spots to place the H flips, so there are $\binom{5}{3}=10$ possibilities. If the first two flips are both heads, then we can only rearrange the last three HTT flips, which corresponds to choosing one spot for the remaining $H$. This can be done in $\binom{3}{1}=3$ ways. Finally, the probability is the quotient of these two, so we get the answer of $\frac{3}{10}$. Alternatively, since the total number of possiblities is small, we can write out all rearrangements: HHHTT, HHTHT, HHTTH, HTHHT, HTHTH, HTTHH, THHHT, THHTH, THTHH, TTHHH. Of these ten, only in the first three do we flip heads the first two times, so we get the same answer of $\frac{3}{10}$.
+2. [3] How many sequences $a_{1}, a_{2}, \ldots, a_{8}$ of zeroes and ones have $a_{1} a_{2}+a_{2} a_{3}+\cdots+a_{7} a_{8}=5$ ?
+
+Answer: 9 First, note that we have seven terms in the left hand side, and each term can be either 0 or 1 , so we must have five terms equal to 1 and two terms equal to 0 . Thus, for $n \in\{1,2, \ldots, 8\}$, at least one of the $a_{n}$ must be equal to 0 . If we can find $i, j \in\{2,3, \ldots, 7\}$ such that $a_{i}=a_{j}=0$ and $i
Sunday 7 November 2010
+
+## Guts Round
+
+1. [5] David, Delong, and Justin each showed up to a problem writing session at a random time during the session. If David arrived before Delong, what is the probability that he also arrived before Justin?
+Answer: $\sqrt[2]{3}$ Let $t_{1}$ be the time that David arrives, let $t_{2}$ be the time that Delong arrives, and let $t_{3}$ be the time that Justin arrives. We can assume that all times are pairwise distinct because the probability of any two being equal is zero. Because the times were originally random and independent before we were given any information, then all orders $t_{1}
Saturday 12 February 2011
Algebra \& Calculus Individual Test
+
+1. Let $a, b$, and $c$ be positive real numbers. Determine the largest total number of real roots that the following three polynomials may have among them: $a x^{2}+b x+c, b x^{2}+c x+a$, and $c x^{2}+a x+b$.
+Answer: 4 If all the polynomials had real roots, their discriminants would all be nonnegative: $a^{2} \geq$ $4 b c, b^{2} \geq 4 c a$, and $c^{2} \geq 4 a b$. Multiplying these inequalities gives $(a b c)^{2} \geq 64(a b c)^{2}$, a contradiction. Hence one of the quadratics has no real roots. The maximum of 4 real roots is attainable: for example, the values $(a, b, c)=(1,5,6)$ give $-2,-3$ as roots to $x^{2}+5 x+6$ and $-1,-\frac{1}{5}$ as roots to $5 x^{2}+6 x+1$.
+2. Josh takes a walk on a rectangular grid of $n$ rows and 3 columns, starting from the bottom left corner. At each step, he can either move one square to the right or simultaneously move one square to the left and one square up. In how many ways can he reach the center square of the topmost row?
+Answer: $2^{n-1}$ Note that Josh must pass through the center square of each row. There are 2 ways to get from the center square of row $k$ to the center square of row $k+1$. So there are $2^{n-1}$ ways to get to the center square of row $n$.
+3. Let $f: \mathbb{R} \rightarrow \mathbb{R}$ be a differentiable function such that $f(0)=0, f(1)=1$, and $\left|f^{\prime}(x)\right| \leq 2$ for all real numbers $x$. If $a$ and $b$ are real numbers such that the set of possible values of $\int_{0}^{1} f(x) d x$ is the open interval $(a, b)$, determine $b-a$.
+Answer: $\boxed{\frac{3}{4}}$ Draw lines of slope $\pm 2$ passing through $(0,0)$ and $(1, 1)$. These form a parallelogram with vertices $(0,0),(.75,1.5),(1,1),(.25,-.5)$. By the mean value theorem, no point of $(x, f(x))$ lies outside this parallelogram, but we can construct functions arbitrarily close to the top or the bottom of the parallelogram while satisfying the condition of the problem. So $(b-a)$ is the area of this parallelogram, which is $\frac{3}{4}$.
+4. Let $A B C$ be a triangle such that $A B=7$, and let the angle bisector of $\angle B A C$ intersect line $B C$ at $D$. If there exist points $E$ and $F$ on sides $A C$ and $B C$, respectively, such that lines $A D$ and $E F$ are parallel and divide triangle $A B C$ into three parts of equal area, determine the number of possible integral values for $B C$.
+Answer: 13
+
+
+Algebra \& Calculus Individual Test
+
+Note that such $E, F$ exist if and only if
+
+$$
+\frac{[A D C]}{[A D B]}=2
+$$
+
+([] denotes area.) Since $A D$ is the angle bisector, and the ratio of areas of triangles with equal height is the ratio of their bases,
+
+$$
+\frac{A C}{A B}=\frac{D C}{D B}=\frac{[A D C]}{[A D B]}
+$$
+
+Hence (1) is equivalent to $A C=2 A B=14$. Then $B C$ can be any length $d$ such that the triangle inequalities are satisfied:
+
+$$
+\begin{aligned}
+d+7 & >14 \\
+7+14 & >d
+\end{aligned}
+$$
+
+Hence $7
Saturday 12 February 2011
+
+## Algebra \& Combinatorics Individual Test
+
+1. Let $a, b$, and $c$ be positive real numbers. Determine the largest total number of real roots that the following three polynomials may have among them: $a x^{2}+b x+c, b x^{2}+c x+a$, and $c x^{2}+a x+b$.
+Answer: 4 If all the polynomials had real roots, their discriminants would all be nonnegative: $a^{2} \geq$ $4 b c, b^{2} \geq 4 c a$, and $c^{2} \geq 4 a b$. Multiplying these inequalities gives $(a b c)^{2} \geq 64(a b c)^{2}$, a contradiction. Hence one of the quadratics has no real roots. The maximum of 4 real roots is attainable: for example, the values $(a, b, c)=(1,5,6)$ give $-2,-3$ as roots to $x^{2}+5 x+6$ and $-1,-\frac{1}{5}$ as roots to $5 x^{2}+6 x+1$.
+2. A classroom has 30 students and 30 desks arranged in 5 rows of 6 . If the class has 15 boys and 15 girls, in how many ways can the students be placed in the chairs such that no boy is sitting in front of, behind, or next to another boy, and no girl is sitting in front of, behind, or next to another girl?
+Answer: $2 \cdot 15!^{2}$ If we color the desks of the class in a checkerboard pattern, we notice that all of one gender must go in the squares colored black, and the other gender must go in the squares colored white. There are 2 ways to pick which gender goes in which color, 15 ! ways to put the boys into desks and 15 ! ways to put the girls into desks. So the number of ways is $2 \cdot 15!^{2}$.
+(There is a little ambiguity in the problem statement as to whether the 15 boys and the 15 girls are distinguishable or not. If they are not distinguishable, the answer is clearly 2. Given the number of contestants who submitted the answer 2, the graders judged that there was enough ambiguity to justify accepting 2 as a correct answer. So both 2 and $2 \cdot 15!^{2}$ were accepted as correct answers.)
+3. Let $A B C$ be a triangle such that $A B=7$, and let the angle bisector of $\angle B A C$ intersect line $B C$ at $D$. If there exist points $E$ and $F$ on sides $A C$ and $B C$, respectively, such that lines $A D$ and $E F$ are parallel and divide triangle $A B C$ into three parts of equal area, determine the number of possible integral values for $B C$.
+Answer: 13
+
+
+Note that such $E, F$ exist if and only if
+
+$$
+\frac{[A D C]}{[A D B]}=2
+$$
+
+([] denotes area.) Since $A D$ is the angle bisector, and the ratio of areas of triangles with equal height is the ratio of their bases,
+
+$$
+\frac{A C}{A B}=\frac{D C}{D B}=\frac{[A D C]}{[A D B]}
+$$
+
+Hence (1) is equivalent to $A C=2 A B=14$. Then $B C$ can be any length $d$ such that the triangle inequalities are satisfied:
+
+$$
+\begin{aligned}
+d+7 & >14 \\
+7+14 & >d
+\end{aligned}
+$$
+
+Hence $7
Calculus \& Combinatorics Individual Test
+
+1. A classroom has 30 students and 30 desks arranged in 5 rows of 6 . If the class has 15 boys and 15 girls, in how many ways can the students be placed in the chairs such that no boy is sitting in front of, behind, or next to another boy, and no girl is sitting in front of, behind, or next to another girl?
+Answer: $2 \cdot 15!^{2}$ If we color the desks of the class in a checkerboard pattern, we notice that all of one gender must go in the squares colored black, and the other gender must go in the squares colored white. There are 2 ways to pick which gender goes in which color, 15 ! ways to put the boys into desks and 15 ! ways to put the girls into desks. So the number of ways is $2 \cdot 15!^{2}$.
+(There is a little ambiguity in the problem statement as to whether the 15 boys and the 15 girls are distinguishable or not. If they are not distinguishable, the answer is clearly 2. Given the number of contestants who submitted the answer 2 , the graders judged that there was enough ambiguity to justify accepting 2 as a correct answer. So both 2 and $2 \cdot 15!^{2}$ were accepted as correct answers.)
+2. Let $a, b$, and $c$ be positive real numbers. Determine the largest total number of real roots that the following three polynomials may have among them: $a x^{2}+b x+c, b x^{2}+c x+a$, and $c x^{2}+a x+b$.
+Answer: 4 If all the polynomials had real roots, their discriminants would all be nonnegative: $a^{2} \geq$ $4 b c, b^{2} \geq 4 c a$, and $c^{2} \geq 4 a b$. Multiplying these inequalities gives $(a b c)^{2} \geq 64(a b c)^{2}$, a contradiction. Hence one of the quadratics has no real roots. The maximum of 4 real roots is attainable: for example, the values $(a, b, c)=(1,5,6)$ give $-2,-3$ as roots to $x^{2}+5 x+6$ and $-1,-\frac{1}{5}$ as roots to $5 x^{2}+6 x+1$.
+3. Let $f: \mathbb{R} \rightarrow \mathbb{R}$ be a differentiable function such that $f(0)=0, f(1)=1$, and $\left|f^{\prime}(x)\right| \leq 2$ for all real numbers $x$. If $a$ and $b$ are real numbers such that the set of possible values of $\int_{0}^{1} f(x) d x$ is the open interval $(a, b)$, determine $b-a$.
+Answer: $\boxed{\frac{3}{4}}$ Draw lines of slope $\pm 2$ passing through $(0,0)$ and $(1, 1)$. These form a parallelogram with vertices $(0,0),(.75,1.5),(1,1),(.25,-.5)$. By the mean value theorem, no point of $(x, f(x))$ lies outside this parallelogram, but we can construct functions arbitrarily close to the top or the bottom of the parallelogram while satisfying the condition of the problem. So $(b-a)$ is the area of this parallelogram, which is $\frac{3}{4}$.
+4. Josh takes a walk on a rectangular grid of $n$ rows and 3 columns, starting from the bottom left corner. At each step, he can either move one square to the right or simultaneously move one square to the left and one square up. In how many ways can he reach the center square of the topmost row?
+Answer: $2^{n-1}$ Note that Josh must pass through the center square of each row. There are 2 ways to get from the center square of row $k$ to the center square of row $k+1$. So there are $2^{n-1}$ ways to get to the center square of row $n$.
+5. Let $A B C$ be a triangle such that $A B=7$, and let the angle bisector of $\angle B A C$ intersect line $B C$ at $D$. If there exist points $E$ and $F$ on sides $A C$ and $B C$, respectively, such that lines $A D$ and $E F$ are parallel and divide triangle $A B C$ into three parts of equal area, determine the number of possible integral values for $B C$.
+Answer: 13
+
+
+Note that such $E, F$ exist if and only if
+
+$$
+\frac{[A D C]}{[A D B]}=2
+$$
+
+([] denotes area.) Since $A D$ is the angle bisector, and the ratio of areas of triangles with equal height is the ratio of their bases,
+
+$$
+\frac{A C}{A B}=\frac{D C}{D B}=\frac{[A D C]}{[A D B]}
+$$
+
+Hence (1) is equivalent to $A C=2 A B=14$. Then $B C$ can be any length $d$ such that the triangle inequalities are satisfied:
+
+$$
+\begin{aligned}
+d+7 & >14 \\
+7+14 & >d
+\end{aligned}
+$$
+
+Hence $7
Saturday 12 February 2011
Combinatorics \& Geometry Individual Test
+
+1. A classroom has 30 students and 30 desks arranged in 5 rows of 6 . If the class has 15 boys and 15 girls, in how many ways can the students be placed in the chairs such that no boy is sitting in front of, behind, or next to another boy, and no girl is sitting in front of, behind, or next to another girl?
+Answer: $2 \cdot 15!^{2}$ If we color the desks of the class in a checkerboard pattern, we notice that all of one gender must go in the squares colored black, and the other gender must go in the squares colored white. There are 2 ways to pick which gender goes in which color, 15 ! ways to put the boys into desks and 15 ! ways to put the girls into desks. So the number of ways is $2 \cdot 15!^{2}$.
+(There is a little ambiguity in the problem statement as to whether the 15 boys and the 15 girls are distinguishable or not. If they are not distinguishable, the answer is clearly 2. Given the number of contestants who submitted the answer 2 , the graders judged that there was enough ambiguity to justify accepting 2 as a correct answer. So both 2 and $2 \cdot 15!^{2}$ were accepted as correct answers.)
+2. Let $A B C$ be a triangle such that $A B=7$, and let the angle bisector of $\angle B A C$ intersect line $B C$ at $D$. If there exist points $E$ and $F$ on sides $A C$ and $B C$, respectively, such that lines $A D$ and $E F$ are parallel and divide triangle $A B C$ into three parts of equal area, determine the number of possible integral values for $B C$.
+Answer: 13
+
+
+Note that such $E, F$ exist if and only if
+
+$$
+\frac{[A D C]}{[A D B]}=2
+$$
+
+([] denotes area.) Since $A D$ is the angle bisector, and the ratio of areas of triangles with equal height is the ratio of their bases,
+
+$$
+\frac{A C}{A B}=\frac{D C}{D B}=\frac{[A D C]}{[A D B]}
+$$
+
+Hence (1) is equivalent to $A C=2 A B=14$. Then $B C$ can be any length $d$ such that the triangle inequalities are satisfied:
+
+$$
+\begin{aligned}
+d+7 & >14 \\
+7+14 & >d
+\end{aligned}
+$$
+
+Hence $7
Saturday 12 February 2011
Guts Round
+
+1. [4] Let $A B C$ be a triangle with area 1. Let points $D$ and $E$ lie on $A B$ and $A C$, respectively, such that $D E$ is parallel to $B C$ and $D E / B C=1 / 3$. If $F$ is the reflection of $A$ across $D E$, find the area of triangle $F B C$.
+Answer: $\frac{1}{3}$
+Let $A F$ intersect $B C$ at $H$. Since $D E / B C=1 / 3$ and $F$ and $A$ are equidistant from $D E$, we have $A F=\frac{2}{3} A H$ and $F H=A H-A F=\frac{1}{3} A H$. Furthermore, since $A F$ is perpendicular to $D E$, we have $A H$ and $F H$ are the altitudes of triangles $A B C$ and $F B C$ respectively. Therefore the area of triangle $F B C$ is $\frac{1}{2} \cdot F H \cdot B C=\frac{1}{2} \cdot \frac{1}{3} \cdot A H \cdot B C=\frac{1}{3}$.
+2. [4] Let $a \star b=\sin a \cos b$ for all real numbers $a$ and $b$. If $x$ and $y$ are real numbers such that $x \star y-y \star x=1$, what is the maximum value of $x \star y+y \star x$ ?
+Answer: 1
+We have $x \star y+y \star x=\sin x \cos y+\cos x \sin y=\sin (x+y) \leq 1$. Equality is achieved when $x=\frac{\pi}{2}$ and $y=0$. Indeed, for these values of $x$ and $y$, we have $x \star y-y \star x=\sin x \cos y-\cos x \sin y=\sin (x-y)=$ $\sin \frac{\pi}{2}=1$.
+3. [4] Evaluate $2011 \times 20122012 \times 201320132013-2013 \times 20112011 \times 201220122012$.
+
+Answer: 0
+Both terms are equal to $2011 \times 2012 \times 2013 \times 1 \times 10001 \times 100010001$.
+4. [4] Let $p$ be the answer to this question. If a point is chosen uniformly at random from the square bounded by $x=0, x=1, y=0$, and $y=1$, what is the probability that at least one of its coordinates is greater than $p$ ?
+Answer: $\frac{\sqrt{5}-1}{2}$
+The probability that a randomly chosen point has both coordinates less than $p$ is $p^{2}$, so the probability that at least one of its coordinates is greater than $p$ is $1-p^{2}$. Since $p$ is the answer to this question, we have $1-p^{2}=p$, and the only solution of $p$ in the interval $[0,1]$ is $\frac{\sqrt{5}-1}{2}$.
+5. [5] Rachelle picks a positive integer $a$ and writes it next to itself to obtain a new positive integer $b$. For instance, if $a=17$, then $b=1717$. To her surprise, she finds that $b$ is a multiple of $a^{2}$. Find the product of all the possible values of $\frac{b}{a^{2}}$.
+Answer: 77
+Suppose $a$ has $k$ digits. Then $b=a\left(10^{k}+1\right)$. Thus $a$ divides $10^{k}+1$. Since $a \geq 10^{k-1}$, we have $\frac{10^{k}+1}{a} \leq 11$. But since none of 2,3 , or 5 divide $10^{k}+1$, the only possibilities are 7 and 11 . These values are obtained when $a=143$ and $a=1$, respectively.
+6. [5] Square $A B C D$ is inscribed in circle $\omega$ with radius 10. Four additional squares are drawn inside $\omega$ but outside $A B C D$ such that the lengths of their diagonals are as large as possible. A sixth square is drawn by connecting the centers of the four aforementioned small squares. Find the area of the sixth square.
+Answer: 144
+Let $D E G F$ denote the small square that shares a side with $A B$, where $D$ and $E$ lie on $A B$. Let $O$ denote the center of $\omega, K$ denote the midpoint of $F G$, and $H$ denote the center of $D E G F$. The area of the sixth square is $2 \cdot O H^{2}$.
+Let $K F=x$. Since $K F^{2}+O K^{2}=O F^{2}$, we have $x^{2}+(2 x+5 \sqrt{2})^{2}=10^{2}$. Solving for $x$, we get $x=\sqrt{2}$. Thus, we have $O H=6 \sqrt{2}$ and $2 \cdot O H^{2}=144$.
+7. [6] For any positive real numbers $a$ and $b$, define $a \circ b=a+b+2 \sqrt{a b}$. Find all positive real numbers $x$ such that $x^{2} \circ 9 x=121$.
+
+## Answer: $\frac{31-3 \sqrt{53}}{2}$
+
+Since $a \circ b=(\sqrt{a}+\sqrt{b})^{2}$, we have $x^{2} \circ 9 x=(x+3 \sqrt{x})^{2}$. Moreover, since $x$ is positive, we have $x+3 \sqrt{x}=11$, and the only possible solution is that $\sqrt{x}=\frac{-3+\sqrt{53}}{2}$, so $x=\frac{31-3 \sqrt{53}}{2}$.
+8. [6] Find the smallest $k$ such that for any arrangement of 3000 checkers in a $2011 \times 2011$ checkerboard, with at most one checker in each square, there exist $k$ rows and $k$ columns for which every checker is contained in at least one of these rows or columns.
+
+Answer: 1006
+If there is a chip in every square along a main diagonal, then we need at least 1006 rows and columns to contain all these chips. We are left to show that 1006 is sufficient.
+
+Take the 1006 rows with greatest number of chips. Assume without loss of generality they are the first 1006 rows. If the remaining 1005 rows contain at most 1005 chips, then we can certainly choose 1006 columns that contain these chips. Otherwise, there exists a row that contains at least 2 chips, so every row in the first 1006 rows must contain at least 2 chips. But this means that there are at least $2 \times 1006+1006=3018$ chips in total. Contradiction.
+9. [6] Segments $A A^{\prime}, B B^{\prime}$, and $C C^{\prime}$, each of length 2, all intersect at a point $O$. If $\angle A O C^{\prime}=\angle B O A^{\prime}=$ $\angle C O B^{\prime}=60^{\circ}$, find the maximum possible value of the sum of the areas of triangles $A O C^{\prime}, B O A^{\prime}$, and $C O B^{\prime}$.
+Answer: $\sqrt{3}$
+Extend $O A$ to $D$ and $O C^{\prime}$ to $E$ such that $A D=O A^{\prime}$ and $C^{\prime} E=O C$. Since $O D=O E=2$ and $\angle D O E=60^{\circ}$, we have $O D E$ is an equilateral triangle. Let $F$ be the point on $D E$ such that $D F=O B$ and $E F=O B^{\prime}$. Clearly we have $\triangle D F A \cong \triangle O B A^{\prime}$ and $\triangle E F C^{\prime} \cong O B^{\prime} C$. Thus the sum of the areas of triangles $A O C^{\prime}, B O A^{\prime}$, and $C O B^{\prime}$ is the same as the sum of the areas of triangle $D F A, F E C^{\prime}$, and $O A C^{\prime}$, which is at most the area of triangle $O D E$. Since $O D E$ is an equilateral triangle with side length 2 , its area is $\sqrt{3}$. Equality is achieved when $O C=O A^{\prime}=0$.
+10. [6] In how many ways can one fill a $4 \times 4$ grid with a 0 or 1 in each square such that the sum of the entries in each row, column, and long diagonal is even?
+Answer: 256
+First we name the elements of the square as follows:
+
+| $a_{11}$ | $a_{12}$ | $a_{13}$ | $a_{14}$ |
+| :--- | :--- | :--- | :--- |
+| $a_{21}$ | $a_{22}$ | $a_{23}$ | $a_{24}$ |
+| $a_{31}$ | $a_{32}$ | $a_{33}$ | $a_{34}$ |
+| $a_{41}$ | $a_{42}$ | $a_{43}$ | $a_{44}$ |
+
+We claim that for any given values of $a_{11}, a_{12}, a_{13}, a_{21}, a_{22}, a_{23}, a_{32}$, and $a_{33}$ (the + signs in the diagram below), there is a unique way to assign values to the rest of the entries such that all necessary sums are even.
+
+$$
+\begin{array}{cccc}
++ & + & + & a_{14} \\
++ & + & + & a_{24} \\
+a_{31} & + & + & a_{34} \\
+a_{41} & a_{42} & a_{43} & a_{44}
+\end{array}
+$$
+
+Taking additions mod 2, we have
+
+$$
+\begin{aligned}
+a_{14} & =a_{11}+a_{12}+a_{13} \\
+a_{24} & =a_{21}+a_{22}+a_{23} \\
+a_{44} & =a_{11}+a_{22}+a_{33} \\
+a_{42} & =a_{12}+a_{22}+a_{32} \\
+a_{43} & =a_{13}+a_{23}+a_{33}
+\end{aligned}
+$$
+
+Since the 4 th column, the 4 th row, and the 1 st column must have entries that sum to 0 , we have
+
+$$
+\begin{aligned}
+& a_{34}=a_{14}+a_{24}+a_{44}=a_{12}+a_{13}+a_{21}+a_{23}+a_{33} \\
+& a_{41}=a_{42}+a_{43}+a_{44}=a_{11}+a_{12}+a_{13}+a_{23}+a_{32} \\
+& a_{31}=a_{11}+a_{21}+a_{41}=a_{12}+a_{13}+a_{21}+a_{23}+a_{32}
+\end{aligned}
+$$
+
+It is easy to check that the sum of entries in every row, column, and the main diagonal is even. Since there are $2^{8}=256$ ways to assign the values to the initial 8 entries, there are exactly 256 ways to fill the board.
+11. [8] Rosencrantz and Guildenstern play a game in which they repeatedly flip a fair coin. Let $a_{1}=4$, $a_{2}=3$, and $a_{n}=a_{n-1}+a_{n-2}$ for all $n \geq 3$. On the $n$th flip, if the coin is heads, Rosencrantz pays Guildenstern $a_{n}$ dollars, and, if the coin is tails, Guildenstern pays Rosencrantz $a_{n}$ dollars. If play continues for 2010 turns, what is the probability that Rosencrantz ends up with more money than he started with?
+Answer: $\frac{1}{2}-\frac{1}{2^{1341}}$
+Since Rosencrantz and Guildenstern have an equal chance of winning each toss, both have the same probability of ending up with a positive amount of money. Let $x$ denote the probability that they both end up with zero dollars. We wish to find $\frac{1-x}{2}$.
+We have $x$ is equal to the probability that
+
+$$
+s_{2010}:=i_{1} a_{1}+i_{2} a_{2}+\cdots i_{2010} a_{2010}=0
+$$
+
+where $i_{n}$ has an equal probability of being either 1 or -1 .
+We claim that $s_{2010}=0$ if and only if $i_{3 n}=-i_{3 n-1}=-i_{3 n-2}$ for all $n \leq 670$. We start with the following lemma.
+Lemma. We have $a_{n}>\sum_{k=1}^{n-3} a_{k}$ for all $n \geq 4$.
+Proof: For the case $n=4, a_{4}=a_{3}+a_{2}=2 a_{2}+a_{1}>a_{1}$. In case $n>4$, we have
+
+$$
+a_{n}=a_{n-2}+a_{n-1}>a_{n-2}+\sum_{k=1}^{n-4} a_{k}=a_{n-4}+\sum_{k=1}^{n-3} a_{k}>\sum_{k=1}^{n-3} a_{k}
+$$
+
+It suffices to show that $s_{3 n}=0$ only if $i_{3 k}=-i_{3 k-1}=-i_{3 k-2}$ for all $k \leq n$. The triangle inequality implies the following:
+
+$$
+\begin{aligned}
+& 0 \leq\left|\left|i_{3 n-2} a_{3 n-2}+s_{3 n-3}\right|-\left|i_{3 n-1} a_{3 n-1}+i_{3 n} a_{3 n}\right|\right| \leq\left|s_{3 n}\right|=0 \\
+& 0 \leq\left|\left|i_{3 n-1} a_{3 n-1}+s_{3 n-3}\right|-\left|i_{3 n-2} a_{3 n-2}+i_{3 n} a_{3 n}\right|\right| \leq\left|s_{3 n}\right|=0
+\end{aligned}
+$$
+
+By the lemma, we have
+
+$$
+\begin{array}{rll}
+a_{3 n-2}+\sum_{k=1}^{3 n-3} a_{k}0$.
+Since $\sum_{i=p}^{q} c_{i} k^{i}=0$, we have
+
+$$
+\left|c_{q} k^{q}\right|=\left|c_{q-1} k^{q-1}+\ldots+c_{p} k^{p}\right| \leq k^{q}+k^{q-1}+\ldots+k^{p+1}<\frac{k}{k-1} k^{q} \leq 2 k^{q}
+$$
+
+so $c_{q}=1$. Now we have
+
+$$
+k^{q}+c_{q-1} k^{q-1}+\ldots+c_{p} k^{p}=0
+$$
+
+This means $\left(k+c_{q-1}\right) k^{q-1}+\ldots+c_{p} k^{p}=0$. Hence, as above,
+
+$$
+\left|\left(k+c_{q-1}\right) k^{q-1}\right|=\left|c_{q-2} k^{q-2}+\ldots+c_{p} k^{p}\right|<2 k^{q-1}
+$$
+
+Therefore, $\left|\left(k+c_{q-1}\right)\right|<2$, which means $c_{q-1}=-k$ or $-k+1$.
+If $c_{q-1}=-k$, then $c_{q} k^{q}+c_{q-1} k^{q-1}=0$, and we get a subsequence $(1,-k)$.
+If $c_{q-1}=-k+1$, then $c_{q} k^{q}+c_{q-1} k^{q-1}=k^{q-1}$. Thus
+
+$$
+k^{q-1}+c_{q-2} k^{q-2}+\ldots+c_{p} k^{p}=0
+$$
+
+which has the exact same form as (1). We can then repeat this procedure to obtain a subsequence $(1,1-k, 1-k, \ldots, 1-k,-k)$.
+Once we have such a subsequence, the terms in the sum $\sum_{i=p}^{q} c_{i} k^{i}=0$ corresponding to that subsequence sum to 0 , so we may remove them and apply the same argument.
+
+We now consider the cases.
+If the base $k$ representation of $n-1$ contains no 0 's, then $a_{i} \neq 0$ so it is impossible to have $c_{i}=a_{i}-b_{i}=$ $-k$. On the other hand, we know that $c_{i}$ is composed of subsequences of the form $\pm(1,1-k, 1-k, \ldots, 1-$ $k,-k)$. Therefore, if $\left\{c_{i}\right\}$ is not the zero sequence, then the fact that $\sum c_{i}=0$ implies that we must have both a subsequence $(1,1-k, 1-k, \ldots, 1-k,-k)$ and a subsequence $-(1,1-k, 1-k, \ldots, 1-k,-k)$, meaning that there exists $i$ for which $c_{i}=-k$, contradiction.
+If the base $k$ representation of $n-1$ contains a 0 , then picking the largest $i$ such that $a_{i}=0$, we can change $a_{i}$ to $k$ and $a_{i+1}$ to $a_{i+1}-1$, and append a $(1,-k)$ to the end of the sequence. This yields another $k$-representation of $n$, so a $k$-representation of $n$ is unique if and only if the base $k$ representation of $n-1$ contains no 0 's, as desired.
+15. [55] Denote $\{1,2, \ldots, n\}$ by $[n]$, and let $S$ be the set of all permutations of [ $n$ ]. Call a subset $T$ of $S$ good if every permutation $\sigma$ in $S$ may be written as $t_{1} t_{2}$ for elements $t_{1}$ and $t_{2}$ of $T$, where the product of two permutations is defined to be their composition. Call a subset of $U$ of $S$ extremely good if every permutation $\sigma$ in $S$ may be written as $s^{-1} u s$ for elements $s$ of $S$ and $u$ of $U$. Let $\tau$ be the smallest value of $|T| /|S|$ for all good subsets $T$, and let $v$ be the smallest value of $|U| /|S|$ for all extremely good subsets $U$. Prove that $\sqrt{v} \geq \tau$.
+Solution: Denote $\{1,2, \ldots, n\}$ by $[n]$, and let $S$ be the set of all permutations of $[n]$. Call a subset $T$ of $S$ good if every permutation $\sigma$ in $S$ may be written as $t_{1} t_{2}$ for elements $t_{1}$ and $t_{2}$ of $T$, where the product of two permutations is defined to be their composition. Call a subset of $U$ of $S$ extremely good if every permutation $\sigma$ in $S$ may be written as $s^{-1} u s$ for elements $s$ of $S$ and $u$ of $U$. Let $\tau$ be
+the smallest value of $|T| /|S|$ for all good subsets $T$, and let $v$ be the smallest value of $|U| /|S|$ for all extremely good subsets $U$. Prove that $\sqrt{v} \geq \tau$.
+Call an element $t \in S$ an involution if and only if $t^{2}$ is the identity permutation. We claim that the set of all involutions in $S$ constitutes a good subset of $S$. The proof is simple. Let $s$ be an arbitrary permutation in $S$. Note that $s$ may be decomposed into a product of disjoint cycles of length at least 2 , and suppose that there are $m$ such cycles in its decomposition. For $1 \leq i \leq m$, let $l_{i}$ denote the length of the $i$ th cycle, so that $s$ may be written as
+
+$$
+\left(a_{1,1} a_{1,2} \ldots a_{1, l_{1}}\right)\left(a_{2,1} a_{2,2} \ldots a_{2, l_{2}}\right) \ldots\left(a_{m, 1} a_{m, 2} \ldots a_{m, l_{m}}\right)
+$$
+
+for some pairwise distinct elements
+
+$$
+a_{1,1}, a_{1,2}, \ldots, a_{1, l_{1}}, a_{2,1}, a_{2,2}, \ldots, a_{2, l_{2}}, \ldots, a_{m, 1}, a_{m, 2}, \ldots, a_{m, l_{m}}
+$$
+
+of $[n]$. Consider the permutations $q$ and $r$ defined by $q\left(a_{i, j}\right)=a_{i, l_{i}+1-j}$ for all $1 \leq j \leq l_{i}$ and $r\left(a_{i, 1}\right)=a_{i, 1}$ and $r\left(a_{i, k}\right)=a_{i, l_{i}+2-k}$ for all $2 \leq k \leq l_{i}$, for all $1 \leq i \leq m$, and by $q(x)=r(x)=x$ for all $x \in[n]$ otherwise. Since $q, r \in S, q^{2}=r^{2}=1$, and $r q=s$, it follows that the set of all involutions in $S$ is indeed good, as desired.
+For all integer partitions $\lambda$ of $n$, let $f^{\lambda}$ denote the number of standard Young tableaux of shape $\lambda$. By the Robinson-Schensted-Knuth correspondence, the permutations of [ $n$ ] are in bijection with pairs of standard Young tableaux of the same shape in such a way that the involutions of $[n]$ are in bijection with pairs of identical standard Young tableaux. In other words, the number of permutations of $[n]$ is equal to the number of pairs of identically shaped standard Young tableaux whose shape is a partition of $n$, and the number of involutions of $[n]$ is equal to the number of standard Young tableaux whose shape is a partition of $n$. Hence $n!=\sum_{\lambda}\left(f^{\lambda}\right)^{2}$ and $\tau \leq \sum_{\lambda} \frac{f^{\lambda}}{n!}$, where both sums range over all partitions $\lambda$ of $n$.
+For all elements $u \in S$, define the conjugacy class of $u$ to be the set of elements that may be written in the form $s^{-1} u s$ for some $s \in S$. It is easy to see that for all $u, u^{\prime} \in S$, the conjugacy classes of $u$ and $u^{\prime}$ are either identical or disjoint. It follows that $S$ may be partitioned into disjoint conjugacy classes and that any extremely good subset of $S$ must contain at least one element from each distinct conjugacy class. We claim that the number of distinct conjuguacy classes of $S$ is at least the number of integer partitions of $n$. It turns out that the two numbers are in fact equal, but such a result is not necessary for the purposes of this problem. Let $u$ be an arbitrary permutation in $S$. Recall that $u$ may be written as
+
+$$
+\left(a_{1,1} a_{1,2} \ldots a_{1, l_{1}}\right)\left(a_{2,1} a_{2,2} \ldots a_{2, l_{2}}\right) \ldots\left(a_{m, 1} a_{m, 2} \ldots a_{m, l_{m}}\right)
+$$
+
+for some pairwise distinct elements
+
+$$
+a_{1,1}, a_{1,2}, \ldots, a_{1, l_{1}}, a_{2,1}, a_{2,2}, \ldots, a_{2, l_{2}}, \ldots, a_{m, 1}, a_{m, 2}, \ldots, a_{m, l_{m}}
+$$
+
+of $[n]$. Associate to the conjugacy class of $u$ the partition $n=l_{w_{1}}+l_{w_{2}}+\ldots+l_{w_{m}}+1+\ldots+1$, where $w_{1}, w_{2}, \ldots, w_{m}$ is a partition of $1,2, \ldots, m$ such that $w_{1} \geq w_{2} \geq \ldots \geq w_{m}$ and the 1 's represent all the fixed points of $s$. Now note that if $s$ is any permutation in $S, s^{-1} u s$ may be written in the form
+
+$$
+s^{-1}\left(a_{1,1} a_{1,2} \ldots a_{1, l_{1}}\right) s s^{-1}\left(a_{2,1} a_{2,2} \ldots a_{2, l_{2}}\right) s \ldots s^{-1}\left(a_{m, 1} a_{m, 2} \ldots a_{m, l_{m}}\right) s
+$$
+
+which may be written as
+
+$$
+\left(b_{1,1} b_{1,2} \ldots b_{1, l_{1}}\right)\left(b_{2,1} b_{2,2} \ldots b_{2, l_{2}}\right) \ldots\left(b_{m, 1} b_{m, 2} \ldots b_{m, l_{m}}\right)
+$$
+
+for some pairwise distinct elements
+
+$$
+b_{1,1}, b_{1,2}, \ldots, b_{1, l_{1}}, b_{2,1}, b_{2,2}, \ldots, b_{2, l_{2}}, \ldots, b_{m, 1}, b_{m, 2}, \ldots, b_{m, l_{m}}
+$$
+
+of $[n]$ because multiplying by $s^{-1}$ on the left and by $s$ on the right is equivalent to re-indexing the letters $1,2, \ldots, n$. Hence if partitions of $n$ are associated to all conjugacy classes of $S$ analogously, the
+same partition that is associated to $u$ is associated to $s^{-1} u s$ for all $s \in S$. Since exactly one partition is associated to each conjugacy class, it follows that the number of conjugacy classes cannot exceed the number of partitions, as desired.
+To conclude, we need only observe that $v \geq \sum_{\lambda} \frac{1}{n!}$ by our above claim, for then
+
+$$
+n!\sqrt{v}=\sqrt{n!\sum_{\lambda} 1}=\sqrt{\left(\sum_{\lambda}\left(f^{\lambda}\right)^{2}\right)\left(\sum_{\lambda} 1\right)} \geq \sum_{\lambda} f^{\lambda} \geq n!\tau
+$$
+
+by the Cauchy-Schwarz inequality, and this completes the proof.
+Remark: more computationally intensive solutions that do not use Young tableaux but instead calculate the number of involutions explicitly and make use of the generating function for the number of integer partitions are also possible.
+
diff --git a/HarvardMIT/md/en-142-2011-feb-team2-solutions.md b/HarvardMIT/md/en-142-2011-feb-team2-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..8d91953c2d118e8d517af910b1c30c2950a8099f
--- /dev/null
+++ b/HarvardMIT/md/en-142-2011-feb-team2-solutions.md
@@ -0,0 +1,149 @@
+# $14^{\text {th }}$ Annual Harvard-MIT Mathematics Tournament Saturday 12 February 2011
+
+Team Round B
+
+## Think Carefully! [55]
+
+The problems in this section require only short answers.
+
+1. [55] Tom, Dick, and Harry play a game in which they each pick an integer between 1 and 2011. Tom picks a number first and informs Dick and Harry of his choice. Then Dick picks a different number and informs Harry of his choice. Finally, Harry picks a number different from both Tom's and Dick's. After all the picks are complete, an integer is randomly selected between 1 and 2011. The player whose number is closest wins 2 dollars, unless there is a tie, in which case each of the tied players wins 1 dollar. If Tom knows that Dick and Harry will each play optimally and select randomly among equally optimal choices, there are two numbers Tom can pick to maximize his expected profit; what are they?
+Answer: 503, 1509 Let $x$ denote the number Tom chooses. By the symmetry of the problem, picking $x$ and picking $2012-x$ yield the same expected profit. If Tom picks 1006, Dick sees that if he picks 1007 , Harry's best play is to pick 1005 , and Dick will win with probability $\frac{1005}{2011}$, and clearly this is the best outcome he can achieve. So Dick will pick 1007 (or 1005) and Harry will pick 1005 (or 1007), and Tom will win with probability $\frac{1}{2011}$. Picking the number 2 will make the probability of winning at least $\frac{2}{2011}$ since Dick and Harry would both be foolish to pick 1, so picking 1006 is suboptimal. It is now clear that the answer to the problem is some pair $(x, 2012-x)$.
+By the symmetry of the problem we can assume without loss of generality that $1 \leq x \leq 1005$. We will show that of these choices, $x=503$ maximizes Tom's expected profit. The trick is to examine the relationship between Tom's choice and Dick's choice. We claim that (a) if $x>503$, Dick's choice is $2013-x$ and (b) if $x<503$, Dick's choice is $1341+\left\lfloor\frac{x+1}{3}\right\rfloor$. Let $y$ denote the number Dick chooses.
+Proof (a). Note first that if $x>503,2013-x$ is the smallest value of $y$ for which Harry always chooses a number less than $x$. This is obvious, for if $y<2011-x$, a choice of $2012-x$ will give Harry a greater expected profit than a choice of any number less than $x$, and if $y=2012-x$, Harry never chooses a number between $x$ and $y$ since $x-1>\frac{2012-x-x}{2}=1006-x$ holds for all integers $x$ greater than 503, so, by symmetry, Harry chooses a number less than $x$ exactly half the time. The desired result actually follows immediately because the fact that Harry always chooses a number less than $x$ when $y=2013-x$ implies that there would be no point in Dick choosing a number greater than $2013-x$, so it suffices to compare Dick's expected profit when $y=2013-x$ with that of all smaller values of $y$, which is trivial.
+Proof (b). This case is somewhat more difficult. First, it should be obvious that if $x<503$, Harry never chooses a number less than $x$. The proof is by contradiction. If $y \leq 2011-x$, Harry can obtain greater expected profit by choosing $2012-x$ than by choosing any number less than $x$. If $y \geq 1002+x$, Harry can obtain greater expected profit by choosing any number between $x$ and $y$ than by choosing a number less than $x$. Hence if Harry chooses a number less than $x, x$ and $y$ must satisfy $y>2011-x$ and $y<1002+x$, which implies $2 x>2009$, contradiction. We next claim that if $y \geq 1342+\left\lfloor\frac{x+1}{3}\right\rfloor$, then Harry chooses a number between $x$ and $y$. The proof follows from the inequality $\frac{1342+\left\lfloor\frac{x+1}{3}\right\rfloor-x}{2}>2011-\left(1342+\left\lfloor\frac{x+1}{3}\right\rfloor\right)$, which is equivalent to $3\left\lfloor\frac{x+1}{3}\right\rfloor>x-4$, which is obviously true. We also claim that if $y \leq 1340+\left\lfloor\frac{x+1}{3}\right\rfloor$ then Harry chooses a number greater than $y$. The proof follows from the inequality $\frac{1340+\left\lfloor\frac{x+1}{3}\right\rfloor-x}{2}<2011-\left(1340+\left\lfloor\frac{x+1}{3}\right\rfloor\right)$, which is equivalent to $3\left\lfloor\frac{x+1}{3}\right\rfloor
General Test
+
+1. [3] Find all ordered pairs of real numbers $(x, y)$ such that $x^{2} y=3$ and $x+x y=4$.
+
+Answer: $(1,3),\left(3, \frac{1}{3}\right)$ Multiplying the second equation by $x$ gives
+
+$$
+x^{2}+x^{2} y=4 x
+$$
+
+and substituting our known value of $x^{2} y$ gives the quadratic
+
+$$
+x^{2}-4 x+3=0
+$$
+
+so $x=1$ or $x=3$. Hence, we obtain the solutions $(x, y)=(1,3),(3,1 / 3)$.
+2. [3] Let $A B C$ be a triangle, and let $D, E$, and $F$ be the midpoints of sides $B C, C A$, and $A B$, respectively. Let the angle bisectors of $\angle F D E$ and $\angle F B D$ meet at $P$. Given that $\angle B A C=37^{\circ}$ and $\angle C B A=85^{\circ}$, determine the degree measure of $\angle B P D$.
+Answer: $61^{\circ}$ Because $D, E, F$ are midpoints, we have $A B C \sim D E F$. Furthermore, we know that $F D \| A C$ and $D E \| A B$, so we have
+
+$$
+\angle B D F=\angle B C A=180-37-85=58^{\circ}
+$$
+
+Also, $\angle F D E=\angle B A C=37^{\circ}$. Hence, we have
+
+$$
+\angle B P D=180^{\circ}-\angle P B D-\angle P D B=180^{\circ}-\frac{85^{\circ}}{2}-\left(\frac{37^{\circ}}{2}+58^{\circ}\right)=61^{\circ}
+$$
+
+
+3. [4] Alberto, Bernardo, and Carlos are collectively listening to three different songs. Each is simultaneously listening to exactly two songs, and each song is being listened to by exactly two people. In how many ways can this occur?
+Answer: 6 We have $\binom{3}{2}=3$ choices for the songs that Alberto is listening to. Then, Bernardo and Carlos must both be listening to the third song. Thus, there are 2 choices for the song that Bernardo shares with Alberto. From here, we see that the songs that everyone is listening to are forced. Thus, there are a total of $3 \times 2=6$ ways for the three to be listening to songs.
+4. [4] Determine the remainder when
+
+$$
+2^{\frac{1 \cdot 2}{2}}+2^{\frac{2 \cdot 3}{2}}+\cdots+2^{\frac{2011 \cdot 2012}{2}}
+$$
+
+is divided by 7 .
+Answer: 1 We have that $2^{3} \equiv 1(\bmod 7)$. Hence, it suffices to consider the exponents modulo 3. We note that the exponents are the triangular number and upon division by 3 give the pattern of remainders $1,0,0,1,0,0, \ldots$, so what we want is
+
+$$
+\begin{aligned}
+2^{\frac{1 \cdot 2}{2}}+\cdots+2^{\frac{2011 \cdot 2012}{2}} & \equiv 2^{1}+2^{0}+2^{0}+2^{1}+\ldots+2^{0}+2^{1} \quad(\bmod 7) \\
+& \equiv \frac{2010}{3}\left(2^{1}+2^{0}+2^{0}\right)+2^{1} \\
+& \equiv(670)(4)+2 \\
+& \equiv 1 .
+\end{aligned}
+$$
+
+5. [5] Find all real values of $x$ for which
+
+$$
+\frac{1}{\sqrt{x}+\sqrt{x-2}}+\frac{1}{\sqrt{x+2}+\sqrt{x}}=\frac{1}{4}
+$$
+
+Answer: $\frac{257}{16}$ We note that
+
+$$
+\begin{aligned}
+\frac{1}{4} & =\frac{1}{\sqrt{x}+\sqrt{x-2}}+\frac{1}{\sqrt{x+2}+\sqrt{x}} \\
+& =\frac{\sqrt{x}-\sqrt{x-2}}{(\sqrt{x}+\sqrt{x-2})(\sqrt{x}-\sqrt{x-2})}+\frac{\sqrt{x+2}-\sqrt{x}}{(\sqrt{x+2}+\sqrt{x})(\sqrt{x+2}-\sqrt{x})} \\
+& =\frac{\sqrt{x}-\sqrt{x-2}}{2}+\frac{\sqrt{x+2}-\sqrt{x}}{2} \\
+& =\frac{1}{2}(\sqrt{x+2}-\sqrt{x-2}),
+\end{aligned}
+$$
+
+so that
+
+$$
+2 \sqrt{x+2}-2 \sqrt{x-2}=1
+$$
+
+Squaring, we get that
+
+$$
+8 x-8 \sqrt{(x+2)(x-2)}=1 \Rightarrow 8 x-1=8 \sqrt{(x+2)(x-2)} .
+$$
+
+Squaring again gives
+
+$$
+64 x^{2}-16 x+1=64 x^{2}-256
+$$
+
+so we get that $x=\frac{257}{16}$.
+6. [5] Five people of heights $65,66,67,68$, and 69 inches stand facing forwards in a line. How many orders are there for them to line up, if no person can stand immediately before or after someone who is exactly 1 inch taller or exactly 1 inch shorter than himself?
+Answer: 14 Let the people be $A, B, C, D, E$ so that their heights are in that order, with $A$ the tallest and $E$ the shortest. We will do casework based on the position of $C$.
+
+- Case 1: $C$ is in the middle. Then, $B$ must be on one of the two ends, for two choices. This leaves only one choice for $D$-the other end. Then, we know the positions of $A$ and $E$ since $A$ cannot neighbor $B$ and $E$ cannot neighbor $D$. So we have 2 options for this case.
+- Case 2: $C$ is in the second or fourth spot. Then, we have two choices for the position of $C$. Without loss of generality, let $C$ be in the second spot. Then, the first and third spots must be $A$ and $E$, giving us two options. This fixes the positions of $B$ and $D$, so we have a total of $2 \times 2=4$ options for this case.
+- Case 3: $C$ is in the first or last spot. Then, we have two choices for the position of $C$. Without loss of generality, let it be in the first spot. Either $A$ or $E$ is in the second spot, giving us two choices. Without loss of generality, let it be $A$. Then, if $D$ is in the third spot, the positions of $B$ and $E$ are fixed. If $E$ is in third spot, the positions of $B$ and $D$ are fixed, so we have a total of $2 \times 2 \times(1+1)=8$ options for this case.
+
+Hence, we have a total of $2+4+8=14$ possibilities.
+7. [5] Determine the number of angles $\theta$ between 0 and $2 \pi$, other than integer multiples of $\pi / 2$, such that the quantities $\sin \theta, \cos \theta$, and $\tan \theta$ form a geometric sequence in some order.
+Answer: 4 If $\sin \theta, \cos \theta$, and $\tan \theta$ are in a geometric progression, then the product of two must equal the square of the third. Using this criterion, we have 3 cases.
+
+- Case 1: $\sin \theta \cdot \tan \theta=\cos ^{2} \theta$. This implies that $\left(\sin ^{2} \theta\right)=\left(\cos ^{3} \theta\right)$. Writing $\sin ^{2} \theta$ as $1-\cos ^{2} \theta$ and letting $\cos \theta=x$, we have that $x^{3}+x^{2}-1=0$. We wish to find the number of solutions of this where $|x| \leq 1$. Clearly -1 is not a root. If $-1
Team Round
+
+
Team Round}
+
+1. [2] Find the number of positive integers $x$ less than 100 for which
+
+$$
+3^{x}+5^{x}+7^{x}+11^{x}+13^{x}+17^{x}+19^{x}
+$$
+
+is prime.
+Answer: 0 We claim that our integer is divisible by 3 for all positive integers $x$. Indeed, we have
+
+$$
+\begin{aligned}
+3^{x}+5^{x}+7^{x}+11^{x}+13^{x}+17^{x}+19^{x} & \equiv(0)^{x}+(-1)^{x}+(1)^{x}+(-1)^{x}+(1)^{x}+(-1)^{x}+(1)^{x} \\
+& \equiv 3\left[(1)^{x}+(-1)^{x}\right] \\
+& \equiv 0 \quad(\bmod 3) .
+\end{aligned}
+$$
+
+It is clear that for all $x \geq 1$, our integer is strictly greater than 3 , so it will always be composite, making our answer 0 .
+2. [4] Determine the set of all real numbers $p$ for which the polynomial $Q(x)=x^{3}+p x^{2}-p x-1$ has three distinct real roots.
+Answer: $p>1$ and $p<-3$ First, we note that
+
+$$
+x^{3}+p x^{2}-p x-1=(x-1)\left(x^{2}+(p+1) x+1\right)
+$$
+
+Hence, $x^{2}+(p+1) x+1$ has two distinct roots. Consequently, the discriminant of this equation must be positive, so $(p+1)^{2}-4>0$, so either $p>1$ or $p<-3$. However, the problem specifies that the quadratic must have distinct roots (since the original cubic has distinct roots), so to finish, we need to check that 1 is not a double root-we will do this by checking that 1 is not a root of $x^{2}+(p+1) x+1$ for any value $p$ in our range. But this is clear, since $1+(p+1)+1=0 \Rightarrow p=-3$, which is not in the aforementioned range. Thus, our answer is all $p$ satisfying $p>1$ or $p<-3$.
+3. [6] Find the sum of the coefficients of the polynomial $P(x)=x^{4}-29 x^{3}+a x^{2}+b x+c$, given that $P(5)=11, P(11)=17$, and $P(17)=23$.
+Answer: -3193 Define $Q(x)=P(x)-x-6=x^{4}-29 x^{3}+a x^{2}+(b-1) x+(c-6)$ and notice that $Q(5)=Q(11)=Q(17)=0 . Q(x)$ has degree 4 and by Vieta's Formulas the sum of its roots is 29, so its last root is $29-17-11-5=-4$, giving us $Q(x)=(x-5)(x-11)(x-17)(x+4)$. This means that $P(1)=Q(1)+7=(-4)(-10)(-16)(5)+7=-3200+7=-3193$.
+4. [7] Determine the number of quadratic polynomials $P(x)=p_{1} x^{2}+p_{2} x-p_{3}$, where $p_{1}, p_{2}, p_{3}$ are not necessarily distinct (positive) prime numbers less than 50 , whose roots are distinct rational numbers.
+Answer: 31 The existence of distinct rational roots means that the given quadratic splits into linear factors. Then, since $p_{1}, p_{3}$ are both prime, we get that the following are the only possible factorizations:
+
+- $\left(p_{1} x-p_{3}\right)(x+1) \Rightarrow p_{2}=p_{1}-p_{3}$
+- $\left(p_{1} x+p_{3}\right)(x-1) \Rightarrow p_{2}=-p_{1}+p_{3}$
+- $\left(p_{1} x-1\right)\left(x+p_{3}\right) \Rightarrow p_{2}=p_{1} p_{3}-1$
+- $\left(p_{1} x+1\right)\left(x-p_{3}\right) \Rightarrow p_{2}=-p_{1} p_{3}+1$
+
+In the first case, observe that since $p_{2}+p_{3}=p_{1}$, we have $p_{1}>2$, so $p_{1}$ is odd and exactly one of $p_{2}, p_{3}$ is equal to 2 . Thus, we get a solutions for every pair of twin primes below 50 , which we enumerate to be $(3,5),(5,7),(11,13),(17,19),(29,31),(41,43)$, giving 12 solutions in total. Similarly, the second case gives $p_{1}+p_{2}=p_{3}$, for another 12 solutions.
+
+In the third case, if $p_{1}, p_{3}$ are both odd, then $p_{2}$ is even and thus equal to 2 . However, this gives $p_{1} p_{3}=3$, which is impossible. Therefore, at least one of $p_{1}, p_{3}$ is equal to 2 . If $p_{1}=2$, we get $p_{2}=2 p_{3}-1$, which we find has 4 solutions: $\left(p_{2}, p_{3}\right)=(3,2),(5,3),(13,7),(37,19)$. Similarly, there are four solutions with $p_{3}=2$. However, we count the solution $\left(p_{1}, p_{2}, p_{3}\right)=(2,3,2)$ twice, so we have a total of 7 solutions in this case. Finally, in the last case
+
+$$
+p_{2}=-p_{1} p_{3}+1<-(2)(2)+1<0
+$$
+
+so there are no solutions. Hence, we have a total of $12+12+7=31$ solutions.
+5. [3] Sixteen wooden Cs are placed in a 4-by-4 grid, all with the same orientation, and each is to be colored either red or blue. A quadrant operation on the grid consists of choosing one of the four two-by-two subgrids of Cs found at the corners of the grid and moving each C in the subgrid to the adjacent square in the subgrid that is 90 degrees away in the clockwise direction, without changing the orientation of the C. Given that two colorings are the considered same if and only if one can be obtained from the other by a series of quadrant operations, determine the number of distinct colorings of the Cs.
+
+| C | C | C | C |
+| :---: | :---: | :---: | :---: |
+| C | C | C | C |
+| C | C | C | C |
+| C | C | C | C |
+
+Answer: 1296 For each quadrant, we have three distinct cases based on the number of Cs in each color:
+
+- Case 1: all four the same color: 2 configurations (all red or all blue)
+- Case 2: 3 of one color, 1 of the other: 2 configurations (three red or three blue)
+- Case 3: 2 of each color: 2 configurations (red squares adjacent or opposite)
+
+Thus, since there are 4 quadrants, there are a total of $(2+2+2)^{4}=1296$ possible grids.
+6. [5] Ten Cs are written in a row. Some Cs are upper-case and some are lower-case, and each is written in one of two colors, green and yellow. It is given that there is at least one lower-case C, at least one green C , and at least one C that is both upper-case and yellow. Furthermore, no lower-case C can be followed by an upper-case C , and no yellow C can be followed by a green C . In how many ways can the Cs be written?
+Answer: 36 By the conditions of the problem, we must pick some point in the line where the green Cs transition to yellow, and some point where the upper-case Cs transition to lower-case. We see that the first transition must occur before the second, and that they cannot occur on the same C. Hence, the answer is $\binom{9}{2}=36$.
+7. [7] Julia is learning how to write the letter C. She has 6 differently-colored crayons, and wants to write Cc Cc Cc Cc Cc . In how many ways can she write the ten Cs , in such a way that each upper case C is a different color, each lower case C is a different color, and in each pair the upper case C and lower case C are different colors?
+
+Answer: 222480 Suppose Julia writes Cc a sixth time, coloring the upper-case C with the unique color different from that of the first five upper-case Cs, and doing the same with the lower-case C (note: we allow the sixth upper-case C and lower-case c to be the same color). Note that because the colors on the last Cc are forced, and any forced coloring of them is admissible, our problem is equivalent to coloring these six pairs.
+There are 6! ways for Julia to color the upper-case Cs. We have two cases for coloring the lower-case Cs:
+
+- Case 1: the last pair of Cs use two different colors. In this case, all six lower-case Cs have a different color to their associated upper-case C, and in addition the six lower-case Cs all use each color exactly once. In other words, we have a derangement* of the six colors, based on the colors of the upper-case Cs. We calculate $D_{6}=265$ ways to color the lower-case Cs here.
+- Case 2: the last pair of Cs have both Cs the same color. Then, the color of the last lower-case C is forced, and with the other five Cs we, in a similar way to before, have a derangement of the remaining five colors based on the colors of the first five lower-case Cs, so we have $D_{5}=44$ ways to finish the coloring.
+
+Our answer is thus $720(265+44)=222480$.
+*A derangement is a permutation $\pi$ of the set $\{1,2, \ldots, n\}$ such that $\pi(k) \neq k$ for all $k$, i.e. there are no fixed points of the permutation. To calculate $D_{n}$, the number of derangements of an $n$-element set, we can use an inclusion-exclusion argument. There are $n$ ! ways to permute the elements of the set. Now, we subtract the number of permutations with at least one fixed point, which is $\binom{n}{1}(n-1)!=\frac{n!}{1!}$, since we choose a fixed point, then permute the other $n-1$ elements. Correcting for overcounting, we add back the number of permutations with at least two fixed points, which is $\binom{n}{2}(n-2)!=\frac{n!}{2!}$. Continuing in this fashion by use of the principle of inclusion-exclusion, we get
+
+$$
+D_{n}=n!\left(\frac{1}{0!}-\frac{1}{1!}+\frac{1}{2!}+\cdots+\frac{(-1)^{n}}{n!}\right)
+$$
+
+8. [4] Let $G, A_{1}, A_{2}, A_{3}, A_{4}, B_{1}, B_{2}, B_{3}, B_{4}, B_{5}$ be ten points on a circle such that $G A_{1} A_{2} A_{3} A_{4}$ is a regular pentagon and $G B_{1} B_{2} B_{3} B_{4} B_{5}$ is a regular hexagon, and $B_{1}$ lies on minor arc $G A_{1}$. Let $B_{5} B_{3}$ intersect $B_{1} A_{2}$ at $G_{1}$, and let $B_{5} A_{3}$ intersect $G B_{3}$ at $G_{2}$. Determine the degree measure of $\angle G G_{2} G_{1}$.
+Answer: $12^{\circ}$
+
+
+Note that $G B_{3}$ is a diameter of the circle. As a result, $A_{2}, A_{3}$ are symmetric with respect to $G B_{3}$, as are $B_{1}, B_{5}$. Therefore, $B_{1} A_{2}$ and $B_{5} A_{3}$ intersect along line $G B_{3}$, so in fact, $B_{1}, A_{2}, G_{1}, G_{2}$ are collinear. We now have
+
+$$
+\angle G G_{2} G_{1}=\angle G G_{2} B_{1}=\frac{\widehat{G B_{1}}-\widehat{B_{3} A_{2}}}{2}=\frac{60^{\circ}-36^{\circ}}{2}=12^{\circ} .
+$$
+
+9. [4] Let $A B C$ be a triangle with $A B=9, B C=10$, and $C A=17$. Let $B^{\prime}$ be the reflection of the point $B$ over the line $C A$. Let $G$ be the centroid of triangle $A B C$, and let $G^{\prime}$ be the centroid of triangle $A B^{\prime} C$. Determine the length of segment $G G^{\prime}$.
+Answer: $\frac{48}{17}$
+
+
+Let $M$ be the midpoint of $A C$. For any triangle, we know that the centroid is located $2 / 3$ of the way from the vertex, so we have $M G / M B=M G^{\prime} / M B^{\prime}=1 / 3$, and it follows that $M G G^{\prime} \sim M B B^{\prime}$. Thus, $G G^{\prime}=B B^{\prime} / 3$. However, note that $B B^{\prime}$ is twice the altitude to $A C$ in triangle $A B C$. To finish, we calculate the area of $A B C$ in two different ways. By Heron's Formula, we have
+
+$$
+[A B C]=\sqrt{18(18-9)(18-10)(18-17)}=36
+$$
+
+and we also have
+
+$$
+[A B C]=\frac{1}{4} B B^{\prime} \cdot A C=\frac{17}{4}\left(B B^{\prime}\right)
+$$
+
+from which it follows that $G G^{\prime}=B B^{\prime} / 3=48 / 17$.
+10. [8] Let $G_{1} G_{2} G_{3}$ be a triangle with $G_{1} G_{2}=7, G_{2} G_{3}=13$, and $G_{3} G_{1}=15$. Let $G_{4}$ be a point outside triangle $G_{1} G_{2} G_{3}$ so that ray $\overrightarrow{G_{1} G_{4}}$ cuts through the interior of the triangle, $G_{3} G_{4}=G_{4} G_{2}$, and $\angle G_{3} G_{1} G_{4}=30^{\circ}$. Let $G_{3} G_{4}$ and $G_{1} G_{2}$ meet at $G_{5}$. Determine the length of segment $G_{2} G_{5}$.
+Answer: $\frac{169}{23}$
+
+
+We first show that quadrilateral $G_{1} G_{2} G_{4} G_{3}$ is cyclic. Note that by the law of cosines,
+
+$$
+\cos \angle G_{2} G_{1} G_{3}=\frac{7^{2}+15^{2}-13^{2}}{2 \cdot 7 \cdot 15}=\frac{1}{2}
+$$
+
+so $\angle G_{2} G_{1} G_{3}=60^{\circ}$. However, we know that $\angle G_{3} G_{1} G_{4}=30^{\circ}$, so $G_{1} G_{4}$ is an angle bisector. Now, let $G_{1} G_{4}$ intersect the circumcircle of triangle $G_{1} G_{2} G_{3}$ at $X$. Then, the minor arcs $\widehat{G_{2} X}$ and $\widehat{G_{3} X}$ are subtended by the equal angles $\angle G_{2} G_{1} X$ and $\angle G_{3} G_{1} X$, implying that $G_{2} X=G_{3} X$, i.e. $X$ is on the perpendicular bisector of $G_{2} G_{3}, l$. Similarly, since $G_{4} G_{2}=G_{4} G_{3}, G_{4}$ lies on $l$. However, since $l$ and $G_{1} G_{4}$ are distinct (in particular, $G_{1}$ lies on $G_{1} G_{4}$ but not $l$ ), we in fact have $X=G_{4}$, so $G_{1} G_{2} G_{4} G_{3}$ is cyclic.
+We now have $G_{5} G_{2} G_{4} \sim G_{5} G_{3} G_{1}$ since $G_{1} G_{2} G_{4} G_{3}$ is cyclic. Now, we have $\angle G_{4} G_{3} G_{2}=\angle G_{4} G_{1} G_{2}=$ $30^{\circ}$, and we may now compute $G_{2} G_{4}=G_{4} G_{3}=13 / \sqrt{3}$. Let $G_{5} G_{2}=x$ and $G_{5} G_{4}=y$. Now, from $G_{5} G_{4} G_{2} \sim G_{5} G_{1} G_{3}$, we have:
+
+$$
+\frac{x}{y+13 / \sqrt{3}}=\frac{13 / \sqrt{3}}{15}=\frac{y}{x+7}
+$$
+
+Equating the first and second expressions and cross-multiplying, we get
+
+$$
+y+\frac{13 \sqrt{3}}{3}=\frac{15 \sqrt{3} x}{13} .
+$$
+
+Now, equating the first and third expressions and and substituting gives
+
+$$
+\left(\frac{15 \sqrt{3} x}{13}-\frac{13 \sqrt{3}}{3}\right)\left(\frac{15 \sqrt{3} x}{13}\right)=x(x+7)
+$$
+
+Upon dividing both sides by $x$, we obtain a linear equation from which we can solve to get $x=169 / 23$.
+
diff --git a/HarvardMIT/md/en-151-2011-nov-thm-solutions.md b/HarvardMIT/md/en-151-2011-nov-thm-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..f6116a6fd3205f9b5500102f52c62203859b95b4
--- /dev/null
+++ b/HarvardMIT/md/en-151-2011-nov-thm-solutions.md
@@ -0,0 +1,109 @@
+## $4^{\text {th }}$ Annual Harvard-MIT November Tournament Saturday 12 November 2011 Theme Round
+
+1. [3] Five of James' friends are sitting around a circular table to play a game of Fish. James chooses a place between two of his friends to pull up a chair and sit. Then, the six friends divide themselves into two disjoint teams, with each team consisting of three consecutive players at the table. If the order in which the three members of a team sit does not matter, how many possible (unordered) pairs of teams are possible?
+Answer: 5 Note that the team not containing James must consist of three consecutive players who are already seated. We have 5 choices for the player sitting furthest clockwise on the team of which James is not a part. The choice of this player uniquely determines the teams, so we have a total of 5 possible pairs.
+2. [3] In a game of Fish, R2 and R3 are each holding a positive number of cards so that they are collectively holding a total of 24 cards. Each player gives an integer estimate for the number of cards he is holding, such that each estimate is an integer between $80 \%$ of his actual number of cards and $120 \%$ of his actual number of cards, inclusive. Find the smallest possible sum of the two estimates.
+Answer: 20 To minimize the sum, we want each player to say an estimate as small as possible-i.e. an estimate as close to $80 \%$ of his actual number of cards as possible. We claim that the minimum possible sum is 20 .
+First, this is achievable when R2 has 10 cards and estimates 8, and when R3 has 14 cards and estimates 12.
+
+Then, suppose that R2 has $x$ cards and R3 has $24-x$. Then, the sum of their estimates is
+
+$$
+\left\lceil\frac{4}{5}(x)\right\rceil+\left\lceil\frac{4}{5}(24-x)\right\rceil \geq\left\lceil\frac{4}{5}(x)+\frac{4}{5}(24-x)\right\rceil \geq\left\lceil\frac{4}{5}(24)\right\rceil \geq 20
+$$
+
+Note: We use the fact that for all real numbers $a, b,\lceil a\rceil+\lceil b\rceil \geq\lceil a+b\rceil$.
+3. [5] In preparation for a game of Fish, Carl must deal 48 cards to 6 players. For each card that he deals, he runs through the entirety of the following process:
+
+1. He gives a card to a random player.
+2. A player Z is randomly chosen from the set of players who have at least as many cards as every other player (i.e. Z has the most cards or is tied for having the most cards).
+3. A player D is randomly chosen from the set of players other than Z who have at most as many cards as every other player (i.e. D has the fewest cards or is tied for having the fewest cards).
+4. Z gives one card to D.
+
+He repeats steps 1-4 for each card dealt, including the last card. After all the cards have been dealt, what is the probability that each player has exactly 8 cards?
+
+Answer: | $\frac{5}{6}$ |
+| :---: |
+| After any number of cards are dealt, we see that the difference between the number of | cards that any two players hold is at most one. Thus, after the first 47 cards have been dealt, there is only one possible distribution: there must be 5 players with 8 cards and 1 player with 7 cards. We have two cases:
+
+- Carl gives the last card to the player with 7 cards. Then, this player must give a card to another, leading to a uneven distribution of cards.
+- Carl gives the last card to a player already with 8 cards. Then, that player must give a card to another; however, our criteria specify that he can only give it to the player with 7 cards, leading to an even distribution.
+
+The probability of the second case happening, as Carl deals at random, is $\frac{5}{6}$.
+4. [6] Toward the end of a game of Fish, the 2 through 7 of spades, inclusive, remain in the hands of three distinguishable players: $\mathrm{DBR}, \mathrm{RB}$, and DB , such that each player has at least one card. If it is known that DBR either has more than one card or has an even-numbered spade, or both, in how many ways can the players' hands be distributed?
+Answer: 450 First, we count the number of distributions where each player has at least 1 card. The possible distributions are:
+
+- Case 1: $4 / 1 / 1$ : There are 3 choices for who gets 4 cards, 6 choices for the card that one of the single-card players holds, and 5 choices for the card the other single-card player holds, or $3 \times 6 \times 5=90$ choices.
+- Case 2: $3 / 2 / 1$ : There are 6 choices for the single card, $\binom{5}{2}=10$ choices for the pair of cards, and $3!=6$ choices for which player gets how many cards, for a total of $6 \times 10 \times 6=360$ choices.
+- Case 3: $2 / 2 / 2$ : There are $\binom{6}{2}=15$ choices for the cards DBR gets, $\binom{4}{2}=6$ for the cards that $R B$ gets, and $D B$ gets the remaining two cards. This gives a total of $15 \times 6=90$ choices.
+
+Thus, we have a total of $90+360+90=540$ ways for the cards to be distributed so that each person holds at least one.
+Next, we look at the number of ways that the condition cannot be satisfied if each player has at least one card. Then, DBR must have no more than one card, and cannot have an even spade. We only care about cases where he has a non-zero number of cards, so he must have exactly 1 odd spade. Then, we see that there are $2^{5}-2=30$ ways to distribute the other 5 cards among RB and DB so that neither has 0 cards. Since there are 3 odd spades, this gives $3 \times 30$ bad cases, so we have $540-90=450$ ones where all the problem conditions hold.
+5. [8] For any finite sequence of positive integers $\pi$, let $S(\pi)$ be the number of strictly increasing subsequences in $\pi$ with length 2 or more. For example, in the sequence $\pi=\{3,1,2,4\}$, there are five increasing sub-sequences: $\{3,4\},\{1,2\},\{1,4\},\{2,4\}$, and $\{1,2,4\}$, so $S(\pi)=5$. In an eight-player game of Fish, Joy is dealt six cards of distinct values, which she puts in a random order $\pi$ from left to right in her hand. Determine
+
+$$
+\sum_{\pi} S(\pi)
+$$
+
+where the sum is taken over all possible orders $\pi$ of the card values.
+Answer: 8287 For each subset of Joy's set of cards, we compute the number of orders of cards in which the cards in the subset are arranged in increasing order. When we sum over all subsets of Joy's cards, we will obtain the desired sum.
+Consider any subset of $k$ cards. The probability that they are arranged in increasing order is precisely $1 / k$ ! (since we can form a $k!$-to- 1 correspondence between all possible orders and orders in which the cards in our subset are in increasing order), and there are $6!=720$ total arrangements so exactly $720 / k$ ! of them give an increasing subsequence in the specified cards. Now for any for $k=2,3,4,5,6$, we have $\binom{6}{k}$ subsets of $k$ cards, so we sum to get
+
+$$
+\sum_{\pi} S(\pi)=\sum_{k=2}^{6}\binom{6}{k} \cdot \frac{6!}{k!}=8287
+$$
+
+6. [3] Let $A B C$ be an equilateral triangle with $A B=3$. Circle $\omega$ with diameter 1 is drawn inside the triangle such that it is tangent to sides $A B$ and $A C$. Let $P$ be a point on $\omega$ and $Q$ be a point on segment $B C$. Find the minimum possible length of the segment $P Q$.
+
+Answer: $\frac{3 \sqrt{3}-3}{2}$ Let $P, Q$, be the points which minimize the distance. We see that we want both to lie on the altitude from $A$ to $B C$. Hence, $Q$ is the foot of the altitude from $A$ to $B C$ and $A Q=\frac{3 \sqrt{3}}{2}$. Let $O$, which must also lie on this line, be the center of $\omega$, and let $D$ be the point of tangency between $\omega$ and $A C$. Then, since $O D=\frac{1}{2}$, we have $A O=2 O D=1$ because $\angle O A D=30^{\circ}$, and $O P=\frac{1}{2}$. Consequently,
+
+$$
+P Q=A Q-A O-O P=\frac{3 \sqrt{3}-3}{2}
+$$
+
+
+7. [4] Let $X Y Z$ be a triangle with $\angle X Y Z=40^{\circ}$ and $\angle Y Z X=60^{\circ}$. A circle $\Gamma$, centered at the point $I$, lies inside triangle $X Y Z$ and is tangent to all three sides of the triangle. Let $A$ be the point of tangency of $\Gamma$ with $Y Z$, and let ray $\overrightarrow{X I}$ intersect side $Y Z$ at $B$. Determine the measure of $\angle A I B$.
+Answer: $10^{\circ}$ Let $D$ be the foot of the perpendicular from $X$ to $Y Z$. Since $I$ is the incenter and $A$ the point of tangency, $I A \perp Y Z$, so
+
+$$
+A I \| X D \Rightarrow \angle A I B=\angle D X B
+$$
+
+Since $I$ is the incenter,
+
+$$
+\angle B X Z=\frac{1}{2} \angle Y X Z=\frac{1}{2}\left(180^{\circ}-40^{\circ}-60^{\circ}\right)=40^{\circ} .
+$$
+
+Consequently, we get that
+
+$$
+\angle A I B=\angle D X B=\angle Z X B-\angle Z X D=40^{\circ}-\left(90^{\circ}-60^{\circ}\right)=10^{\circ}
+$$
+
+
+8. [5] Points $D, E, F$ lie on circle $O$ such that the line tangent to $O$ at $D$ intersects ray $\overrightarrow{E F}$ at $P$. Given that $P D=4, P F=2$, and $\angle F P D=60^{\circ}$, determine the area of circle $O$.
+
+Answer: $12 \pi \quad$ By the power of a point on $P$, we get that
+
+$$
+16=P D^{2}=(P F)(P E)=2(P E) \Rightarrow P E=8
+$$
+
+However, since $P E=2 P D$ and $\angle F P D=60^{\circ}$, we notice that $P D E$ is a $30-60-90$ triangle, so $D E=4 \sqrt{3}$ and we have $E D \perp D P$. It follows that $D E$ is a diameter of the circle, since tangents the tangent at $D$ must be perpendicular to the radius containing $D$. Hence, the area of the circle is $\left(\frac{1}{2} D E\right)^{2} \pi=12 \pi$.
+
+9. [6] Let $A B C$ be a triangle with $A B=13, B C=14$, and $C A=15$. Let $D$ be the foot of the altitude from $A$ to $B C$. The inscribed circles of triangles $A B D$ and $A C D$ are tangent to $A D$ at $P$ and $Q$, respectively, and are tangent to $B C$ at $X$ and $Y$, respectively. Let $P X$ and $Q Y$ meet at $Z$. Determine the area of triangle $X Y Z$.
+Answer: $\frac{25}{4}$ First, note that $A D=12, B D=5, C D=9$.
+By equal tangents, we get that $P D=D X$, so $P D X$ is isosceles. Because $D$ is a right angle, we get that $\angle P X D=45^{\circ}$. Similarly, $\angle X Y Z=45^{\circ}$, so $X Y Z$ is an isosceles right triangle with hypotenuse $X Y$. However, by tangents to the incircle, we get that $X D=\frac{1}{2}(12+5-13)=2$ and $Y D=\frac{1}{2}(12+9-15)=3$. Hence, the area of the XYZ is $\frac{1}{4}(X Y)^{2}=\frac{1}{4}(2+3)^{2}=\frac{25}{4}$.
+
+10. [7] Let $\Omega$ be a circle of radius 8 centered at point $O$, and let $M$ be a point on $\Omega$. Let $S$ be the set of points $P$ such that $P$ is contained within $\Omega$, or such that there exists some rectangle $A B C D$ containing $P$ whose center is on $\Omega$ with $A B=4, B C=5$, and $B C \| O M$. Find the area of $S$.
+
+Answer: $164+64 \pi$ We wish to consider the union of all rectangles $A B C D$ with $A B=4, B C=5$, and $B C \| \overline{O M}$, with center $X$ on $\Omega$. Consider translating rectangle $A B C D$ along the radius $X O$ to a rectangle $A^{\prime} B^{\prime} C^{\prime} D^{\prime}$ now centered at $O$. It is now clear that that every point inside $A B C D$ is a translate of a point in $A^{\prime} B^{\prime} C^{\prime} D^{\prime}$, and furthermore, any rectangle $A B C D$ translates along the appropriate radius to the same rectangle $A^{\prime} B^{\prime} C^{\prime} D^{\prime}$.
+We see that the boundary of this region can be constructed by constructing a quarter-circle at each vertex, then connecting these quarter-circles with tangents to form four rectangular regions. Now, splitting our region in to four quarter circles and five rectangles, we compute the desired area to be
+
+$$
+4 \cdot \frac{1}{4}(8)^{2} \pi+2(4 \cdot 8)+2(5 \cdot 8)+(4 \cdot 5)=164+64 \pi
+$$
+
+
+
diff --git a/HarvardMIT/md/en-152-2012-feb-alg-solutions.md b/HarvardMIT/md/en-152-2012-feb-alg-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..846d4536cfb06b5340e22be1732fa039e2602c77
--- /dev/null
+++ b/HarvardMIT/md/en-152-2012-feb-alg-solutions.md
@@ -0,0 +1,243 @@
+# $15^{\text {th }}$ Annual Harvard-MIT Mathematics Tournament Saturday 11 February 2012
Algebra Test
+
+
Algebra Test}
+
+1. Let $f$ be the function such that
+
+$$
+f(x)= \begin{cases}2 x & \text { if } x \leq \frac{1}{2} \\ 2-2 x & \text { if } x>\frac{1}{2}\end{cases}
+$$
+
+What is the total length of the graph of $\underbrace{f(f(\ldots f}_{2012 f^{\prime} s}(x) \ldots))$ from $x=0$ to $x=1$ ?
+Answer: $\sqrt{\sqrt{4^{2012}+1}}$ When there are $n$ copies of $f$, the graph consists of $2^{n}$ segments, each of which goes $1 / 2^{n}$ units to the right, and alternately 1 unit up or down. So, the length is
+
+$$
+2^{n} \sqrt{1+\frac{1}{2^{2 n}}}=\sqrt{4^{n}+1}
+$$
+
+Taking $n=2012$, the answer is
+
+$$
+\sqrt{4^{2012}+1}
+$$
+
+2. You are given an unlimited supply of red, blue, and yellow cards to form a hand. Each card has a point value and your score is the sum of the point values of those cards. The point values are as follows: the value of each red card is 1 , the value of each blue card is equal to twice the number of red cards, and the value of each yellow card is equal to three times the number of blue cards. What is the maximum score you can get with fifteen cards?
+Answer: 168 If there are $B$ blue cards, then each red card contributes $1+2 B$ points (one for itself and two for each blue card) and each yellow card contributes $3 B$ points. Thus, if $B>1$, it is optimal to change all red cards to yellow cards. When $B=0$, the maximum number of points is 15 . When $B=1$, the number of points is always 42 . When $B>1$, the number of points is $3 B Y$, where $Y$ is the number of yellow cards. Since $B+Y=15$, the desired maximum occurs when $B=7$ and $Y=8$, which gives 168 points.
+3. Given points $a$ and $b$ in the plane, let $a \oplus b$ be the unique point $c$ such that $a b c$ is an equilateral triangle with $a, b, c$ in the clockwise orientation.
+
+Solve $(x \oplus(0,0)) \oplus(1,1)=(1,-1)$ for $x$.
+Answer: $\left(\frac{1-\sqrt{3}}{2}, \frac{3-\sqrt{3}}{2}\right)$ It is clear from the definition of $\oplus$ that $b \oplus(a \oplus b)=a$ and if $a \oplus b=c$ then $b \oplus c=a$ and $c \oplus a=b$. Therefore $x \oplus(0,0)=(1,1) \oplus(1,-1)=(1-\sqrt{3}, 0)$. Now this means $x=(0,0) \oplus(1-\sqrt{3}, 0)=\left(\frac{1-\sqrt{3}}{2}, \frac{3-\sqrt{3}}{2}\right)$.
+4. During the weekends, Eli delivers milk in the complex plane. On Saturday, he begins at $z$ and delivers milk to houses located at $z^{3}, z^{5}, z^{7}, \ldots, z^{2013}$, in that order; on Sunday, he begins at 1 and delivers milk to houses located at $z^{2}, z^{4}, z^{6}, \ldots, z^{2012}$, in that order. Eli always walks directly (in a straight line) between two houses. If the distance he must travel from his starting point to the last house is $\sqrt{2012}$ on both days, find the real part of $z^{2}$.
+Answer: $\frac{1005}{1006}$ Note that the distance between two points in the complex plane, $m$ and $n$, is $|m-n|$. We have that
+
+$$
+\sum_{k=1}^{1006}\left|z^{2 k+1}-z^{2 k-1}\right|=\sum_{k=1}^{1006}\left|z^{2 k}-z^{2 k-2}\right|=\sqrt{2012}
+$$
+
+However, noting that
+
+$$
+|z| \cdot \sum_{k=1}^{1006}\left|z^{2 k}-z^{2 k-2}\right|=\sum_{k=1}^{1006}\left|z^{2 k+1}-z^{2 k-1}\right|
+$$
+
+we must have $|z|=1$. Then, since Eli travels a distance of $\sqrt{2012}$ on each day, we have
+
+$$
+\begin{aligned}
+\sum_{k=1}^{1006}\left|z^{2 k}-z^{2 k-2}\right|= & \left|z^{2}-1\right| \cdot \sum_{k=1}^{1006}\left|z^{2 k-2}\right|=\left|z^{2}-1\right| \cdot \sum_{k=1}^{1006}|z|^{2 k-2} \\
+& =1006\left|z^{2}-1\right|=\sqrt{2012}
+\end{aligned}
+$$
+
+so $\left|z^{2}-1\right|=\frac{\sqrt{2012}}{1006}$. Since $|z|=1$, we can write $z=\cos (\theta)+i \sin (\theta)$ and then $z^{2}=\cos (2 \theta)+i \sin (2 \theta)$. Hence,
+
+$$
+\left|z^{2}-1\right|=\sqrt{(\cos (2 \theta)-1)^{2}+\sin ^{2}(2 \theta)}=\sqrt{2-2 \cos (2 \theta)}=\frac{\sqrt{2012}}{1006}
+$$
+
+so $2-2 \cos (2 \theta)=\frac{2}{1006}$. The real part of $z^{2}, \cos (2 \theta)$, is thus $\frac{1005}{1006}$.
+5. Find all ordered triples $(a, b, c)$ of positive reals that satisfy: $\lfloor a\rfloor b c=3, a\lfloor b\rfloor c=4$, and $a b\lfloor c\rfloor=5$, where $\lfloor x\rfloor$ denotes the greatest integer less than or equal to $x$.
+Answer: $\left(\frac{\sqrt{30}}{3}, \frac{\sqrt{30}}{4}, \frac{2 \sqrt{30}}{5}\right),\left(\frac{\sqrt{30}}{3}, \frac{\sqrt{30}}{2}, \frac{\sqrt{30}}{5}\right)$ Write $p=a b c, q=\lfloor a\rfloor\lfloor b\rfloor\lfloor c\rfloor$. Note that $q$ is an integer.
+Multiplying the three equations gives:
+
+$$
+p=\sqrt{\frac{60}{q}}
+$$
+
+Substitution into the first equation,
+
+$$
+p=3 \frac{a}{\lfloor a\rfloor}<3 \frac{\lfloor a\rfloor+1}{\lfloor a\rfloor} \leq 6
+$$
+
+Looking at the last equation:
+
+$$
+p=5 \frac{c}{\lfloor c\rfloor} \geq 5 \frac{\lfloor c\rfloor}{\lfloor c\rfloor} \geq 5
+$$
+
+Here we've used $\lfloor x\rfloor \leq x<\lfloor x\rfloor+1$, and also the apparent fact that $\lfloor a\rfloor \geq 1$. Now:
+
+$$
+\begin{aligned}
+& 5 \leq \sqrt{\frac{60}{q}} \leq 6 \\
+& \frac{12}{5} \geq q \geq \frac{5}{3}
+\end{aligned}
+$$
+
+Since $q$ is an integer, we must have $q=2$. Since $q$ is a product of 3 positive integers, we must have those be 1,1 , and 2 in some order, so there are three cases:
+
+Case 1: $\lfloor a\rfloor=2$. By the equations, we'd need $a=\frac{2}{3} \sqrt{30}=\sqrt{120 / 9}>3$, a contradiction, so there are no solutions in this case.
+
+Case 2: $\lfloor b\rfloor=2$. We have the solution
+
+$$
+\left(\frac{\sqrt{30}}{3}, \frac{\sqrt{30}}{2}, \frac{\sqrt{30}}{5}\right)
+$$
+
+Case 3: $\lfloor c\rfloor=2$. We have the solution
+
+$$
+\left(\frac{\sqrt{30}}{3}, \frac{\sqrt{30}}{4}, \frac{2 \sqrt{30}}{5}\right)
+$$
+
+6. Let $a_{0}=-2, b_{0}=1$, and for $n \geq 0$, let
+
+$$
+\begin{aligned}
+& a_{n+1}=a_{n}+b_{n}+\sqrt{a_{n}^{2}+b_{n}^{2}} \\
+& b_{n+1}=a_{n}+b_{n}-\sqrt{a_{n}^{2}+b_{n}^{2}}
+\end{aligned}
+$$
+
+Find $a_{2012}$.
+Answer: $2^{1006} \sqrt{2^{2010}+2}-2^{2011}$ We have
+
+$$
+\begin{gathered}
+a_{n+1}+b_{n+1}=2\left(a_{n}+b_{n}\right) \\
+a_{n+1} b_{n+1}=\left(a_{n}+b_{n}\right)^{2}-a_{n}^{2}-b_{n}^{2}=2 a_{n} b_{n}
+\end{gathered}
+$$
+
+Thus,
+
+$$
+\begin{aligned}
+a_{n}+b_{n} & =-2^{n} \\
+a_{n} b_{n} & =-2^{n+1}
+\end{aligned}
+$$
+
+Using Viete's formula, $a_{2012}$ and $b_{2012}$ are the roots of the following quadratic, and, since the square root is positive, $a_{2012}$ is the bigger root:
+
+$$
+x^{2}+2^{2012} x-2^{2013}
+$$
+
+Thus,
+
+$$
+a_{2012}=2^{1006} \sqrt{2^{2010}+2}-2^{2011}
+$$
+
+7. Let $\otimes$ be a binary operation that takes two positive real numbers and returns a positive real number. Suppose further that $\otimes$ is continuous, commutative $(a \otimes b=b \otimes a)$, distributive across multiplication $(a \otimes(b c)=(a \otimes b)(a \otimes c))$, and that $2 \otimes 2=4$. Solve the equation $x \otimes y=x$ for $y$ in terms of $x$ for $x>1$.
+Answer: $y=\sqrt{2}$ We note that $\left(a \otimes b^{k}\right)=(a \otimes b)^{k}$ for all positive integers $k$. Then for all rational numbers $\frac{p}{q}$ we have $a \otimes b^{\frac{p}{q}}=\left(a \otimes b^{\frac{1}{q}}\right)^{p}=(a \otimes b)^{\frac{p}{q}}$. So by continuity, for all real numbers $a, b$, it follows that $2^{a} \otimes 2^{b}=(2 \otimes 2)^{a b}=4^{a b}$. Therefore given positive reals $x, y$, we have $x \otimes y=2^{\log _{2}(x)} \otimes 2^{\log _{2}(y)}=$ $4^{\log _{2}(x) \log _{2}(y)}$.
+If $x=4^{\log _{2}(x) \log _{2}(y)}=2^{2 \log _{2}(x) \log _{2}(y)}$ then $\log _{2}(x)=2 \log _{2}(x) \log _{2}(y)$ and $1=2 \log _{2}(y)=\log _{2}\left(y^{2}\right)$. Thus $y=\sqrt{2}$ regardless of $x$.
+8. Let $x_{1}=y_{1}=x_{2}=y_{2}=1$, then for $n \geq 3$ let $x_{n}=x_{n-1} y_{n-2}+x_{n-2} y_{n-1}$ and $y_{n}=y_{n-1} y_{n-2}-$ $x_{n-1} x_{n-2}$. What are the last two digits of $\left|x_{2012}\right|$ ?
+Answer: 84 Let $z_{n}=y_{n}+x_{n} i$. Then the recursion implies that:
+
+$$
+\begin{aligned}
+& z_{1}=z_{2}=1+i \\
+& z_{n}=z_{n-1} z_{n-2}
+\end{aligned}
+$$
+
+This implies that
+
+$$
+z_{n}=\left(z_{1}\right)^{F_{n}}
+$$
+
+where $F_{n}$ is the $n^{\text {th }}$ Fibonacci number $\left(F_{1}=F_{2}=1\right)$. So, $z_{2012}=(1+i)^{F_{2012}}$. Notice that
+
+$$
+(1+i)^{2}=2 i
+$$
+
+Also notice that every third Fibonnaci number is even, and the rest are odd. So:
+
+$$
+z_{2012}=(2 i)^{\frac{F_{2012}-1}{2}}(1+i)
+$$
+
+## Algebra Test
+
+Let $m=\frac{F_{2012}-1}{2}$. Since both real and imaginary parts of $1+i$ are 1 , it follows that the last two digits of $\left|x_{2012}\right|$ are simply the last two digits of $2^{m}=2^{\frac{F_{2012}-1}{2}}$.
+By the Chinese Remainder Theorem, it suffices to evaluate $2^{m}$ modulo 4 and 25 . Clearly, $2^{m}$ is divisible by 4 . To evaluate it modulo 25 , it suffices by Euler's Totient theorem to evaluate $m$ modulo 20.
+To determine $\left(F_{2012}-1\right) / 2$ modulo 4 it suffices to determine $F_{2012}$ modulo 8. The Fibonacci sequence has period 12 modulo 8 , and we find
+
+$$
+\begin{aligned}
+F_{2012} & \equiv 5 \quad(\bmod 8) \\
+m & \equiv 2 \quad(\bmod 4)
+\end{aligned}
+$$
+
+$2 * 3 \equiv 1(\bmod 5)$, so
+
+$$
+m \equiv 3 F_{2012}-3 \quad(\bmod 5)
+$$
+
+The Fibonacci sequence has period 20 modulo 5, and we find
+
+$$
+m \equiv 4 \quad(\bmod 5)
+$$
+
+Combining,
+
+$$
+\begin{aligned}
+m & \equiv 14 \quad(\bmod 20) \\
+2^{m} & \equiv 2^{14}=4096 \equiv 21 \quad(\bmod 25) \\
+\left|x_{2012}\right| & \equiv 4 \cdot 21=84 \quad(\bmod 100)
+\end{aligned}
+$$
+
+9. How many real triples $(a, b, c)$ are there such that the polynomial $p(x)=x^{4}+a x^{3}+b x^{2}+a x+c$ has exactly three distinct roots, which are equal to $\tan y, \tan 2 y$, and $\tan 3 y$ for some real $y$ ?
+Answer: 18 Let $p$ have roots $r, r, s, t$. Using Vieta's on the coefficient of the cubic and linear terms, we see that $2 r+s+t=r^{2} s+r^{2} t+2 r s t$. Rearranging gives $2 r(1-s t)=\left(r^{2}-1\right)(s+t)$.
+If $r^{2}-1=0$, then since $r \neq 0$, we require that $1-s t=0$ for the equation to hold. Conversely, if $1-s t=0$, then since $s t=1, s+t=0$ cannot hold for real $s, t$, we require that $r^{2}-1=0$ for the equation to hold. So one valid case is where both these values are zero, so $r^{2}=s t=1$. If $r=\tan y$ (here we stipulate that $0 \leq y<\pi$ ), then either $y=\frac{\pi}{4}$ or $y=\frac{3 \pi}{4}$. In either case, the value of $\tan 2 y$ is undefined. If $r=\tan 2 y$, then we have the possible values $y=\frac{\pi}{8}, \frac{3 \pi}{8}, \frac{5 \pi}{8}, \frac{7 \pi}{8}$. In each of these cases, we must check if $\tan y \tan 3 y=1$. But this is true if $y+3 y=4 y$ is a odd integer multiple of $\frac{\pi}{2}$, which is the case for all such values. If $r=\tan 3 y$, then we must have $\tan y \tan 2 y=1$, so that $3 y$ is an odd integer multiple of $\frac{\pi}{2}$. But then $\tan 3 y$ would be undefined, so none of these values can work.
+Now, we may assume that $r^{2}-1$ and $1-s t$ are both nonzero. Dividing both sides by $\left(r^{2}-1\right)(1-s t)$ and rearranging yields $0=\frac{2 r}{1-r^{2}}+\frac{s+t}{1-s t}$, the tangent addition formula along with the tangent double angle formula. By setting $r$ to be one of $\tan y$, $\tan 2 y$, or $\tan 3 y$, we have one of the following:
+(a) $0=\tan 2 y+\tan 5 y$
+(b) $0=\tan 4 y+\tan 4 y$
+(c) $0=\tan 6 y+\tan 3 y$.
+
+We will find the number of solutions $y$ in the interval $[0, \pi)$. Case 1 yields six multiples of $\frac{\pi}{7}$. Case 2 yields $\tan 4 y=0$, which we can readily check has no solutions. Case 3 yields eight multiples of $\frac{\pi}{9}$. In total, we have $4+6+8=18$ possible values of $y$.
+10. Suppose that there are 16 variables $\left\{a_{i, j}\right\}_{0 \leq i, j \leq 3}$, each of which may be 0 or 1 . For how many settings of the variables $a_{i, j}$ do there exist positive reals $c_{i, j}$ such that the polynomial
+
+$$
+f(x, y)=\sum_{0 \leq i, j \leq 3} a_{i, j} c_{i, j} x^{i} y^{j}
+$$
+
+$(x, y \in \mathbb{R})$ is bounded below?
+Answer: 126 For some choices of the $a_{i, j}$, let $S=\left\{(i, j) \mid a_{i, j}=1\right\}$, and let $S^{\prime}=S \cup\{(0,0)\}$. Let $C\left(S^{\prime}\right)$ denote the convex hull of $S^{\prime}$. We claim that there exist the problem conditions are satisfied (there exist positive coefficients for the terms so that the polynomial is bounded below) if and only if the vertices of $C\left(S^{\prime}\right)$ all have both coordinates even.
+For one direction, suppose that $C\left(S^{\prime}\right)$ has a vertex $v=\left(i^{\prime}, j^{\prime}\right)$ with at least one odd coordinate; WLOG, suppose it is $i^{\prime}$. Since $v$ is a vertex, it maximizes some objective function $a i+b j$ over $C\left(S^{\prime}\right)$ uniquely, and thus also over $S^{\prime}$. Since $(0,0) \in S^{\prime}$, we must have $a i^{\prime}+b j^{\prime}>0$. Now consider plugging in $(x, y)=\left(-t^{a}, t^{b}\right)(t>0)$ into $f$. This gives the value
+
+$$
+f\left(-t^{a}, t^{b}\right)=\sum_{(i, j) \in S}(-1)^{i} c_{i, j} t^{a i+b j}
+$$
+
+But no matter what positive $c_{i, j}$ we choose, this expression is not bounded below as $t$ grows infinitely large, as there is a $-c_{i^{\prime}, j^{\prime}} t^{a i^{\prime}+b j^{\prime}}$ term, with $a i^{\prime}+b j^{\prime}>0$, and all other terms have smaller powers of $t$. So the polynomial cannot be bounded below.
+For the other direction, suppose the vertices of $C\left(S^{\prime}\right)$ all have both coordinates even. If all points in $S^{\prime}$ are vertices of $C\left(S^{\prime}\right)$, then the polynomial is a sum of squares, so it is bounded below. Otherwise, we assume that some points in $S^{\prime}$ are not vertices of $C\left(S^{\prime}\right)$. It suffices to consider the case where there is exactly one such point. Call this point $w=\left(i^{\prime}, j^{\prime}\right)$. Let $V\left(S^{\prime}\right)$ denote the set of the vertices of $C\left(S^{\prime}\right)$, and let $n=\left|V\left(S^{\prime}\right)\right|$. Enumerate the points of $V\left(S^{\prime}\right)$ as $v_{1}, v_{2}, \ldots, v_{n}$. Let $i_{k}, j_{k}$ denote the $i$ and $j$ coordinates of $v_{k}$, respectively.
+Since $w \in C\left(S^{\prime}\right)$, there exist nonnegative constants $\lambda_{1}, \lambda_{2}, \ldots, \lambda_{n}$ such that $\sum_{k=1}^{n} \lambda_{k}=1$ and $\sum_{k=1}^{n} \lambda_{k} v_{k}=$ $w$. (Here, we are treating the ordered pairs as vectors.) Then, by weighted AM-GM, we have
+
+$$
+\sum_{k=1}^{n} \lambda_{k}|x|^{i_{k}}|y|^{j_{k}} \geq|x|^{i^{\prime}}|y|^{j^{\prime}}
+$$
+
+Let $c$ be the $\lambda$-value associated with $(0,0)$. Then by picking $c_{i_{k}, j_{k}}=\lambda_{k}$ and $c_{i^{\prime}, j^{\prime}}=1$, we find that $p(x, y) \geq-c$ for all $x, y$, as desired.
+We now find all possible convex hulls $C\left(S^{\prime}\right)$ (with vertices chosen from $(0,0),(0,2),(2,0)$, and $(2,2)$ ), and for each convex hull, determine how many possible settings of $a_{i, j}$ give that convex hull. There are 8 such possible convex hulls: the point $(0,0)$ only, 3 lines, 3 triangles, and the square. The point has 2 possible choices, each line has 4 possible choices, each triangle has 16 possible choices, and the square has 64 possible choices, giving $2+3 \cdot 4+3 \cdot 16+64=126$ total choices.
+
diff --git a/HarvardMIT/md/en-152-2012-feb-comb-solutions.md b/HarvardMIT/md/en-152-2012-feb-comb-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..cbe22cd3aef0c1aacae1c8fcfabdd7d8f3d0ff6d
--- /dev/null
+++ b/HarvardMIT/md/en-152-2012-feb-comb-solutions.md
@@ -0,0 +1,114 @@
+## $15^{\text {th }}$ Annual Harvard-MIT Mathematics Tournament Saturday 11 February 2012
Combinatorics Test
+
+1. In the game of Minesweeper, a number on a square denotes the number of mines that share at least one vertex with that square. A square with a number may not have a mine, and the blank squares are undetermined. How many ways can the mines be placed in this configuration?
+
+| | | | | | |
+| :--- | :--- | :--- | :--- | :--- | :--- |
+| | 2 | | 1 | | 2 |
+| | | | | | |
+
+Answer: 95 Let $A$ be the number of mines in the first two columns. Let $B, C, D, E$ be the number of mines in the third, fourth, fifth, and sixth columns, respectively. We need to have $A+B=2$, $B+C+D=1$, and $D+E=2$. This can happen in three ways, which are $(A, B, C, D, E)=$ $(2,0,1,0,2),(2,0,0,1,1),(1,1,0,0,2)$. This gives $(10)(2)(1)+(10)(3)(2)+(5)(3)(1)=95$ possible configurations.
+2. Brian has a 20 -sided die with faces numbered from 1 to 20 , and George has three 6 -sided dice with faces numbered from 1 to 6 . Brian and George simultaneously roll all their dice. What is the probability that the number on Brian's die is larger than the sum of the numbers on George's dice?
+
+Answer: $\frac{19}{40}$ Let Brian's roll be $d$ and let George's rolls be $x, y, z$. By pairing the situation $d, x, y, z$ with $21-\overline{d, 7}-x, 7-y, 7-z$, we see that the probability that Brian rolls higher is the same as the probability that George rolls higher. Given any of George's rolls $x, y, z$, there is exactly one number Brian can roll which will make them tie, so the probability that they tie is $\frac{1}{20}$. So the probability that Brian wins is $\frac{1-\frac{1}{20}}{2}=\frac{19}{40}$.
+3. In the figure below, how many ways are there to select 5 bricks, one in each row, such that any two bricks in adjacent rows are adjacent?
+
+
+Answer: 61 The number of valid selections is equal to the number of paths which start at a top brick and end at a bottom brick. We compute these by writing 1 in each of the top bricks and letting lower bricks be the sum of the one or two bricks above them. Thus, the number inside each brick is the number of paths from that brick to the top. The bottom row is $6,14,16,15,10$, which sums to 61.
+
+| 1 | 2 | | 1 | | 1 | 1 | | 1 | |
+| :---: | :---: | :---: | :---: | :---: | :---: | :---: | :---: | :---: | :---: |
+| | | 2 | | 2 | | 2 | | 1 | |
+| 2 | - | | 4 | 4 | | 4 | 3 | | |
+| | 6 | 8 | 8 | 8 | 8 | | 7 | 3 | , |
+| 6 | | | 16 | 6 | | | | 0 | |
+
+4. A frog is at the point $(0,0)$. Every second, he can jump one unit either up or right. He can only move to points $(x, y)$ where $x$ and $y$ are not both odd. How many ways can he get to the point $(8,14)$ ?
+
+Answer: 330 When the frog is at a point $(x, y)$ where $x$ and $y$ are both even, then if that frog chooses to move right, his next move will also have to be a step right; similarly, if he moves up, his next move will have to be up.
+If we "collapse" each double step into one step, the problem simply becomes how many ways are there to move to the point $(4,7)$ using only right and up steps, with no other restrictions. That is 11 steps total, so the answer is $\binom{11}{4}=330$.
+5. Dizzy Daisy is standing on the point $(0,0)$ on the $x y$-plane and is trying to get to the point $(6,6)$. She starts facing rightward and takes a step 1 unit forward. On each subsequent second, she either takes a step 1 unit forward or turns 90 degrees counterclockwise then takes a step 1 unit forward. She may never go on a point outside the square defined by $|x| \leq 6,|y| \leq 6$, nor may she ever go on the same point twice. How many different paths may Daisy take?
+Answer: 131922 Because Daisy can only turn in one direction and never goes to the same square twice, we see that she must travel in an increasing spiral about the origin. Clearly, she must arrive at $(6,6)$ coming from below. To count her paths, it therefore suffices to consider the horizontal and vertical lines along which she travels (out of 5 choices to move upward, 6 choices leftward, 6 choices downward, and 6 choices rightward). Breaking up the cases by the number of complete rotations she performs, the total is $\binom{5}{0}\binom{6}{0}^{3}+\binom{5}{1}\binom{6}{1}^{3}+\binom{5}{2}\binom{6}{2}^{3}+\binom{5}{3}\binom{6}{3}^{3}+\binom{5}{4}\binom{6}{4}^{3}+\binom{5}{5}\binom{6}{5}^{3}=131922$.
+6. For a permutation $\sigma$ of $1,2, \ldots, 7$, a transposition is a swapping of two elements. (For instance, we could apply a transposition to the permutation $3,7,1,4,5,6,2$ and get $3,7,6,4,5,1,2$ by swapping the 1 and the 6.)
+Let $f(\sigma)$ be the minimum number of transpositions necessary to turn $\sigma$ into the permutation $1,2,3,4,5,6,7$. Find the sum of $f(\sigma)$ over all permutations $\sigma$ of $1,2, \ldots, 7$.
+Answer: 22212 To solve this problem, we use the idea of a cycle in a permutation. If $\sigma$ is a permutation, we say that $\left(a_{1} a_{2} \cdots a_{k}\right)$ is a cycle if $\sigma\left(a_{i}\right)=\sigma\left(a_{i+1}\right)$ for $1 \leq i \leq k-1$ and $\sigma\left(a_{k}\right)=a_{1}$. Any permutation can be decomposed into disjoint cycles; for instance, the permutation $3,7,6,4,5,1,2$, can be written as $(136)(27)(4)(5)$. For a permutation $\sigma$, let $g(\sigma)$ be the number of cycles in its cycle decomposition. (This includes single-element cycles.)
+Claim. For any permutation $\sigma$ on $n$ elements, $f(\sigma)=n-g(\sigma)$.
+Proof. Given a cycle ( $a_{1} a_{2} \cdots a_{k}$ ) (with $k \geq 2$ ) of a permutation $\sigma$, we can turn this cycle into the identity permutation with $k-1$ transpositions; first we swap $a_{1}$ and $a_{2}$; that is, we replace $\sigma$ with a permutation $\sigma^{\prime}$ such that instead of $\sigma\left(a_{k}\right)=a_{1}$ and $\sigma\left(a_{1}\right)=a_{2}$, we have $\sigma^{\prime}\left(a_{k}\right)=a_{2}$ and $\sigma^{\prime}\left(a_{1}\right)=a_{1}$. Now, $\sigma^{\prime}$ takes $a_{1}$ to itself, so we are left with the cycle $\left(a_{2} \cdots a_{n}\right)$. We continue until the entire cycle is replaced by the identity, which takes $k-1$ transpositions. Now, for any $\sigma$, we resolve each cycle in this way, making a total of $n-g(\sigma)$ transpositions, to turn $\sigma$ into the identity permutation.
+This shows that $n-g(\sigma)$ transpositions; now let us that we cannot do it in less. We show that whenever we make a transposition, the value of $n-g(\sigma)$ can never decrease by more than 1 . Whenever we swap two elements, if they are in different cycles, then those two cycles merge into one; thus $n-g(\sigma)$ actually increased. If the two elements are in one cycle, then the one cycle splits into two cycles, so $n-g(\sigma)$ decreased by only one, and this proves the claim.
+Thus, we want to find
+
+$$
+\sum_{\sigma \in S_{7}}(7-g(\sigma))=7 \cdot 7!-\sum_{\sigma \in S_{7}} g(\sigma)
+$$
+
+to evaluate the sum, we instead sum over every cycle the number of permutations it appears in. For any $1 \leq k \leq 7$, the number of cycles of size $k$ is $\frac{n!}{(n-k)!k}$, and the number of permutations each such cycle can appear in is $(n-k)$ !. Thus we get that the answer is
+
+$$
+7 \cdot 7!-\sum_{k=1}^{7} \frac{7!}{k}=22212
+$$
+
+7. You are repeatedly flipping a fair coin. What is the expected number of flips until the first time that your previous 2012 flips are 'HTHT...HT'?
+Answer: $\left(2^{2014}-4\right) / 3$ Let $S$ be our string, and let $f(n)$ be the number of binary strings of length $n$ which do not contain $S$. Let $g(n)$ be the number of strings of length $n$ which contain $S$ but whose prefix of length $n-1$ does not contain $S$ (so it contains $S$ for the "first" time at time $n$ ).
+Consider any string of length $n$ which does not contain $S$ and append $S$ to it. Now, this new string contains $S$, and in fact it must contain $S$ for the first time at either time $n+2, n+4, \ldots$, or $n+2012$. It's then easy to deduce the relation
+
+$$
+f(n)=g(n+2)+g(n+4)+\cdots+g(n+2012)
+$$
+
+Now, let's translate this into a statement about probabilities. Let $t$ be the first time our sequence of coin flips contains the string $S$. Dividing both sides by $2^{n}$, our equality becomes
+
+$$
+P(t>n)=4 P(t=n+2)+16 P(t=n+4)+\cdots+2^{2012} P(t=n+2012)
+$$
+
+Summing this over all $n$ from 0 to $\infty$, we get
+
+$$
+\sum P(t>n)=4+16+\cdots+2^{2012}=\left(2^{2014}-4\right) / 3
+$$
+
+But it is also easy to show that since $t$ is integer-valued, $\sum P(t>n)=E(t)$, and we are done.
+8. How many ways can one color the squares of a $6 \times 6$ grid red and blue such that the number of red squares in each row and column is exactly 2 ?
+Answer: 67950 Assume the grid is $n \times n$. Let $f(n)$ denote the number of ways to color exactly two squares in each row and column red. So $f(1)=0$ and $f(2)=1$. We note that coloring two squares red in each row and column partitions the set $1,2, \ldots, n$ into cycles such that $i$ is in the same cycle as, and adjacent to, $j$ iff column $i$ and column $j$ have a red square in the same row. Each $i$ is adjacent to two other, (or the same one twice in a 2 -cycle).
+Now consider the cycle containing 1, and let it have size $k$. There are $\binom{n}{2}$ ways to color two squares red in the first column. Now we let the column that is red in the same row as the top ball in the first column, be the next number in the cycle. There are $n-1$ ways to pick this column, and $n-2$ ways to pick the second red square in this column (unless $k=2$ ). Then there are $(n-2)(n-3)$ ways to pick the red squares in the third column. and $(n-j)(n-j+1)$ ways to pick the $j$ th ones for $j \leq k-1$. Then when we pick the $k$ th column, the last one in the cycle, it has to be red in the same row as the second red square in column 1 , so there are just $n-k+1$ choices. Therefore if the cycle has length $k$ there are
+$\frac{n(n-1)}{2} \times(n-1)(n-2) \times \ldots \times(n-k+1)(n-k+2) \times(n-k+1)$ ways, which equals: $\frac{n!(n-1)!}{2(n-k)!(n-k)!}$.
+Summing over the size of the cycle containing the first column, we get
+
+$$
+\begin{gathered}
+f(n)=\sum_{k=2}^{n} \frac{1}{2} f(n-k) \frac{(n)!(n-1)!}{(n-k)!(n-k)!} \\
+\frac{2 n f(n)}{n!n!}=\sum_{k=2}^{n} \frac{f(n-k)}{(n-k)!(n-k)!} \\
+\frac{2 n f(n)}{n!n!}-\frac{2(n-1) f(n-1)}{(n-1)!(n-1)!}=\frac{f(n-2)}{(n-2)!(n-2)!}
+\end{gathered}
+$$
+
+We thus obtain the recursion:
+
+$$
+f(n)=n(n-1) f(n-1)+\frac{n(n-1)^{2}}{2} f(n-2)
+$$
+
+Then we get:
+
+$$
+\begin{aligned}
+& f(1)=0 \\
+& f(2)=1 \\
+& f(3)=6 \\
+& f(4)=12 \times 6+18=90 \\
+& f(5)=20 \times 90+40 \times 6=2040 \\
+& f(6)=30 \times 2040+75 \times 90=67950
+\end{aligned}
+$$
+
+9. A parking lot consists of 2012 parking spots equally spaced in a line, numbered 1 through 2012. One by one, 2012 cars park in these spots under the following procedure: the first car picks from the 2012 spots uniformly randomly, and each following car picks uniformly randomly among all possible choices which maximize the minimal distance from an already parked car. What is the probability that the last car to park must choose spot 1 ?
+Answer: $\frac{1}{2062300}$ We see that for 1 to be the last spot, 2 must be picked first (with probability $\frac{1}{n}$ ), after which spot $n$ is picked. Then, cars from 3 to $n-1$ will be picked until there are only gaps of 1 or 2 remaining. At this point, each of the remaining spots (including spot 1) is picked uniformly at random, so the probability that spot 1 is chosen last here will be the reciprocal of the number of remaining slots.
+Let $f(n)$ denote the number of empty spots that will be left if cars park in $n+2$ consecutive spots whose ends are occupied, under the same conditions, except that the process stops when a car is forced to park immediately next to a car. We want to find the value of $f(2009)$. Given the gap of $n$ cars, after placing a car, there are gaps of $f\left(\left\lfloor\frac{n-1}{2}\right\rfloor\right)$ and $f\left(\left\lceil\frac{n-1}{2}\right\rceil\right)$ remaining. Thus, $f(n)=$ $f\left(\left\lfloor\frac{n-1}{2}\right\rfloor\right)+f\left(\left\lceil\frac{n-1}{2}\right\rceil\right)$. With the base cases $f(1)=1, f(2)=2$, we can determine with induction that $f(x)= \begin{cases}x-2^{n-1}+1 & \text { if } 2^{n} \leq x \leq \frac{3}{2} \cdot 2^{n}-2, \\ 2^{n} & \text { if } \frac{3}{2} \cdot 2^{n}-1 \leq x \leq 2 \cdot 2^{n}-1 .\end{cases}$
+Thus, $f(2009)=1024$, so the total probability is $\frac{1}{2012} \cdot \frac{1}{1024+1}=\frac{1}{2062300}$.
+10. Jacob starts with some complex number $x_{0}$ other than 0 or 1 . He repeatedly flips a fair coin. If the $n^{\text {th }}$ flip lands heads, he lets $x_{n}=1-x_{n-1}$, and if it lands tails he lets $x_{n}=\frac{1}{x_{n-1}}$. Over all possible choices of $x_{0}$, what are all possible values of the probability that $x_{2012}=x_{0}$ ?
+Answer: $1, \frac{2^{2011}+1}{3 \cdot 2^{2011}}$ Let $f(x)=1-x, g(x)=\frac{1}{x}$. Then for any $x, f(f(x))=x$ and $g(g(x))=x$. Furthermore, $f(g(x))=1-\frac{1}{x}, g(f(g(x)))=\frac{x}{x-1}, f(g(f(g(x))))=\frac{1}{1-x}, g(f(g(f(g(x)))))=1-x=$ $f(x)$, so for all $n, x_{n}$ is one of $x, \frac{1}{x}, 1-\frac{1}{x}, \frac{x}{x-1}, \frac{1}{1-x}, 1-x$, and we can understand the coin flipping procedure as moving either left or right with equal probability along this cycle of values.
+For most $x$, all six of these values are distinct. In this case, suppose that we move right $R$ times and left $2012-R$ times between $x_{0}$ and $x_{2012}$. For $x_{2012}=x_{0}$, we need to have that $R-2012+R \equiv 0(\bmod 6)$, or $R \equiv 1(\bmod 3)$. The number of possible ways to return to $x_{0}$ is then $a=\binom{2012}{1}+\binom{2012}{4}+\cdots+\binom{2012}{2011}$. Let $b=\binom{2012}{0}+\binom{2012}{3}+\cdots+\binom{2012}{2010}=\binom{2012}{2}+\binom{2012}{5}+\cdots+\binom{2012}{2012}$. Then we have $a+2 b=2^{2012}$ and that $b=\frac{(1+1)^{2012}+(1+\omega)^{2012}+\left(1+\omega^{2}\right)^{2012}}{3}$, where $\omega$ is a primitive third root of unity. It can be seen that $1+\omega$ is a primitive sixth root of unity and $1+\omega^{2}$ is its inverse, so $(1+\omega)^{2012}=(1+\omega)^{2}=\omega$, and similarly $\left(1+\omega^{2}\right)^{2012}=\omega^{2}$. Therefore, $b=\frac{2^{2012}-1}{3}$, so $a=2^{2012}-2 b=\frac{2^{2012}+2}{3}$, and our desired probability is then $\frac{a}{2^{2012}}=\frac{2^{2012}+2}{3 \cdot 2^{2012}}=\frac{2^{2011}+1}{3 \cdot 2^{2011}}$.
+For some $x_{0}$, however, the cycle of values can become degenerate. It could be the case that two adjacent values are equal. Let $y$ be a value that is equal to an adjacent value. Then $y=\frac{1}{y}$ or $y=1-y$, which gives $y \in\left\{-1, \frac{1}{2}\right\}$. Therefore, this only occurs in the cycle of values $-1,2, \frac{1}{2}, \frac{1}{2}, 2,-1$. In this case, note that after 2012 steps we will always end up an even number of steps away from our starting point, and each of the numbers occupies two spaces of opposite parity, so we would need to return to our
+original location, just as if all six numbers were distinct. Therefore in this case we again have that the probability that $x_{2012}=x_{0}$ is $\frac{2^{2011}+1}{3 \cdot 2^{2011}}$.
+It is also possible that two numbers two apart on the cycle are equal. For this to be the case, let $y$ be the value such that $f(g(y))=y$. Then $1-\frac{1}{x}=x$, or $x-1=x^{2}$, so $x=\frac{1 \pm i \sqrt{3}}{2}$. Let $\zeta=\frac{1+i \sqrt{3}}{2}$. Then we get that the cycle of values is $\zeta, \bar{\zeta}, \zeta, \bar{\zeta}, \zeta, \bar{\zeta}$, and since at the end we are always an even number of spaces away from our starting location, the probability that $x_{2012}=x_{0}$ is 1 .
+Finally, we need to consider the possibility that two opposite numbers are equal. In this case we have a $y$ such that $f(g(f(y)))=y$, or $\frac{x}{x-1}=x$, so $x=2$. In this case we obtain the same cycle of numbers in the case where two adjacent numbers are equal, and so we again obtain the probability $\frac{2^{2011}+1}{3 \cdot 2^{2011}}$. Therefore, the only possibilities are $1, \frac{2^{2011}+1}{3 \cdot 2^{2011}}$.
diff --git a/HarvardMIT/md/en-152-2012-feb-geo-solutions.md b/HarvardMIT/md/en-152-2012-feb-geo-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..5d6bcfa982db3edf4fddc6479e77d3ec9665645a
--- /dev/null
+++ b/HarvardMIT/md/en-152-2012-feb-geo-solutions.md
@@ -0,0 +1,70 @@
+## $15^{\text {th }}$ Annual Harvard-MIT Mathematics Tournament Saturday 11 February 2012
Geometry Test
+
+1. $A B C$ is an isosceles triangle with $A B=2$ and $\measuredangle A B C=90^{\circ} . D$ is the midpoint of $B C$ and $E$ is on $A C$ such that the area of $A E D B$ is twice the area of $E C D$. Find the length of $D E$.
+Answer: $\frac{\sqrt{17}}{3}$ Let $F$ be the foot of the perpendicular from $E$ to $B C$. We have $[A E D B]+[E D C]=$ $[A B C]=2 \Rightarrow[E D C]=\frac{2}{3}$. Since we also have $[E D C]=\frac{1}{2}(E F)(D C)$, we get $E F=F C=\frac{4}{3}$. So $F D=\frac{1}{3}$, and $E D=\frac{\sqrt{17}}{3}$ by the Pythagorean Theorem.
+2. Let $A B C$ be a triangle with $\angle A=90^{\circ}, A B=1$, and $A C=2$. Let $\ell$ be a line through $A$ perpendicular to $B C$, and let the perpendicular bisectors of $A B$ and $A C$ meet $\ell$ at $E$ and $F$, respectively. Find the length of segment $E F$.
+Answer: $\frac{3 \sqrt{5}}{4}$ Let $M, N$ be the midpoints of $A B$ and $A C$, respectively. Then we have $\angle E A B=$ $\angle A C B$ and $\angle E A C=\angle A B C$, so $A E M \sim C B A \Rightarrow A E=\frac{\sqrt{5}}{4}$ and $F A N \sim C B A \Rightarrow A F=\sqrt{5}$. Consequently, $E F=A F-A E=\frac{3 \sqrt{5}}{4}$.
+3. Let $A B C$ be a triangle with incenter $I$. Let the circle centered at $B$ and passing through $I$ intersect side $A B$ at $D$ and let the circle centered at $C$ passing through $I$ intersect side $A C$ at $E$. Suppose $D E$ is the perpendicular bisector of $A I$. What are all possible measures of angle $B A C$ in degrees?
+Answer: $\sqrt{\frac{540}{7}}$ Let $\alpha=\measuredangle B A C . D E$ is the perpendicular bisector of $A I$, so $D A=D I$, and $\angle D I A=\angle \overline{D A I}=\alpha / 2$. Thus, $\angle I D B=\angle D I B=\alpha$, since $B D=B I$. This gives $\angle D B I=180^{\circ}-2 \alpha$, so that $\angle A B C=360^{\circ}-4 \alpha$. Similarly, $\angle A C B=360^{\circ}-4 \alpha$. Now, summing the angles in $A B C$, we find $720^{\circ}-7 \alpha=180^{\circ}$, so that $\alpha=\frac{540^{\circ}}{7}$.
+4. There are circles $\omega_{1}$ and $\omega_{2}$. They intersect in two points, one of which is the point $A$. $B$ lies on $\omega_{1}$ such that $A B$ is tangent to $\omega_{2}$. The tangent to $\omega_{1}$ at $B$ intersects $\omega_{2}$ at $C$ and $D$, where $D$ is the closer to $B$. $A D$ intersects $\omega_{1}$ again at $E$. If $B D=3$ and $C D=13$, find $E B / E D$.
+Answer: $4 \sqrt{3} / 3$
+
+> [diagram]
+
+By power of a point, $B A=\sqrt{B D \cdot B C}=4 \sqrt{3}$. Also, $D E B \sim D B A$, so $E B / E D=B A / B D=4 \sqrt{3} / 3$.
+5. A mouse lives in a circular cage with completely reflective walls. At the edge of this cage, a small flashlight with vertex on the circle whose beam forms an angle of $15^{\circ}$ is centered at an angle of $37.5^{\circ}$ away from the center. The mouse will die in the dark. What fraction of the total area of the cage can keep the mouse alive?
+
+
+Geometry Test
+
+Answer: | $\frac{3}{4}$ |
+| :---: |
+| We claim that the lit region is the entire cage except for a circle of half the radius | of the cage in the center, along with some isolated points on the boundary of the circle and possibly minus a set of area 0 . Note that the region is the same except for a set of area 0 if we disallow the light paths at the very edge of the beam. In that case, we can see that the lit region is an open subset of the disk, as clearly the region after $k$ bounces is open for each $k$ and the union of open sets is again open. We will then show that a dense subset of the claimed region of the cage is lit.
+
+First, let us show that no part of the inner circle is lit. For any given light path, each chord of the circle is the same length, and in particular the minimum distance from the center of the circle is the same on each chord of the path. Since none of the initial chords can come closer than half the cage's radius to the center, the circle with half the cage's radius is indeed dark.
+Now we need to show that for each open subset of the outer region, there is a light path passing through it, which will imply that the unlit region outside the small circle contains no open set, and thus has area 0 . To do this, simply consider a light path whose angle away from the center is irrational such that the distance $d$ from the center of the cage to the midpoint of the first chord is sufficiently close to the distance from the center of the cage to a point in the open set we're considering. Each successive chord of the light path can be seen as a rotation of the original one, and since at each step it is translated by an irrational angle, we obtain a dense subset of all the possible chords. This means that we obtain a dense subset of the circumference of the circle of radius $d$ centered at the center of the cage, and in particular a point inside the open set under consideration, as desired.
+Therefore, the lit region of the cage is the area outside the concentric circle of half the radius plus or minus some regions of area 0 , which tells us that $\frac{3}{4}$ of the cage is lit.
+6. Triangle $A B C$ is an equilateral triangle with side length 1 . Let $X_{0}, X_{1}, \ldots$ be an infinite sequence of points such that the following conditions hold:
+
+- $X_{0}$ is the center of $A B C$
+- For all $i \geq 0, X_{2 i+1}$ lies on segment $A B$ and $X_{2 i+2}$ lies on segment $A C$.
+- For all $i \geq 0, \measuredangle X_{i} X_{i+1} X_{i+2}=90^{\circ}$.
+- For all $i \geq 1, X_{i+2}$ lies in triangle $A X_{i} X_{i+1}$.
+
+Find the maximum possible value of $\sum_{i=0}^{\infty}\left|X_{i} X_{i+1}\right|$, where $|P Q|$ is the length of line segment $P Q$.
+Answer: $\sqrt{\frac{\sqrt{6}}{3}}$ Let $Y$ be the foot of the perpendicular from $A$ to $X_{0} X_{1}$ : note that the sum we wish to minimize is simply $X_{0} Y+Y A$. However, it is not difficult to check (for example, by AMGM) that $A Y+Y X_{0} \geq \sqrt{2} A X_{0}=\sqrt{6} / 3$. This may be achieved by making $\angle Y X_{0} A=45^{\circ}$, so that $\angle A X_{1} X_{0}=105^{\circ}$.
+7. Let $S$ be the set of the points $\left(x_{1}, x_{2}, \ldots, x_{2012}\right)$ in 2012-dimensional space such that $\left|x_{1}\right|+\left|x_{2}\right|+\cdots+$ $\left|x_{2012}\right| \leq 1$. Let $T$ be the set of points in 2012-dimensional space such that $\max _{i=1}^{2012}\left|x_{i}\right|=2$. Let $p$ be a randomly chosen point on $T$. What is the probability that the closest point in $S$ to $p$ is a vertex of $S$ ?
+Answer: $\frac{1}{2^{2011}}$ Note that $T$ is a hypercube in 2012-dimensional space, containing the rotated hyperoctahedron $S$. Let $v$ be a particular vertex of $S$, and we will consider the set of points $x$ on $T$ such that $v$ is the closest point to $x$ in $S$. Let $w$ be another point of $S$ and let $\ell$ be the line between $v$ and $w$. Then in order for $v$ to be the closest point to $x$ in $S$, it must also be so on the region of $\ell$ contained in $S$. This condition is then equivalent to the projection of $x$ lying past $v$ on the line $\ell$, or alternatively that $v$ lies in the opposite halfspace of $w$ defined by the hyperplane perpendicular to $\ell$ and passing through $v$. This can be written algebraically as $(x-v) \cdot(w-v) \leq 0$. Therefore, $v$ is the closest point to $x$ if and only if $(x-v) \cdot(w-v) \leq 0$ for all $w$ in $S$.
+Note that these conditions do not depend on where $w$ is on the line, so for each line intersecting $S$ nontrivially, let us choose $w$ such that $w$ lies on the hyperplane $H$ containing all the vertices of $S$ except for $v$ and $-v$. We can further see that the conditions are linear in $w$, so them holding for all $w$
+in $H$ is equivalent to them holding on the vertices of the region $S \cap H$, which are simply the vertices of $S$ except for $v$ and $-v$. Let us now compute what these conditions look like.
+Without loss of generality, let $v=(1,0, \ldots, 0)$ and $w=(0,1,0, \ldots, 0)$. Then the equation is of the form $(x-v) \cdot(-1,1,0, \ldots, 0) \leq 0$, which we can rewrite as $\left(x_{1}-1, x_{2}, x_{3}, \ldots, x_{2} 012\right) \cdot(-1,1,0, \ldots, 0)=$ $1-x_{1}+x_{2} \leq 0$. For the other choices of $w$, we get the similar conditions that $1-x_{1}+x_{i} \leq 0$ and also $1-x_{1}-x_{i} \leq 0$ for each $i \in\{2, \ldots, 2012\}$. Note that if any $x_{i} \in\{2,-2\}$ for $i \neq 1$, then one of these conditions trivially fails, as it would require $3-x_{1} \leq 0$. Therefore, the only face of $T$ where $x$ can lie is the face defined by $x_{1}=2$, which gives us the conditions that $-1+x_{i} \leq 0$ and $-1-x_{i} \leq 0$, so $x_{i} \in[-1,1]$ for all $i \in\{2, \ldots, 2012\}$. This defines a 2011-dimensional hypercube of side length 2 on the face of $T$ defined by $x_{1}=2$, and we obtain similar regions on each of the other faces corresponding to the other vertices of $S$. Therefore, the volume of the set of $x$ for which $x$ is closest to a vertex is $2 \cdot 2012 \cdot 2^{2011}$ and the volume of all the choices of $x$ is $2 \cdot 2012 \cdot 4^{2011}$, so the desired probability is $\frac{1}{2^{2011}}$.
+8. Hexagon $A B C D E F$ has a circumscribed circle and an inscribed circle. If $A B=9, B C=6, C D=2$, and $E F=4$. Find $\{D E, F A\}$.
+Answer: $\left\{\frac{9+\sqrt{33}}{2}, \frac{9-\sqrt{33}}{2}\right\}$ By Brianchon's Theorem, $A D, B E, C F$ concur at some point $P$. Also, it follows from the fact that tangents from a point to a circle have equal lengths that $A B+C D+E F=$ $B C+D E+F A$. Let $D E=x$, so that $F A=9-x$.
+Note that $A P B \sim E P D, B P C \sim F P E$, and $C P D \sim A P F$. The second similarty gives $B P / F P=3 / 2$, so that $B P=3 y, F P=2 y$ for some $y$. From here, the first similarity gives $D P=x y / 3$. Now, the third similarity gives $4 y=\frac{(9-x) x y}{3}$, so that $x^{2}-9 x+12=0$. It follows that $x=\frac{9 \pm \sqrt{33}}{2}$, giving our answer.
+9. Let $O, O_{1}, O_{2}, O_{3}, O_{4}$ be points such that $O_{1}, O, O_{3}$ and $O_{2}, O, O_{4}$ are collinear in that order, $O O_{1}=$ $1, O O_{2}=2, O O_{3}=\sqrt{2}, O O_{4}=2$, and $\measuredangle O_{1} O O_{2}=45^{\circ}$. Let $\omega_{1}, \omega_{2}, \omega_{3}, \omega_{4}$ be the circles with respective centers $O_{1}, O_{2}, O_{3}, O_{4}$ that go through $O$. Let $A$ be the intersection of $\omega_{1}$ and $\omega_{2}, B$ be the intersection of $\omega_{2}$ and $\omega_{3}, C$ be the intersection of $\omega_{3}$ and $\omega_{4}$, and $D$ be the intersection of $\omega_{4}$ and $\omega_{1}$, with $A, B, C, D$ all distinct from $O$. What is the largest possible area of a convex quadrilateral $P_{1} P_{2} P_{3} P_{4}$ such that $P_{i}$ lies on $O_{i}$ and that $A, B, C, D$ all lie on its perimeter?
+Answer: $8+4 \sqrt{2}$ We first maximize the area of triangle $P_{1} O P_{2}$, noting that the sum of the area of $P_{1} O P_{2}$ and the three other analogous triangles is the area of $P_{1} P_{2} P_{3} P_{4}$. Note that if $A \neq P_{1}, P_{2}$, without loss of generality say $\angle O A P_{1}<90^{\circ}$. Then, $\angle O O_{1} P_{1}=2 \angle O A P_{1}$, and since $\angle O A P_{2}=180^{\circ}-\angle O A P_{1}>$ $90^{\circ}$, we see that $\angle O O_{2} P_{2}=2 \angle O A P_{1}$ as well, and it follows that $O O_{1} P_{1} \sim O O_{2} P_{2}$. This is a spiral similarity, so $O O_{1} O_{2} \sim O P_{1} P_{2}$, and in particular $\angle P_{1} O P_{2}=\angle O_{1} O O_{2}$, which is fixed. By the sine area formula, to maximize $O P_{1} \cdot O P_{2}$, which is bounded above by the diameters $2\left(O O_{1}\right), 2\left(O O_{2}\right)$. In a similar way, we want $P_{3}, P_{4}$ to be diametrically opposite $O_{3}, O_{4}$ in their respective circles.
+When we take these $P_{i}$, we indeed have $A \in P_{1} P_{2}$ and similarly for $B, C, D$, since $\angle O A P_{1}=\angle O A P_{2}=$ $90^{\circ}$. To finish, the area of the quadrilateral is the sum of the areas of the four triangles, which is
+
+$$
+\frac{1}{2} \cdot \frac{\sqrt{2}}{2} \cdot 2^{2} \cdot(1 \cdot 2+2 \cdot \sqrt{2}+\sqrt{2} \cdot 2+2 \cdot 1)=8+4 \sqrt{2} .
+$$
+
+10. Let $C$ denote the set of points $(x, y) \in \mathbb{R}^{2}$ such that $x^{2}+y^{2} \leq 1$. A sequence $A_{i}=\left(x_{i}, y_{i}\right) \mid i \geq 0$ of points in $\mathbb{R}^{2}$ is 'centric' if it satisfies the following properties:
+
+- $A_{0}=\left(x_{0}, y_{0}\right)=(0,0), A_{1}=\left(x_{1}, y_{1}\right)=(1,0)$.
+- For all $n \geq 0$, the circumcenter of triangle $A_{n} A_{n+1} A_{n+2}$ lies in $C$.
+
+Let $K$ be the maximum value of $x_{2012}^{2}+y_{2012}^{2}$ over all centric sequences. Find all points $(x, y)$ such that $x^{2}+y^{2}=K$ and there exists a centric sequence such that $A_{2012}=(x, y)$.
+
+Answer: $(-1006,1006 \sqrt{3}),(-1006,-1006 \sqrt{3})$ Consider any triple of points $\triangle A_{n} A_{n+1} A_{n+2}$ with circumcenter $P_{n}$. By the Triangle Inequality we have $A_{n} P_{n} \leq A_{n} A_{0}+A_{0} P_{n} \leq A_{n} A_{0}+1$. Since $P_{n}$ is the circumcenter, we have $P_{n} A_{n}=P_{n} A_{n+2}$. Finally we have $A_{n+2} a_{0} \leq P_{n} A_{n+2}+1=A_{n} P_{n}+1 \leq A_{n} A_{0}+2$. Therefore $\sqrt{x_{n+2}^{2}+y_{n+2}^{2}} \leq \sqrt{x_{n}^{2}+y_{n}^{2}}+2$.
+It is also clear that equality occurs if and only if $A_{n}, A_{0}, P_{n}, A_{n+2}$ are all collinear and $P_{n}$ lies on the unit circle.
+From the above inequality it is clear that $\sqrt{x_{2012}^{2}+y_{2012}^{2}} \leq 2012$. So the maximum value of $K$ is $2012^{2}$.
+Now we must find all points $A_{2}$ that conforms to the conditions of the equality case. $P_{0}$ must lie on the unit circle, so it lies on the intersection of the unit circle with the perpendicular bisector of $A_{0} A_{1}$, which is the line $x=\frac{1}{2}$. Thus $P_{0}$ must be one of $\left(\frac{1}{2}, \pm \frac{\sqrt{3}}{2}\right)$. From now on we assume that we take the positive root, as the negative root just reflects all successive points about the $x$-axis.
+If $P_{0}=\left(\frac{1}{2}, \frac{\sqrt{3}}{2}\right)$ then $A_{0}, P_{0}, A_{2}$ must be colinear, so $A_{2}=(1, \sqrt{3})$.
+Then since we must have $A_{0}, P_{2 n}, A_{2 n}, A_{2 n+2}$ colinear and $P_{2 n}$ on the unit circle, it follows that $P_{2 n}=(-1)^{n}\left(\frac{1}{2}, \frac{\sqrt{3}}{2}\right)$. Then by induction we have $A_{2 n}=(-1)^{n+1}(n, n \sqrt{3})$. To fill out the rest of the sequence, we may take $A_{2 n+1}=(-1)^{n}(n+1,-n \sqrt{3})$ and $P_{2 n+1}=(-1)^{n+1}\left(\frac{1}{2},-\frac{\sqrt{3}}{2}\right)$ so that we get the needed properties.
+Therefore the answer is
+
+$$
+A_{2012} \in\{(-1006,1006 \sqrt{3}),(-1006,-1006 \sqrt{3})\}
+$$
+
diff --git a/HarvardMIT/md/en-152-2012-feb-guts-solutions.md b/HarvardMIT/md/en-152-2012-feb-guts-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..ad11e6772e4c87633eb44e4a3bffd19f0f8cceb2
--- /dev/null
+++ b/HarvardMIT/md/en-152-2012-feb-guts-solutions.md
@@ -0,0 +1,284 @@
+## $15^{\text {th }}$ Annual Harvard-MIT Mathematics Tournament Saturday 11 February 2012
Guts
+
+1. [2] Square $A B C D$ has side length 2 , and $X$ is a point outside the square such that $A X=X B=\sqrt{2}$. What is the length of the longest diagonal of pentagon $A X B C D$ ?
+Answer: $\sqrt{10}$ Since $A X=X B=\sqrt{2}$ and $A B=2$, we have $\angle A X B=90^{\circ}$. Hence, the distance from $X$ to $A B$ is 1 and the distance from $X$ to $C D$ is 3 . By inspection, the largest diagonals are thus $B X=C X=\sqrt{3^{2}+1^{2}}$.
+2. [2] Let $a_{0}, a_{1}, a_{2}, \ldots$ denote the sequence of real numbers such that $a_{0}=2$ and $a_{n+1}=\frac{a_{n}}{1+a_{n}}$ for $n \geq 0$. Compute $a_{2012}$.
+Answer: $\frac{2}{4025}$ Calculating out the first few terms, note that they follow the pattern $a_{n}=\frac{2}{2 n+1}$. Plugging this back into the recursion shows that it indeed works.
+3. [2] Suppose $x$ and $y$ are real numbers such that $-1
Team B
+
+1. [10] Triangle $A B C$ has $A B=5, B C=3 \sqrt{2}$, and $A C=1$. If the altitude from $B$ to $A C$ and the angle bisector of angle $A$ intersect at at $D$, what is $B D$ ?
+
+Answer: | $\frac{5}{3}$ |
+| :---: |
+| Let $E$ | be the foot of the perpendicular from $B$ to line $A C$. By the Law of Cosines, $\cos \angle B A C=\frac{4}{5}$, and it follows that $B E=3$ and $A E=4$. Now, by the Angle Bisector Theorem, $\frac{B D}{B E}=\frac{A B}{A B+A E}=\frac{5}{9}$, so $B D=\frac{5}{3}$.
+
+2. [10] You are given two line segments of length $2^{n}$ for each integer $0 \leq n \leq 10$. How many distinct nondegenerate triangles can you form with three of the segments? Two triangles are considered distinct if they are not congruent.
+Answer: 55 First, observe that if we have three sticks of distinct lengths $2^{a}<2^{b}<2^{c}$, then $2^{a}+2^{b}<2^{b+1} \leq 2^{c}$, so we cannot form a triangle. Thus, we must have (exactly) two of our sticks the same length, so that our triangle has side lengths $2^{a}, 2^{a}, 2^{b}$. This triangle is non-degenerate if and only if $2^{a+1}>2^{b}$, and since $a \neq b$, this happens if and only if $a>b$. Clearly, there are $\binom{11}{2}=55$ ways to choose such $a, b$.
+3. [10] Mac is trying to fill 2012 barrels with apple cider. He starts with 0 energy. Every minute, he may rest, gaining 1 energy, or if he has $n$ energy, he may expend $k$ energy $(0 \leq k \leq n)$ to fill up to $n(k+1)$ barrels with cider. What is the minimal number of minutes he needs to fill all the barrels?
+Answer: 46 First, suppose that Mac fills barrels during two consecutive minutes. Let his energy immediately before doing so be $n$, and the energy spent in the next two minutes be $k_{1}, k_{2}$, respectively. It is not difficult to check that he can fill at least as many barrels by spending $k_{1}+k_{2}+1$ energy and resting for an additional minute before doing so, so that his starting energy is $n+1$ : this does not change the total amount of time. Furthermore, this does not affect the amount of energy Mac has remaining afterward. We may thus assume that Mac first rests for a (not necessarily fixed) period of time, then spends one minute filling barrels, and repeats this process until all of the barrels are filled.
+Next, we check that he only needs to fill barrels once. Suppose that Mac first rests for $n_{1}$ minutes, then spends $k_{1}$ energy, and next rests for $n_{2}$ minutes and spends $k_{2}$ energy. It is again not difficult to check that Mac can instead rest for $n_{1}+n_{2}+1$ minutes and spend $k_{1}+k_{2}+1$ energy, to increase the number of barrels filled, while not changing the amount of time nor the energy remaining. Iterating this operation, we can reduce our problem to the case in which Mac first rests for $n$ minutes, then spends $n$ energy filling all of the barrels.
+We need $n(n+1) \geq 2012$, so $n \geq 45$, and Mac needs a minimum of 46 minutes.
+4. [10] A restaurant has some number of seats, arranged in a line. Its customers are in parties arranged in a queue. To seat its customers, the restaurant takes the next party in the queue and attempts to seat all of the party's member(s) in a contiguous block of unoccupied seats. If one or more such blocks exist, then the restaurant places the party in an arbitrarily selected block; otherwise, the party leaves.
+
+Suppose the queue has parties of sizes $6,4,2,5,3,1$ from front to back, and all seats are initially empty. What is the minimal number of seats the restaurant needs to guarantee that it will seat all of these customers?
+Answer: 29 First, note that if there are only 28 seats, it is possible for the seating not to be possible, in the following way. The party of six could be seated in such a way that the remaining contiguous regions have sizes 10 and 12 . Then, the party of 4 is seated in the middle of the region of size 12 , and the party of 2 is seated in the middle of the region of size 10 , so that the remaining regions all of size 4 . Now, it is impossible to seat the party of 5 . It is clear that fewer than 28 seats also make it impossible to guarantee that everyone can be seated.
+Now, given 29 seats, clearly, the first party can be seated. Afterward, 23 seats remain in at most 2 contiguous regions, one of which has to have size at least 4 . Next, 19 seats remain in at most 3
+contiguous regions, one of which has size at least 2. 17 seats in at most 4 contiguous regions remain for the party of 5 , and one region must have size at least 5 . Finally, 12 seats in at most 5 contiguous regions are available for the party of 3 , and the party of 1 can take any remaining seat. Our answer is therefore 29.
+Remark: We can arrive at the answer of 29 by doing the above argument in reverse.
+5. [10] Steph and Jeff each start with the number 4, and Travis is flipping a coin. Every time he flips a heads, Steph replaces her number $x$ with $2 x-1$, and Jeff replaces his number $y$ with $y+8$. Every time he flips a tails, Steph replaces her number $x$ with $\frac{x+1}{2}$, and Jeff replaces his number $y$ with $y-3$. After some (positive) number of coin flips, Steph and Jeff miraculously end up with the same number below 2012. How many times was the coin flipped?
+Answer: 137 Suppose that $a$ heads and $b$ tails are flipped. Jeff's number at the end is $4+8 a-3 b$. Note that the operations which Steph applies are inverses of each other, and as a result it is not difficult to check by induction that her final number is simply $1+3 \cdot 2^{a-b}$.
+We now have $3+3(a-b)+5 a=3 \cdot 2^{a-b}$. Letting $n=a-b$, we see that $2^{n}-n-1$ must be divisible by 5 , so that $a$ is an integer. In particular, $n$ is a positive integer. Furthermore, we have $1+3 \cdot 2^{n}<2012$, so that $n \leq 9$. We see that the only possibility is for $n=7=a-b$, and thus $4+8 a-3 b=385$. Solving, we get $a=72, b=65$, so our answer is $72+65=137$.
+6. [20] Let $A B C$ be a triangle with $A B0$, we also have $k>0$, so we know that $k$ must lie in $\left(0, \frac{1+\sqrt{2}}{2}\right]$.
+Now, take any $k$ in the interval $\left(0, \frac{1+\sqrt{2}}{2}\right]$. We thus know that $1^{2} \geq 4 k(k-1)$, so the quadratic $k t^{2}-t+k-1=0$ has a positive solution, $\frac{1+\sqrt{1-4 k(k-1)}}{2 k}$. Call this solution $x$. Then $k\left(x^{2}+1\right)=x+1$, so $\frac{x+1}{x^{2}+1}=k$. If we set $a=x$ and $b=1$, we get that $\frac{a b+b^{2}}{a^{2}+b^{2}}=k$. Thus, the set of all attainable values of $\frac{a b+b^{2}}{a^{2}+b^{2}}$ is the interval $\left(0, \frac{1+\sqrt{2}}{2}\right)$.
+29. [15]
+
+Answer: $-\frac{25+5 \sqrt{17}}{8}$ First, note that $(x+1)(2 x+1)(3 x+1)(4 x+1)=((x+1)(4 x+1))((2 x+1)(3 x+$ $1))=\left(4 x^{2}+5 x+1\right)\left(6 x^{2}+5 x+1\right)=\left(5 x^{2}+5 x+1-x^{2}\right)\left(5 x^{2}+5 x+1+x^{2}\right)=\left(5 x^{2}+5 x+1\right)^{2}-x^{4}$. Therefore, the equation is equivalent to $\left(5 x^{2}+5 x+1\right)^{2}=17 x^{4}$, or $5 x^{2}+5 x+1= \pm \sqrt{17} x^{2}$.
+If $5 x^{2}+5 x+1=\sqrt{17} x^{2}$, then $(5-\sqrt{17}) x^{2}+5 x+1=0$. The discriminant of this is $25-4(5-\sqrt{17})=$ $5+4 \sqrt{17}$, so in this case, there are two real roots and they sum to $-\frac{5}{5-\sqrt{17}}=-\frac{25+5 \sqrt{17}}{8}$.
+If $5 x^{2}+5 x+1=-\sqrt{17} x^{2}$, then $(5+\sqrt{17}) x^{2}+5 x+1=0$. The discriminant of this is $25-4(5+\sqrt{17})=$ $5-4 \sqrt{17}$. This is less than zero, so there are no real solutions in this case. Therefore, the sum of all real solutions to the equation is $-\frac{25+5 \sqrt{17}}{8}$.
+30. [15]
+
+Answer: | $\frac{3}{7}$ |
+| :---: |
+| It suffices to assume that the monkey starts all over as soon as he has typed a string | that ends in no prefix of either $a b c$ or $a a a$. For instance, if the monkey gets to $a b b$ we can throw these out because there's no way to finish one of those strings from this without starting all over.
+
+Now, we draw the tree of all possible intermediate stages under this assumption; there are not many possibilities. The paths from the root "a" are:
+a- aa- aaa
+a- aa- aab- aabc
+a- ab- abc
+The first and last possibilities have probability $1 / 27$ each and the middle one has probability $1 / 81$, so in total the probability of getting the first before the second or the third is $\frac{1 / 27}{1 / 27+1 / 81+1 / 27}=\frac{3}{7}$.
+31. [17]
+
+Answer: $\frac{3 \sqrt{3}}{20}$ We place the points in the coordinate plane. We let $A=\left(0,0, \frac{\sqrt{6}}{3}\right), B=\left(0, \frac{\sqrt{3}}{3}, 0\right)$, $C=\left(-\frac{1}{2},-\frac{\sqrt{3}}{6}, 0\right)$, and $D=\left(\frac{1}{2}, \frac{\sqrt{3}}{6}, 0\right)$. The point $P$ is the origin, while $M$ is $\left(0,0, \frac{\sqrt{6}}{6}\right)$. The line through $B$ and $M$ is the line $x=0, y=\frac{\sqrt{3}}{3}-z \sqrt{2}$. The plane through $A, C$, and $D$ has equation $z=2 \sqrt{2} y+\sqrt{\frac{2}{3}}$. The coordinates of $Q$ are the coordinates of the intersection of this line and this plane. Equating the equations and solving for $y$ and $z$, we see that $y=-\frac{1}{5 \sqrt{3}}$ and $z=\frac{\sqrt{6}}{5}$, so the coordinates of $Q$ are $\left(0,-\frac{1}{5 \sqrt{3}}, \frac{\sqrt{6}}{5}\right)$.
+Let $N$ be the midpoint of $C D$, which has coordinates $\left(0,-\frac{\sqrt{3}}{6}, 0\right)$. By the distance formula, $Q N=\frac{3 \sqrt{3}}{10}$. Thus, the area of $Q C D$ is $\frac{Q N \cdot C D}{2}=\frac{3 \sqrt{3}}{20}$.
+32. [17]
+
+Answer: 2530 Note that $\phi(23)=22$ and $\phi(22)=10$, so if $\operatorname{lcm}(23,22,10)=2530 \mid k$ then $f(n+k) \equiv$ $f(n)(\bmod 23)$ is always true. We show that this is necessary as well.
+Choosing $n \equiv 0(\bmod 23)$, we see that $k \equiv 0(\bmod 23)$. Thus $n+k \equiv n(\bmod 23)$ always, and we can move to the exponent by choosing $n$ to be a generator modulo 23 :
+$(n+k)^{n+k} \equiv n^{n}(\bmod 22)$
+The choice of $n$ here is independent of the choice $(\bmod 23)$ since 22 and 23 are coprime. Thus we must have again that $22 \mid k$, by choosing $n \equiv 0(\bmod 22)$. But then $n+k \equiv n(\bmod 11)$ always, and we can go to the exponent modulo $\phi(11)=10$ by choosing $n$ a generator modulo 11:
+$n+k \equiv n(\bmod 10)$
+From here it follows that $10 \mid k$ as well. Thus $2530 \mid k$ and 2530 is the minimum positive integer desired.
+33. [17]
+
+Answer: $\tan ^{-1}\left(\frac{1009}{1005}\right)$ As per usual with reflection problems instead of bouncing off the sides of a $1 \times 1$ square we imagine the ball to travel in a straight line from origin in an infinite grid of $1 \times 1$ squares, "bouncing" every time it meets a line $x=m$ or $y=n$. Let the lattice point it first meets after leaving the origin be $(a, b)$, so that $b>a$. Note that $a$ and $b$ are coprime, otherwise the ball will reach a vertex before the 2012 th bounce. We wish to minimize the slope of the line to this point from origin, which is $b / a$.
+
+Now, the number of bounces up to this point is $a-1+b-1=a+b-2$, so the given statement is just $a+b=2014$. To minimize $b / a$ with $a$ and $b$ relatively prime, we must have $a=1005, b=1009$, so that the angle is $\tan ^{-1}\left(\frac{1009}{1005}\right)$.
+34. [20]
+
+Answer: 15612 Note that the number of integers between 1 and 2012 that have $n$ as a divisor is $\left\lfloor\frac{2012}{n}\right\rfloor$. Therefore, if we sum over the possible divisors, we see that the sum is equivalent to $\sum_{d=1}^{2012}\left\lfloor\frac{2012}{d}\right\rfloor$. This can be approximated by $\sum_{d=1}^{2012} \frac{2012}{d}=2012 \sum_{d=1}^{2012} \frac{1}{d} \approx 2012 \ln (2012)$. As it turns out, $2012 \ln (2012) \approx 15300$, which is worth 18 points. Using the very rough approximation $\ln (2012) \approx 7$ still gives 14 points.
+35. [20]
+
+Answer: 3.1415875473 The answer is $1006 \sin \frac{\pi}{1006}$. Approximating directly by $\pi=3.1415 \ldots$ is worth only 3 points.
+Using the third-degree Taylor polynomial for sin we can approximate $\sin x \approx x-\frac{x^{3}}{6}$. This gives an answer of 3.1415875473 worth full points. If during the calculation we use the approximation $\pi^{3} \approx 30$, this gives an answer worth 9 points.
+36. [20]
+
+Answer: x Submit solution
+
diff --git a/HarvardMIT/md/en-161-2012-nov-team-solutions.md b/HarvardMIT/md/en-161-2012-nov-team-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..023a2dc5a5183feb20b3adadf6b4f8b9bd576374
--- /dev/null
+++ b/HarvardMIT/md/en-161-2012-nov-team-solutions.md
@@ -0,0 +1,96 @@
+## HMMT November 2012
+
+## Saturday 10 November 2012
+
+## Team Round
+
+1. [3] Find the number of integers between 1 and 200 inclusive whose distinct prime divisors sum to 16 . (For example, the sum of the distinct prime divisors of 12 is $2+3=5$.)
+
+Answer: 6 The primes less than 16 are $2,3,5,7,11$, and 13 . We can write 16 as the sum of such primes in three different ways and find the integers less than 200 with those prime factors:
+
+- $13+3: 3 \cdot 13=39$ and $3^{2} \cdot 13=117$.
+- $11+5: 5 \cdot 11=55$
+- $11+3+2: 2 \cdot 3 \cdot 11=66,2^{2} \cdot 3 \cdot 11=132$, and $2 \cdot 3^{2} \cdot 11=198$.
+
+There are therefore 6 numbers less than 200 whose prime divisors sum to 16 .
+2. [5] Find the number of ordered triples of divisors $\left(d_{1}, d_{2}, d_{3}\right)$ of 360 such that $d_{1} d_{2} d_{3}$ is also a divisor of 360 .
+
+Answer: 800 Since $360=2^{3} \cdot 3^{2} \cdot 5$, the only possible prime divisors of $d_{i}$ are 2 , 3 , and 5 , so we can write $d_{i}=2^{a_{i}} \cdot 3^{b_{i}} \cdot 5^{c_{i}}$, for nonnegative integers $a_{i}, b_{i}$, and $c_{i}$. Then, $d_{1} d_{2} d_{3} \mid 360$ if and only if the following three inequalities hold.
+
+$$
+\begin{aligned}
+a_{1}+a_{2}+a_{3} & \leq 3 \\
+b_{1}+b_{2}+b_{3} & \leq 2 \\
+c_{1}+c_{2}+c_{3} & \leq 1
+\end{aligned}
+$$
+
+Now, one can count that there are 20 assignments of $a_{i}$ that satisfy the first inequality, 10 assignments of $b_{i}$ that satisfy the second inequality, and 4 assignments of $c_{i}$ that satisfy the third inequality, for a total of 800 ordered triples $\left(d_{1}, d_{2}, d_{3}\right)$.
+(Alternatively, instead of counting, it is possible to show that the number of nonnegative-integer triples $\left(a_{1}, a_{2}, a_{3}\right)$ satisfying $a_{1}+a_{2}+a_{3} \leq n$ equals $\binom{n+3}{3}$, since this is equal to the number of nonnegativeinteger quadruplets ( $a_{1}, a_{2}, a_{3}, a_{4}$ ) satisfying $a_{1}+a_{2}+a_{3}+a_{4}=n$.)
+3. [6] Find the largest integer less than 2012 all of whose divisors have at most two 1 's in their binary representations.
+Answer: 1536 Call a number good if all of its positive divisors have at most two 1's in their binary representations. Then, if $p$ is an odd prime divisor of a good number, $p$ must be of the form $2^{k}+1$. The only such primes less than 2012 are $3,5,17$, and 257 , so the only possible prime divisors of $n$ are $2,3,5,17$, and 257 .
+Next, note that since $\left(2^{i}+1\right)\left(2^{j}+1\right)=2^{i+j}+2^{i}+2^{j}+1$, if either $i$ or $j$ is greater than 1 , then there will be at least 3 's in the binary representation of $\left(2^{i}+1\right)\left(2^{j}+1\right)$, so $\left(2^{i}+1\right)\left(2^{j}+1\right)$ cannot divide a good number. On the other hand, if $i=j=1$, then $\left(2^{1}+1\right)\left(2^{1}+1\right)=9=2^{3}+1$, so 9 is a good number and can divide a good number. Finally, note that since multiplication by 2 in binary just appends additional 0 s, so if $n$ is a good number, then $2 n$ is also a good number.
+It therefore follows that any good number less than 2012 must be of the form $c \cdot 2^{k}$, where $c$ belongs to $\{1,3,5,9,17,257\}$ (and moreover, all such numbers are good). It is then straightforward to check that the largest such number is $1536=3 \cdot 2^{9}$.
+4. [3] Let $\pi$ be a permutation of the numbers from 2 through 2012. Find the largest possible value of $\log _{2} \pi(2) \cdot \log _{3} \pi(3) \cdots \log _{2012} \pi(2012)$.
+
+Answer: 1 Note that
+
+$$
+\begin{aligned}
+\prod_{i=2}^{2012} \log _{i} \pi(i) & =\prod_{i=2}^{2012} \frac{\log \pi(i)}{\log i} \\
+& =\frac{\prod_{i=2}^{2012} \log \pi(i)}{\prod_{i=2}^{2012} \log i} \\
+& =1
+\end{aligned}
+$$
+
+where the last equality holds since $\pi$ is a permutation of the numbers 2 through 2012 .
+5. [4] Let $\pi$ be a randomly chosen permutation of the numbers from 1 through 2012 . Find the probability that $\pi(\pi(2012))=2012$.
+Answer: $\frac{1}{1006}$ There are two possibilities: either $\pi(2012)=2012$ or $\pi(2012)=i$ and $\pi(i)=2012$ for $i \neq 2012$. The first case occurs with probability $2011!/ 2012!=1 / 2012$, since any permutation on the remaining 2011 elements is possible. Similarly, for any fixed $i$, the second case occurs with probability $2010!/ 2012!=1 /(2011 \cdot 2012)$, since any permutation on the remaining 2010 elements is possible. Since there are 2011 possible values for $i$, and since our two possibilities are disjoint, the overall probability that $\pi(\pi(2012))=2012$ equals
+
+$$
+\frac{1}{2012}+(2011) \frac{1}{2011 \cdot 2012}=\frac{1}{1006}
+$$
+
+6. [6] Let $\pi$ be a permutation of the numbers from 1 through 2012. What is the maximum possible number of integers $n$ with $1 \leq n \leq 2011$ such that $\pi(n)$ divides $\pi(n+1)$ ?
+
+Answer: 1006 Since any proper divisor of $n$ must be less than or equal to $n / 2$, none of the numbers greater than 1006 can divide any other number less than or equal to 2012. Since there are at most 1006 values of $n$ for which $\pi(n) \leq 1006$, this means that there can be at most 1006 values of $n$ for which $\pi(n)$ divides $\pi(n+1)$.
+On the other hand, there exists a permutation for which $\pi(n)$ divides $\pi(n+1)$ for exactly 1006 values of $n$, namely the permutation:
+
+$$
+\left(1,2,2^{2}, 2^{3}, \ldots, 2^{10}, 3,2 \cdot 3,2^{2} \cdot 3,2^{3} \cdot 3, \ldots, 2^{9} \cdot 3,5, \ldots\right)
+$$
+
+Formally, for each odd number $\ell \leq 2012$, we construct the sequence $\ell, 2 \ell, 4 \ell, \ldots, 2^{k} \ell$, where $k$ is the largest integer such that $2^{k} \ell \leq 2012$. We then concatenate all of these sequences to form a permutation of the numbers 1 through $\ell$ (note that no number occurs in more than one sequence). It follows that if $\pi(n) \leq 1006$, then $\pi(n+1)$ will equal $2 \pi(n)$, and therefore $\pi(n)$ will divide $\pi(n+1)$ for all 1006 values of $n$ satisfying $1 \leq \pi(n) \leq 1006$.
+7. [8] Let $A_{1} A_{2} \ldots A_{100}$ be the vertices of a regular 100-gon. Let $\pi$ be a randomly chosen permutation of the numbers from 1 through 100. The segments $A_{\pi(1)} A_{\pi(2)}, A_{\pi(2)} A_{\pi(3)}, \ldots, A_{\pi(99)} A_{\pi(100)}, A_{\pi(100)} A_{\pi(1)}$ are drawn. Find the expected number of pairs of line segments that intersect at a point in the interior of the 100-gon.
+
+Answer: | $\frac{4850}{3}$ |
+| :---: |
+| By linearity of expectation, the expected number of total intersections is equal to | the sum of the probabilities that any given intersection will occur.
+
+Let us compute the probability $p_{i, j}$ that $A_{\pi(i)} A_{\pi(i+1)}$ intersects $A_{\pi(j)} A_{\pi(j+1)}$ (where $1 \leq i, j \leq 100$, $i \neq j$, and indices are taken modulo 100). Note first that if $j=i+1$, then these two segments share vertex $\pi(i+1)$ and therefore will not intersect in the interior of the 100-gon; similarly, if $i=j+1$, these two segments will also not intersect. On the other hand, if $\pi(i), \pi(i+1), \pi(j)$, and $\pi(j+1)$ are all distinct, then there is a $1 / 3$ chance that $A_{\pi(i)} A_{\pi(i+1)}$ intersects $A_{\pi(j)} A_{\pi(j+1)}$; in any set of four
+points that form a convex quadrilateral, exactly one of the three ways of pairing the points into two pairs (two pairs of opposite sides and the two diagonals) forms two segments that intersect inside the quadrilateral (namely, the two diagonals).
+Now, there are 100 ways to choose a value for $i$, and 97 ways to choose a value for $j$ which is not $i$, $i+1$, or $i-1$, there are 9700 ordered pairs $(i, j)$ where $p_{i, j}=1 / 3$. Since each pair is counted twice (once as $(i, j)$ and once as $(j, i)$ ), there are $9700 / 2=4850$ distinct possible intersections, each of which occurs with probability $1 / 3$, so the expected number of intersections is equal to $4850 / 3$.
+8. [4] $A B C$ is a triangle with $A B=15, B C=14$, and $C A=13$. The altitude from $A$ to $B C$ is extended to meet the circumcircle of $A B C$ at $D$. Find $A D$.
+Answer: $\boxed{\frac{63}{4}}$ Let the altitude from $A$ to $BC$ meet $BC$ at $E$. The altitude $AE$ has length 12; one way to see this is that it splits the triangle $A B C$ into a $9-12-15$ right triangle and a $5-12-13$ right triangle; from this, we also know that $B E=9$ and $C E=5$.
+Now, by Power of a Point, $A E \cdot D E=B E \cdot C E$, so $D E=(B E \cdot C E) / A E=(9 \cdot 5) /(12)=15 / 4$. It then follows that $A D=A E+D E=63 / 4$.
+9. [5] Triangle $A B C$ satisfies $\angle B>\angle C$. Let $M$ be the midpoint of $B C$, and let the perpendicular bisector of $B C$ meet the circumcircle of $\triangle A B C$ at a point $D$ such that points $A, D, C$, and $B$ appear on the circle in that order. Given that $\angle A D M=68^{\circ}$ and $\angle D A C=64^{\circ}$, find $\angle B$.
+Answer: $86^{\circ}$ Extend $D M$ to hit the circumcircle at $E$. Then, note that since $A D E B$ is a cyclic quadrilateral, $\angle A B E=180^{\circ}-\angle A D E=180^{\circ}-\angle A D M=180^{\circ}-68^{\circ}=112^{\circ}$.
+
+We also have that $\angle M E C=\angle D E C=\angle D A C=64^{\circ}$. But now, since $M$ is the midpoint of $B C$ and since $E M \perp B C$, triangle $B E C$ is isosceles. This implies that $\angle B E M=\angle M E C=64^{\circ}$, and $\angle M B E=90^{\circ}-\angle M E B=26^{\circ}$. It follows that $\angle B=\angle A B E-\angle M B E=112^{\circ}-26^{\circ}=86^{\circ}$.
+10. [6] Triangle $A B C$ has $A B=4, B C=5$, and $C A=6$. Points $A^{\prime}, B^{\prime}, C^{\prime}$ are such that $B^{\prime} C^{\prime}$ is tangent to the circumcircle of $\triangle A B C$ at $A, C^{\prime} A^{\prime}$ is tangent to the circumcircle at $B$, and $A^{\prime} B^{\prime}$ is tangent to the circumcircle at $C$. Find the length $B^{\prime} C^{\prime}$.
+Answer: $\frac{80}{3}$ Note that by equal tangents, $B^{\prime} A=B^{\prime} C, C^{\prime} A=C^{\prime} B$, and $A^{\prime} B=A^{\prime} C$. Moreover, since the line segments $A^{\prime} B^{\prime}, B^{\prime} C^{\prime}$, and $C^{\prime} A^{\prime}$ are tangent to the circumcircle of $A B C$ at $C, A$, and $B$ respectively, we have that $\angle A^{\prime} B C=\angle A^{\prime} C B=\angle A, \angle B^{\prime} A C=\angle B^{\prime} C A=\angle B$, and $\angle C^{\prime} B A=$ $\angle C^{\prime} A B=\angle C$. By drawing the altitudes of the isosceles triangles $B C^{\prime} A$ and $A C^{\prime} B$, we therefore have that $C^{\prime} A=2 / \cos C$ and $B^{\prime} A=3 / \cos B$.
+Now, by the Law of Cosines, we have that
+
+$$
+\begin{aligned}
+& \cos B=\frac{a^{2}+c^{2}-b^{2}}{2 a c}=\frac{25+16-36}{2(5)(4)}=\frac{1}{8} \\
+& \cos C=\frac{a^{2}+b^{2}-c^{2}}{2 a b}=\frac{25+36-16}{2(5)(6)}=\frac{3}{4} .
+\end{aligned}
+$$
+
+Therefore,
+
+$$
+B^{\prime} C^{\prime}=C^{\prime} A+B^{\prime} A=2\left(\frac{4}{3}\right)+3(8)=\frac{80}{3}
+$$
+
diff --git a/HarvardMIT/md/en-161-2012-nov-thm-solutions.md b/HarvardMIT/md/en-161-2012-nov-thm-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..07b5f9af7c60bb70951233e6f8c1ff2bf7431f82
--- /dev/null
+++ b/HarvardMIT/md/en-161-2012-nov-thm-solutions.md
@@ -0,0 +1,97 @@
+# HMMT November 2012
Saturday 10 November 2012
Saturday 10 November 2012
Theme Round
+
+
Theme Round}
+
+1. [3] If $4^{4^{4}}=\sqrt[128]{2^{2^{2^{n}}}}$, find $n$.
+
+Answer: 4 We rewrite the left hand side as
+
+$$
+\left(2^{2}\right)^{4^{4}}=2^{2 \cdot 4^{4}}=2^{2^{9}},
+$$
+
+and the right hand side as
+
+$$
+\left(2^{2^{2^{n}}}\right)^{\frac{1}{128}}=2^{2^{\left(2^{n}-7\right)}} .
+$$
+
+Equating, we find $2^{n}-7=9$, yielding $n=4$.
+2. [4] If $x^{x}=2012^{2012^{2013}}$, find $x$.
+
+Answer: $2012^{2012}$ We have
+
+$$
+2012^{2012^{2013}}=2012^{2012 \cdot 2012^{2012}}=\left(2012^{2012}\right)^{2012^{2012}} .
+$$
+
+Thus, $x=2012^{2012}$.
+3. [4] Find the smallest positive integer $n$ such that $\underbrace{2^{2 \cdot 2}}_{n}>3^{3^{3^{3}}}$. (The notation $\underbrace{2^{2 \cdot 2^{2}}}_{n}$ is used to denote a power tower with $n 2$ 's. For example, $\underbrace{2^{2^{2}}}_{n}$ with $n=4$ would equal $2^{2^{2^{2}}}$.)
+
+Answer: 6 Clearly, $n \geq 5$. When we take $n=5$, we have
+
+$$
+2^{2^{2^{2^{2}}}}=2^{2^{16}}<3^{3^{27}}=3^{3^{3^{3}}} .
+$$
+
+On the other hand, when $n=6$, we have
+
+$$
+2^{2^{2^{2^{2^{2}}}}}=2^{2^{65536}}=4^{2^{65535}}>4^{4^{27}}>3^{3^{2^{27}}}=3^{3^{3^{3}}} .
+$$
+
+Our answer is thus $n=6$.
+4. [7] Find the sum of all real solutions for $x$ to the equation $\left(x^{2}+2 x+3\right)^{\left(x^{2}+2 x+3\right)^{\left(x^{2}+2 x+3\right)}}=2012$.
+
+Answer: $\sqrt{-2}$ When $y=x^{2}+2 x+3$, note that there is a unique real number $y$ such that $y^{y^{y}}=2012$ because $y^{y^{y}}$ is increasing in $y$. The sum of the real distinct solutions of the equation $x^{2}+2 x+3=y$ is -2 by Vieta's Formulae as long as $2^{2}+4(y-3)>0$, which is equivalent to $y>2$. This is easily seen to be the case; therefore, our answer is -2 .
+5. [7] Given any positive integer, we can write the integer in base 12 and add together the digits of its base 12 representation. We perform this operation on the number $7^{6^{5^{3^{2^{1}}}}}$ repeatedly until a single base 12 digit remains. Find this digit.
+Answer: 4 For a positive integer $n$, let $s(n)$ be the sum of digits when $n$ is expressed in base 12 . We claim that $s(n) \equiv n(\bmod 11)$ for all positive integers $n$. Indeed, if $n=d_{k} 12^{k}+d_{k-1} 12^{k-1}+\cdots+d_{0}$ with each $d_{i}$ an integer between 0 and 11 , inclusive, because $12 \equiv 1(\bmod 11)$, reducing modulo 11 gives exactly $s(n)$. Thus, our answer is congruent to $N=7^{6^{5^{4^{3^{1}}}}}$ modulo 11 , and furthermore must be a one-digit integer in base 12; these two conditions uniquely determine the answer.
+By Fermat's Little Theorem, $7^{10} \equiv 1(\bmod 11)$, and also observe that $6^{5^{4^{3^{2^{1}}}}} \equiv 6(\bmod 10)$ because $6 \cong 0(\bmod 2)$ and $6 \cong 1(\bmod 5)$. Thus, $N \equiv 7^{6} \equiv 343^{2} \equiv 2^{2} \equiv 4(\bmod 11)$, which is our answer. (Additionally, we note that this process of writing the number in base twelve and summing the digits must eventually terminate because the value decreases after each step.)
+6. [3] A rectangular piece of paper with vertices $A B C D$ is being cut by a pair of scissors. The pair of scissors starts at vertex $A$, and then cuts along the angle bisector of $D A B$ until it reaches another edge of the paper. One of the two resulting pieces of paper has 4 times the area of the other piece. What is the ratio of the longer side of the original paper to the shorter side?
+Answer: $\sqrt{\frac{5}{2}}$ Without loss of generality, let $A B>A D$, and let $x=A D, y=A B$. Let the cut along the angle bisector of $\angle D A B$ meet $C D$ at $E$. Note that $A D E$ is a 45-45-90 triangle, so $D E=A D=x$, and $E C=y-x$. Now, $[A D E]=\frac{x^{2}}{2}$, and $[A E C B]=x\left(y-\frac{x}{2}\right)=4[A D E]$. Equating and dividing both sides by $x$, we find that $2 x=y-\frac{x}{2}$, so $y / x=\frac{5}{2}$.
+7. [4] The game of rock-scissors is played just like rock-paper-scissors, except that neither player is allowed to play paper. You play against a poorly-designed computer program that plays rock with $50 \%$ probability and scissors with $50 \%$ probability. If you play optimally against the computer, find the probability that after 8 games you have won at least 4 .
+
+Answer: $\frac{163}{256}$ Since rock will always win against scissors, the optimum strategy is for you to always play rock; then, you win a game if and only if the computer plays scissors. Let $p_{n}$ be the probability that the computer plays scissors $n$ times; we want $p_{0}+p_{1}+p_{2}+p_{3}+p_{4}$. Note that by symmetry, $p_{n}=p_{8-n}$ for $n=0,1, \ldots, 8$, and because $p_{0}+p_{1}+\cdots+p_{8}=1, p_{0}+\cdots+p_{3}=p_{5}+\cdots+p_{8}=\left(1-p_{4}\right) / 2$. Our answer will thus be $\left(1+p_{4}\right) / 2$.
+If the computer is to play scissors exactly 4 times, there are $\binom{8}{4}$ ways in which it can do so, compared to $2^{8}$ possible combinations of eight plays. Thus, $p_{4}=\binom{8}{4} / 2^{8}=35 / 128$. Our answer is thus $\frac{1+\frac{35}{128}}{2}=$ $\frac{163}{256}$.
+8. [4] In the game of rock-paper-scissors-lizard-Spock, rock defeats scissors and lizard, paper defeats rock and Spock, scissors defeats paper and lizard, lizard defeats paper and Spock, and Spock defeats rock and scissors, as shown in the below diagram. As before, if two players choose the same move, then there is a draw. If three people each play a game of rock-paper-scissors-lizard-Spock at the same time by choosing one of the five moves at random, what is the probability that one player beats the other two?
+
+
+Answer: $\frac{12}{25}$ Let the three players be $A, B, C$. Our answer will simply be the sum of the probability that $A$ beats both $B$ and $C$, the probability that $B$ beats both $C$ and $A$, and the probability that $C$ beats $A$ and $B$, because these events are all mutually exclusive. By symmetry, these three probabilities are the same, so we only need to compute the probability that $A$ beats both $B$ and $C$. Given $A$ 's play, the probability that $B$ 's play loses to that of $A$ is $2 / 5$, and similarly for $C$. Thus, our answer is $3 \cdot\left(\frac{2}{5}\right) \cdot\left(\frac{2}{5}\right)=\frac{12}{25}$.
+9. [6] 64 people are in a single elimination rock-paper-scissors tournament, which consists of a 6-round knockout bracket. Each person has a different rock-paper-scissors skill level, and in any game, the person with the higher skill level will always win. For how many players $P$ is it possible that $P$ wins the first four rounds that he plays?
+(A 6-round knockout bracket is a tournament which works as follows:
+(a) In the first round, all 64 competitors are paired into 32 groups, and the two people in each group play each other. The winners advance to the second round, and the losers are eliminated.
+(b) In the second round, the remaining 32 players are paired into 16 groups. Again, the winner of each group proceeds to the next round, while the loser is eliminated.
+(c) Each round proceeds in a similar way, eliminating half of the remaining players. After the sixth round, only one player will not have been eliminated. That player is declared the champion.)
+
+Answer: 49 Note that a sub-bracket, that is, a subset of games of the tournament that themselves constitute a bracket, is always won by the person with the highest skill level. Therefore, a person wins her first four rounds if and only if she has the highest skill level among the people in her 16 -person sub-bracket. This is possible for all but the people with the $16-1=15$ lowest skill levels, so our answer is $64-15=49$.
+10. [8] In a game of rock-paper-scissors with $n$ people, the following rules are used to determine a champion:
+(a) In a round, each person who has not been eliminated randomly chooses one of rock, paper, or scissors to play.
+(b) If at least one person plays rock, at least one person plays paper, and at least one person plays scissors, then the round is declared a tie and no one is eliminated. If everyone makes the same move, then the round is also declared a tie.
+(c) If exactly two moves are represented, then everyone who made the losing move is eliminated from playing in all further rounds (for example, in a game with 8 people, if 5 people play rock and 3 people play scissors, then the 3 who played scissors are eliminated).
+(d) The rounds continue until only one person has not been eliminated. That person is declared the champion and the game ends.
+
+If a game begins with 4 people, what is the expected value of the number of rounds required for a champion to be determined?
+Answer: $\sqrt[\frac{45}{14}]{ }$ For each positive integer $n$, let $E_{n}$ denote the expected number of rounds required to determine a winner among $n$ people. Clearly, $E_{1}=0$. When $n=2$, on the first move, there is a $\frac{1}{3}$ probability that there is a tie, and a $\frac{2}{3}$ probability that a winner is determined. In the first case, the expected number of additional rounds needed is exactly $E_{2}$; in the second, it is $E_{1}$. Therefore, we get the relation
+
+$$
+E_{2}=\frac{1}{3}\left(E_{2}+1\right)+\frac{2}{3}\left(E_{1}+1\right),
+$$
+
+from which it follows that $E_{2}=\frac{3}{2}$.
+Next, if $n=3$, with probability $\frac{1}{9}$ there is only one distinct play among the three players, and with probability $\frac{6}{27}=\frac{2}{9}$ all three players make different plays. In both of these cases, no players are eliminated. In all remaining situations, which occur with total probability $\frac{2}{3}$, two players make one play and the third makes a distinct play; with probability $\frac{1}{3}$ two players are eliminated and with probability $\frac{1}{3}$ one player is eliminated. This gives the relation
+
+$$
+E_{3}=\frac{1}{3}\left(E_{3}+1\right)+\frac{1}{3}\left(E_{2}+1\right)+\frac{1}{3}\left(E_{1}+1\right),
+$$
+
+from which we find that $E_{3}=\frac{9}{4}$.
+Finally, suppose $n=4$. With probability $\frac{1}{27}$, all four players make the same play, and with probability $\frac{3 \cdot 6 \cdot 2}{81}=\frac{4}{9}$, two players make one play, and the other two players make the other two plays; in both cases no players are eliminated, with total probability $\frac{1}{27}+\frac{4}{9}=\frac{13}{27}$ over the two cases. With probability $\frac{6 \cdot 4}{81}=\frac{8}{27}$, three players make one play and the fourth makes another; thus, there is a probability of $\frac{4}{27}$ for exactly one player being eliminated and a probability of $\frac{4}{27}$ of three players being eliminated.
+
+Then, there is a remaining probability of $\frac{6 \cdot 3}{81}=\frac{2}{9}$, two players make one play and the other two players make another. Similar analysis from before yields
+
+$$
+E_{4}=\frac{13}{27}\left(E_{4}+1\right)+\frac{4}{27}\left(E_{3}+1\right)+\frac{2}{9}\left(E_{2}+1\right)+\frac{4}{27}\left(E_{1}+1\right)
+$$
+
+so it follows that $E_{4}=\frac{45}{14}$.
+
diff --git a/HarvardMIT/md/en-162-2013-feb-alg-solutions.md b/HarvardMIT/md/en-162-2013-feb-alg-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..5e434c22b2e2d9c27b378e349f3255c8b7f8a6c1
--- /dev/null
+++ b/HarvardMIT/md/en-162-2013-feb-alg-solutions.md
@@ -0,0 +1,145 @@
+## HMMT 2013
Saturday 16 February 2013
+
+## Algebra Test
+
+1. Let $x$ and $y$ be real numbers with $x>y$ such that $x^{2} y^{2}+x^{2}+y^{2}+2 x y=40$ and $x y+x+y=8$. Find the value of $x$.
+Answer: $\quad 3+\sqrt{7}$ We have $(x y)^{2}+(x+y)^{2}=40$ and $x y+(x+y)=8$. Squaring the second equation and subtracting the first gives $x y(x+y)=12$ so $x y, x+y$ are the roots of the quadratic $a^{2}-8 a+12=0$. It follows that $\{x y, x+y\}=\{2,6\}$. If $x+y=2$ and $x y=6$, then $x, y$ are the roots of the quadratic $b^{2}-2 b+6=0$, which are non-real, so in fact $x+y=6$ and $x y=2$, and $x, y$ are the roots of the quadratic $b^{2}-6 b+2=0$. Because $x>y$, we take the larger root, which is $\frac{6+\sqrt{28}}{2}=3+\sqrt{7}$.
+2. Let $\left\{a_{n}\right\}_{n \geq 1}$ be an arithmetic sequence and $\left\{g_{n}\right\}_{n \geq 1}$ be a geometric sequence such that the first four terms of $\left\{a_{n}+g_{n}\right\}$ are $0,0,1$, and 0 , in that order. What is the 10 th term of $\left\{a_{n}+g_{n}\right\}$ ?
+Answer: $\quad-54$ Let the terms of the geometric sequence be $a, r a, r^{2} a, r^{3} a$. Then, the terms of the arithmetic sequence are $-a,-r a,-r^{2} a+1,-r^{3} a$. However, if the first two terms of this sequence are $-a,-r a$, the next two terms must also be $(-2 r+1) a,(-3 r+2) a$. It is clear that $a \neq 0$ because $a_{3}+g_{3} \neq 0$, so $-r^{3}=-3 r+2 \Rightarrow r=1$ or -2 . However, we see from the arithmetic sequence that $r=1$ is impossible, so $r=-2$. Finally, by considering $a_{3}$, we see that $-4 a+1=5 a$, so $a=1 / 9$. We also see that $a_{n}=(3 n-4) a$ and $g_{n}=(-2)^{n-1} a$, so our answer is $a_{10}+g_{10}=(26-512) a=-486 a=-54$.
+3. Let $S$ be the set of integers of the form $2^{x}+2^{y}+2^{z}$, where $x, y, z$ are pairwise distinct non-negative integers. Determine the 100 th smallest element of $S$.
+Answer: $577 S$ is the set of positive integers with exactly three ones in its binary representation. The number of such integers with at most $d$ total bits is $\binom{d}{3}$, and noting that $\binom{9}{3}=84$ and $\binom{10}{3}=120$, we want the 16 th smallest integer of the form $2^{9}+2^{x}+2^{y}$, where $y
Saturday 16 February 2013
Geometry Test
+
+1. Jarris the triangle is playing in the $(x, y)$ plane. Let his maximum $y$ coordinate be $k$. Given that he has side lengths 6,8 , and 10 and that no part of him is below the $x$-axis, find the minimum possible value of $k$.
+Answer: $\quad \frac{24}{5}$ By playing around, we find that Jarris should have his hypotenuse flat on the $x$ axis. The desired minimum value of $k$ is then the length of the altitude to the hypotenuse. Thus, by computing the area of the triangle in two ways, $\frac{1}{2} \cdot 10 \cdot k=\frac{1}{2} \cdot 6 \cdot 8$ and so $k=\frac{24}{5}$.
+2. Let $A B C D$ be an isosceles trapezoid such that $A D=B C, A B=3$, and $C D=8$. Let $E$ be a point in the plane such that $B C=E C$ and $A E \perp E C$. Compute $A E$.
+Answer: $2 \sqrt{6}$ Let $r=B C=E C=A D . \triangle A C E$ has right angle at $E$, so by the Pythagorean Theorem,
+
+$$
+A E^{2}=A C^{2}-C E^{2}=A C^{2}-r^{2}
+$$
+
+Let the height of $\triangle A C D$ at $A$ intersect $D C$ at $F$. Once again, by the Pythagorean Theorem,
+
+$$
+A C^{2}=F C^{2}+A F^{2}=\left(\frac{8-3}{2}+3\right)^{2}+A D^{2}-D F^{2}=\left(\frac{11}{2}\right)^{2}+r^{2}-\left(\frac{5}{2}\right)^{2}
+$$
+
+Plugging into the first equation,
+
+$$
+A E^{2}=\left(\frac{11}{2}\right)^{2}+r^{2}-\left(\frac{5}{2}\right)^{2}-r^{2}
+$$
+
+so $A E=2 \sqrt{6}$.
+3. Let $A_{1} A_{2} A_{3} A_{4} A_{5} A_{6}$ be a convex hexagon such that $A_{i} A_{i+2} \| A_{i+3} A_{i+5}$ for $i=1,2,3$ (we take $A_{i+6}=A_{i}$ for each $i$. Segment $A_{i} A_{i+2}$ intersects segment $A_{i+1} A_{i+3}$ at $B_{i}$, for $1 \leq i \leq 6$, as shown. Furthermore, suppose that $\triangle A_{1} A_{3} A_{5} \cong \triangle A_{4} A_{6} A_{2}$. Given that $\left[A_{1} B_{5} B_{6}\right]=1,\left[A_{2} B_{6} B_{1}\right]=$ 4, and $\left[A_{3} B_{1} B_{2}\right]=9$ (by $[X Y Z]$ we mean the area of $\triangle X Y Z$ ), determine the area of hexagon $B_{1} B_{2} B_{3} B_{4} B_{5} B_{6}$.
+
+
+Answer: 22 Because $B_{6} A_{3} B_{3} A_{6}$ and $B_{1} A_{4} B_{4} A_{1}$ are parallelograms, $B_{6} A_{3}=A_{6} B_{3}$ and $A_{1} B_{1}=$ $A_{4} B_{4}$. By the congruence of the large triangles $A_{1} A_{3} A_{5}$ and $A_{2} A_{4} A_{6}, A_{1} A_{3}=A_{4} A_{6}$. Thus, $B_{6} A_{3}+$ $A_{1} B_{1}-A_{1} A_{3}=A_{6} B_{3}+A_{4} B_{4}-A_{4} A_{6}$, so $B_{6} B_{1}=B_{3} B_{4}$. Similarly, opposite sides of hexagon $B_{1} B_{2} B_{3} B_{4} B_{5} B_{6}$ are equal, and implying that the triangles opposite each other on the outside of this hexagon are congruent.
+Furthermore, by definition $B_{5} B_{6}\left\|A_{3} A_{5}, B_{3} B_{4}\right\| A_{1} A_{3}, B_{6} B_{1} \| A_{4} A_{6}$ and $B_{1} B_{2} \| A_{1} A_{5}$. Let the area of triangle $A_{1} A_{3} A_{5}$ and triangle $A_{2} A_{4} A_{6}$ be $k^{2}$. Then, by similar triangles,
+
+$$
+\begin{aligned}
+& \sqrt{\frac{1}{k^{2}}}=\frac{A_{1} B_{6}}{A_{1} A_{3}} \\
+& \sqrt{\frac{4}{k^{2}}}=\frac{B_{6} B_{1}}{A_{4} A_{6}}=\frac{B_{1} B_{6}}{A_{1} A_{3}} \\
+& \sqrt{\frac{9}{k^{2}}}=\frac{A_{3} B_{1}}{A_{1} A_{3}}
+\end{aligned}
+$$
+
+Summing yields $6 / k=1$, so $k^{2}=36$. To finish, the area of $B_{1} B_{2} B_{3} B_{4} B_{5} B_{6}$ is equivalent to the area of the triangle $A_{1} A_{3} A_{5}$ minus the areas of the smaller triangles provided in the hypothesis. Thus, our answer is $36-1-4-9=22$.
+4. Let $\omega_{1}$ and $\omega_{2}$ be circles with centers $O_{1}$ and $O_{2}$, respectively, and radii $r_{1}$ and $r_{2}$, respectively. Suppose that $O_{2}$ is on $\omega_{1}$. Let $A$ be one of the intersections of $\omega_{1}$ and $\omega_{2}$, and $B$ be one of the two intersections of line $O_{1} O_{2}$ with $\omega_{2}$. If $A B=O_{1} A$, find all possible values of $\frac{r_{1}}{r_{2}}$.
+Answer: $\frac{-1+\sqrt{5}}{2}, \frac{1+\sqrt{5}}{2}$ There are two configurations to this problem, namely, $B$ in between the segment $O_{1} O_{2}$ and $B$ on the ray $O_{1} O_{2}$ passing through the side of $O_{2}$ Case 1: Let us only consider the triangle $A B O_{2} . A B=A O_{1}=O_{1} O_{2}=r_{1}$ because of the hypothesis and $A O_{1}$ and $O_{1} O_{2}$ are radii of $w_{1}$. $O_{2} B=O_{2} A=r_{2}$ because they are both radii of $w_{2}$.
+Then by the isosceles triangles, $\angle A O_{1} B=\angle A B O_{1}=\angle A B O_{2}=\angle O_{2} A B$. Thus can establish that $\triangle A B O_{1} \sim \triangle O_{2} A B$.
+
+Thus,
+
+$$
+\begin{gathered}
+\frac{r_{2}}{r_{1}}=\frac{r_{1}}{r_{2}-r_{1}} \\
+r_{1}^{2}-r_{2}^{2}+r_{1} r_{2}=0
+\end{gathered}
+$$
+
+By straightforward quadratic equation computation and discarding the negative solution,
+
+$$
+\frac{r_{1}}{r_{2}}=\frac{-1+\sqrt{5}}{2}
+$$
+
+Case 2: Similar to case 1, let us only consider the triangle $A B O_{1}$. $A B=A O_{1}=O_{1} O_{2}=r_{1}$ because of the hypothesis and $A O_{1}$ and $O_{1} O_{2}$ are radii of $w_{1} . O_{2} B=O_{2} A=r_{2}$ because they are both radii of $w_{2}$.
+Then by the isosceles triangles, $\angle A O_{1} B=\angle A B O_{1}=\angle A B O_{2}=\angle O_{2} A B$. Thus can establish that $\triangle A B O_{1} \sim \triangle O_{2} A B$.
+Now,
+
+$$
+\begin{gathered}
+\frac{r_{2}}{r_{1}}=\frac{r_{1}}{r_{2}+r_{1}} \\
+r_{1}^{2}-r_{2}^{2}-r_{1} r_{2}=0
+\end{gathered}
+$$
+
+By straightforward quadratic equation computation and discarding the negative solution,
+
+$$
+\frac{r_{1}}{r_{2}}=\frac{1+\sqrt{5}}{2}
+$$
+
+5. In triangle $A B C, \angle A=45^{\circ}$ and $M$ is the midpoint of $\overline{B C}$. $\overline{A M}$ intersects the circumcircle of $A B C$ for the second time at $D$, and $A M=2 M D$. Find $\cos \angle A O D$, where $O$ is the circumcenter of $A B C$.
+Answer: $-\frac{1}{8} \angle B A C=45^{\circ}$, so $\angle B O C=90^{\circ}$. If the radius of the circumcircle is $r, B C=\sqrt{2} r$, and $B M=C M=\frac{\sqrt{2}}{2} r$. By power of a point, $B M \cdot C M=A M \cdot D M$, so $A M=r$ and $D M=\frac{1}{2} r$, and $A D=\frac{3}{2} r$. Using the law of cosines on triangle $A O D$ gives $\cos \angle A O D=-\frac{1}{8}$.
+6. Let $A B C D$ be a quadrilateral such that $\angle A B C=\angle C D A=90^{\circ}$, and $B C=7$. Let $E$ and $F$ be on $B D$ such that $A E$ and $C F$ are perpendicular to $B D$. Suppose that $B E=3$. Determine the product of the smallest and largest possible lengths of $D F$.
+Answer: 9 By inscribed angles, $\angle C D B=\angle C A B$, and $\angle A B D=\angle A C D$. By definition, $\angle A E B=\angle C \overline{D A}=\angle A B C=\angle C F A$. Thus, $\triangle A B E \sim \triangle A D C$ and $\triangle C D F \sim \triangle C A B$. This shows that
+
+$$
+\frac{B E}{A B}=\frac{C D}{C A} \text { and } \frac{D F}{C D}=\frac{A B}{B D}
+$$
+
+Based on the previous two equations, it is sufficient to conclude that $3=E B=F D$. Thus, $F D$ must equal to 3 , and the product of its largest and smallest length is 9 .
+7. Let $A B C$ be an obtuse triangle with circumcenter $O$ such that $\angle A B C=15^{\circ}$ and $\angle B A C>90^{\circ}$. Suppose that $A O$ meets $B C$ at $D$, and that $O D^{2}+O C \cdot D C=O C^{2}$. Find $\angle C$.
+Answer: 35 Let the radius of the circumcircle of $\triangle A B C$ be $r$.
+
+$$
+\begin{gathered}
+O D^{2}+O C \cdot C D=O C^{2} \\
+O C \cdot C D=O C^{2}-O D^{2} \\
+O C \cdot C D=(O C+O D)(O C-O D) \\
+O C \cdot C D=(r+O D)(r-O D)
+\end{gathered}
+$$
+
+By the power of the point at D ,
+
+$$
+\begin{gathered}
+O C \cdot C D=B D \cdot D C \\
+r=B D
+\end{gathered}
+$$
+
+Then, $\triangle O B D$ and $\triangle O A B$ and $\triangle A O C$ are isosceles triangles. Let $\angle D O B=\alpha . \angle B A O=90-\frac{\alpha}{2}$. In $\triangle A B D, 15+90-\frac{\alpha}{2}=\alpha$. This means that $\alpha=70$. Furthermore, $\angle A C B$ intercepts minor arc $A B$, thus $\angle A C B=\frac{\angle A O B}{2}=\frac{70}{2}=35$
+8. Let $A B C D$ be a convex quadrilateral. Extend line $C D$ past $D$ to meet line $A B$ at $P$ and extend line $C B$ past $B$ to meet line $A D$ at $Q$. Suppose that line $A C$ bisects $\angle B A D$. If $A D=\frac{7}{4}, A P=\frac{21}{2}$, and $A B=\frac{14}{11}$, compute $A Q$.
+Answer: $\frac{42}{13}$ We prove the more general statement $\frac{1}{A B}+\frac{1}{A P}=\frac{1}{A D}+\frac{1}{A Q}$, from which the answer easily follows.
+
+Denote $\angle B A C=\angle C A D=\gamma, \angle B C A=\alpha, \angle A C D=\beta$. Then we have that by the law of sines, $\frac{A C}{A B}+\frac{A C}{A P}=\frac{\sin (\gamma+\alpha)}{\sin (\alpha)}+\frac{\sin (\gamma-\beta)}{\sin (\beta)}=\frac{\sin (\gamma-\alpha)}{\sin (\alpha)}+\frac{\sin (\gamma+\beta)}{\sin (\beta)}=\frac{A C}{A D}+\frac{A C}{A Q}$ where we have simply used the sine addition formula for the middle step.
+Dividing the whole equation by $A C$ gives the desired formula, from which we compute $A Q=\left(\frac{11}{14}+\right.$ $\left.\frac{2}{21}-\frac{4}{7}\right)^{-1}=\frac{42}{13}$.
+9. Pentagon $A B C D E$ is given with the following conditions:
+(a) $\angle C B D+\angle D A E=\angle B A D=45^{\circ}, \angle B C D+\angle D E A=300^{\circ}$
+(b) $\frac{B A}{D A}=\frac{2 \sqrt{2}}{3}, C D=\frac{7 \sqrt{5}}{3}$, and $D E=\frac{15 \sqrt{2}}{4}$
+(c) $A D^{2} \cdot B C=A B \cdot A E \cdot B D$
+
+Compute $B D$.
+Answer: $\sqrt{\sqrt{39}}$ As a preliminary, we may compute that by the law of cosines, the ratio $\frac{A D}{B D}=\frac{3}{\sqrt{5}}$. Now, construct the point $P$ in triangle $A B D$ such that $\triangle A P B \sim \triangle A E D$. Observe that $\frac{A P}{A D}=$ $\frac{A E \cdot A B}{A D \cdot A D}=\frac{B C}{B D}$ (where we have used first the similarity and then condition 3). Furthermore, $\angle C B D=$ $\angle D A B-\angle D A E=\angle D A B-\angle P A B=\angle P A D$ so by SAS, we have that $\triangle C B D \sim \triangle P A D$.
+
+Therefore, by the similar triangles, we may compute $P B=D E \cdot \frac{A B}{A D}=5$ and $P D=C D \cdot \frac{A D}{B D}=7$. Furthermore, $\angle B P D=360-\angle B P A-\angle D P A=360-\angle B C D-\angle D E A=60$ and therefore, by the law of cosines, we have that $B D=\sqrt{39}$.
+10. Triangle $A B C$ is inscribed in a circle $\omega$. Let the bisector of angle $A$ meet $\omega$ at $D$ and $B C$ at $E$. Let the reflections of $A$ across $D$ and $C$ be $D^{\prime}$ and $C^{\prime}$, respectively. Suppose that $\angle A=60^{\circ}, A B=3$, and $A E=4$. If the tangent to $\omega$ at $A$ meets line $B C$ at $P$, and the circumcircle of $A P D^{\prime}$ meets line $B C$ at $F$ (other than $P$ ), compute $F C^{\prime}$.
+Answer: $2 \sqrt{13-6 \sqrt{3}}$ First observe that by angle chasing, $\angle P A E=180-\frac{1}{2} \angle B A C-\angle A B C=$ $\angle A E P$, so by the cyclic quadrilateral $A P D^{\prime} F, \angle E F D^{\prime}=\angle P A E=\angle P E A=\angle D^{\prime} E F$. Thus, $E D^{\prime} F$ is isosceles.
+
+Define $B^{\prime}$ to be the reflection of $A$ about $B$, and observe that $B^{\prime} C^{\prime} \| E F$ and $B^{\prime} D^{\prime} C^{\prime}$ is isosceles. It follows that $B^{\prime} E F C^{\prime}$ is an isosceles trapezoid, so $F C^{\prime}=B^{\prime} E$, which by the law of cosines, is equal to $\sqrt{A B^{\prime 2}+A E^{2}-2 A B \cdot A E \cos 30}=2 \sqrt{13-6 \sqrt{3}}$.
+
diff --git a/HarvardMIT/md/en-162-2013-feb-guts-solutions.md b/HarvardMIT/md/en-162-2013-feb-guts-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..db30c8e86b9dc2e49a2289f21a439bde68c79856
--- /dev/null
+++ b/HarvardMIT/md/en-162-2013-feb-guts-solutions.md
@@ -0,0 +1,305 @@
+## HMMT 2013
Saturday 16 February 2013
+
+## Guts Round
+
+1. [4] Arpon chooses a positive real number $k$. For each positive integer $n$, he places a marker at the point $(n, n k)$ in the $(x, y)$ plane. Suppose that two markers whose $x$ coordinates differ by 4 have distance 31. What is the distance between the markers at $(7,7 k)$ and $(19,19 k)$ ?
+
+Answer: 93 The difference of the $x$-coordinates of the markers is $12=3 \cdot 4$. Thus, by similar triangles (where we draw right triangles whose legs are parallel to the axes and whose hypotenuses lie along the line $y=k x$ ), the distance between the markers is $3 \cdot 31=93$.
+2. [4] The real numbers $x, y, z$ satisfy $0 \leq x \leq y \leq z \leq 4$. If their squares form an arithmetic progression with common difference 2 , determine the minimum possible value of $|x-y|+|y-z|$.
+Answer: $4-2 \sqrt{3}$ Clearly $|x-y|+|y-z|=z-x=\frac{z^{2}-x^{2}}{z+x}=\frac{4}{z+x}$, which is minimized when $z=4$ and $x=\sqrt{12}$. Thus, our answer is $4-\sqrt{12}=4-2 \sqrt{3}$.
+3. [4] Find the rightmost non-zero digit of the expansion of (20)(13!).
+
+Answer: 6 We can rewrite this as $(10 * 2)(13 * 12 * 11 * 10 * 9 * 8 * 7 * 6 * 5 * 4 * 3 * 2 * 1)=$ $\left(10^{3}\right)(2 * 13 * 12 * 11 * 9 * 8 * 7 * 6 * 4 * 3)$; multiplying together the units digits for the terms not equal to 10 reveals that the rightmost non-zero digit is 6 .
+4. [4] Spencer is making burritos, each of which consists of one wrap and one filling. He has enough filling for up to four beef burritos and three chicken burritos. However, he only has five wraps for the burritos; in how many orders can he make exactly five burritos?
+Answer: 25 Spencer's burrito-making can include either 3, 2, or 1 chicken burrito; consequently, he has $\binom{5}{3}+\binom{5}{2}+\binom{5}{1}=25$ orders in which he can make burritos.
+5. [5] Rahul has ten cards face-down, which consist of five distinct pairs of matching cards. During each move of his game, Rahul chooses one card to turn face-up, looks at it, and then chooses another to turn face-up and looks at it. If the two face-up cards match, the game ends. If not, Rahul flips both cards face-down and keeps repeating this process. Initially, Rahul doesn't know which cards are which. Assuming that he has perfect memory, find the smallest number of moves after which he can guarantee that the game has ended.
+Answer: 4 Label the 10 cards $a_{1}, a_{2}, \ldots, a_{5}, b_{1}, b_{2}, \ldots, b_{5}$ such that $a_{i}$ and $b_{i}$ match for $1 \leq i \leq 5$.
+
+First, we'll show that Rahul cannot always end the game in less than 4 moves, in particular, when he turns up his fifth card (during the third move), it is possible that the card he flips over is not one which he has yet encountered; consequently, he will not guarantee being able to match it, so he cannot guarantee that the game can end in three moves.
+However, Rahul can always end the game in 4 moves. To do this, he can turn over 6 distinct cards in his first 3 moves. If we consider the 5 sets of cards $\left\{a_{1}, b_{1}\right\},\left\{a_{2}, b_{2}\right\},\left\{a_{3}, b_{3}\right\},\left\{a_{4}, b_{4}\right\},\left\{a_{5}, b_{5}\right\}$, then by the pigeonhole principle, at least 2 of the 6 revealed cards must be from the same set. Rahul can then turn over those 2 cards on the fourth move, ending the game.
+6. [5] Let $R$ be the region in the Cartesian plane of points $(x, y)$ satisfying $x \geq 0, y \geq 0$, and $x+y+$ $\lfloor x\rfloor+\lfloor y\rfloor \leq 5$. Determine the area of $R$.
+
+Answer: | $\frac{9}{2}$ |
+| :---: |
+| We claim that a point in the first quadrant satisfies the desired property if the point | is below the line $x+y=3$ and does not satisfy the desired property if it is above the line.
+
+To see this, for a point inside the region, $x+y<3$ and $\lfloor x\rfloor+\lfloor y\rfloor \leq x+y<3$ However, $\lfloor x\rfloor+\lfloor y\rfloor$ must equal to an integer. Thus, $\lfloor x\rfloor+\lfloor y\rfloor \leq 2$. Adding these two equations, $x+y+\lfloor x\rfloor+\lfloor y\rfloor<5$, which satisfies the desired property. Conversely, for a point outside the region, $\lfloor x\rfloor+\lfloor y\rfloor+\{x\}+\{y\}=x+y>3$ However, $\{x\}+\{y\}<2$. Thus, $\lfloor x\rfloor+\lfloor y\rfloor>1$, so $\lfloor x\rfloor+\lfloor y\rfloor \geq 2$, implying that $x+y+\lfloor x\rfloor+\lfloor y\rfloor>5$.
+
+To finish, $R$ is the region bounded by the x -axis, the y -axis, and the line $x+y=3$ is a right triangle whose legs have length 3 . Consequently, $R$ has area $\frac{9}{2}$.
+7. [5] Find the number of positive divisors $d$ of $15!=15 \cdot 14 \cdots 2 \cdot 1$ such that $\operatorname{gcd}(d, 60)=5$.
+
+Answer: 36 Since $\operatorname{gcd}(d, 60)=5$, we know that $d=5^{i} d^{\prime}$ for some integer $i>0$ and some integer $d^{\prime}$ which is relatively prime to 60 . Consequently, $d^{\prime}$ is a divisor of $(15!) / 5$; eliminating common factors with 60 gives that $d^{\prime}$ is a factor of $\left(7^{2}\right)(11)(13)$, which has $(2+1)(1+1)(1+1)=12$ factors. Finally, $i$ can be 1,2 , or 3 , so there are a total of $3 \cdot 12=36$ possibilities.
+8. [5] In a game, there are three indistinguishable boxes; one box contains two red balls, one contains two blue balls, and the last contains one ball of each color. To play, Raj first predicts whether he will draw two balls of the same color or two of different colors. Then, he picks a box, draws a ball at random, looks at the color, and replaces the ball in the same box. Finally, he repeats this; however, the boxes are not shuffled between draws, so he can determine whether he wants to draw again from the same box. Raj wins if he predicts correctly; if he plays optimally, what is the probability that he will win?
+
+Answer: | $\frac{5}{6}$ | Call the box with two red balls box 1, the box with one of each color box 2 , and the |
+| :---: | :---: | box with two blue balls box 3. Without loss of generality, assume that the first ball that Bob draws is red. If Bob picked box 1 , then he would have picked a red ball with probability 1 , and if Bob picked box 2 , then he would have picked a red ball with probability $\frac{1}{2}$. Therefore, the probability that he picked box 1 is $\frac{1}{1+\frac{1}{2}}=\frac{2}{3}$, and the probability that he picked box 2 is $\frac{1}{3}$. We will now consider both possible predictions and find which one gives a better probability of winning, assuming optimal play.
+
+If Bob predicts that he will draw two balls of the same color, then there are two possible plays: he draws from the same box, or he draws from a different box. If he draws from the same box, then in the $\frac{2}{3}$ chance that he originally picked box 1 , he will always win, and in the $\frac{1}{3}$ chance that he picked box 2 , he will win with probability $\frac{1}{2}$, for a total probability of $\frac{2}{3}+\frac{1}{3} \cdot \frac{1}{2}=\frac{5}{6}$. If he draws from a different box, then if he originally picked box 1 , he will win with probability $\frac{1}{4}$ and if he originally picked box 2 , he will win with probability $\frac{1}{2}$, for a total probability of $\frac{2}{3} \cdot \frac{1}{4}+\frac{1}{3} \cdot \frac{1}{2}=\frac{1}{3}$.
+
+If Bob predicts that he will draw two balls of different colors, then we can consider the same two possible plays. Using similar calculations, if he draws from the same box, then he will win with probability $\frac{1}{6}$, and if he draws from a different box, then he will win with probability $\frac{2}{3}$. Looking at all cases, Bob's best play is to predict that he will draw two balls of the same color and then draw the second ball from the same box, with a winning probability of $\frac{5}{6}$.
+9. [6] I have 8 unit cubes of different colors, which I want to glue together into a $2 \times 2 \times 2$ cube. How many distinct $2 \times 2 \times 2$ cubes can I make? Rotations of the same cube are not considered distinct, but reflections are.
+Answer: 1680 Our goal is to first pin down the cube, so it can't rotate. Without loss of generality, suppose one of the unit cubes is purple, and let the purple cube be in the top left front position. Now, look at the three positions that share a face with the purple cube. There are $\binom{7}{3}$ ways to pick the three cubes that fill those positions and two ways to position them that are rotationally distinct. Now, we've taken care of any possible rotations, so there are simply 4 ! ways to position the final four cubes. Thus, our answer is $\binom{7}{3} \cdot 2 \cdot 4!=1680$ ways.
+10. [6] Wesyu is a farmer, and she's building a cao (a relative of the cow) pasture. She starts with a triangle $A_{0} A_{1} A_{2}$ where angle $A_{0}$ is $90^{\circ}$, angle $A_{1}$ is $60^{\circ}$, and $A_{0} A_{1}$ is 1 . She then extends the pasture. First, she extends $A_{2} A_{0}$ to $A_{3}$ such that $A_{3} A_{0}=\frac{1}{2} A_{2} A_{0}$ and the new pasture is triangle $A_{1} A_{2} A_{3}$. Next, she extends $A_{3} A_{1}$ to $A_{4}$ such that $A_{4} A_{1}=\frac{1}{6} A_{3} A_{1}$. She continues, each time extending $A_{n} A_{n-2}$ to $A_{n+1}$ such that $A_{n+1} A_{n-2}=\frac{1}{2^{n}-2} A_{n} A_{n-2}$. What is the smallest $K$ such that her pasture never exceeds an area of $K$ ?
+Answer: $\sqrt{3}$ First, note that for any $i$, after performing the operation on triangle $A_{i} A_{i+1} A_{i+2}$, the resulting pasture is triangle $A_{i+1} A_{i+2} A_{i+3}$. Let $K_{i}$ be the area of triangle $A_{i} A_{i+1} A_{i+2}$. From
+$A_{n+1} A_{n-2}=\frac{1}{2^{n}-2} A_{n} A_{n-2}$ and $A_{n} A_{n+1}=A_{n} A_{n-2}+A_{n-2} A_{n+1}$, we have $A_{n} A_{n+1}=\left(1+\frac{1}{2^{n}-2}\right) A_{n} A_{n-2}$. We also know that the area of a triangle is half the product of its base and height, so if we let the base of triangle $A_{n-2} A_{n-1} A_{n}$ be $A_{n} A_{n-2}$, its area is $K_{n-2}=\frac{1}{2} h A_{n} A_{n-2}$. The area of triangle $A_{n-1} A_{n} A_{n+1}$ is $K_{n-1}=\frac{1}{2} h A_{n} A_{n+1}$. The $h$ 's are equal because the distance from $A_{n-1}$ to the base does not change.
+
+We now have $\frac{K_{n-1}}{K_{n-2}}=\frac{A_{n} A_{n+1}}{A_{n} A_{n-2}}=1+\frac{1}{2^{n}-2}=\frac{2^{n}-1}{2^{n}-2}$. Therefore, $\frac{K_{1}}{K_{0}}=\frac{3}{2}, \frac{K_{2}}{K_{0}}=\frac{K_{2}}{K_{1}} \frac{K_{1}}{K_{0}}=\frac{7}{6} \cdot \frac{3}{2}=\frac{7}{4}$, $\frac{K_{3}}{K_{0}}=\frac{K_{3}}{K_{2}} \frac{K_{2}}{K_{0}}=\frac{15}{14} \cdot \frac{7}{4}=\frac{15}{8}$. We see the pattern $\frac{K_{n}}{K_{0}}=\frac{2^{n+1}-1}{2^{n}}$, which can be easily proven by induction. As $n$ approaches infinity, $\frac{K_{n}}{K_{0}}$ grows arbitrarily close to 2 , so the smallest $K$ such that the pasture never exceeds an area of $K$ is $2 K_{0}=\sqrt{3}$.
+11. [6] Compute the prime factorization of 1007021035035021007001 . (You should write your answer in the form $p_{1}^{e_{1}} p_{2}^{e_{2}} \ldots p_{k}^{e_{k}}$, where $p_{1}, \ldots, p_{k}$ are distinct prime numbers and $e_{1}, \ldots, e_{k}$ are positive integers.)
+Answer: $7^{7} \cdot 11^{7} \cdot 13^{7}$ The number in question is
+
+$$
+\sum_{i=0}^{7}\binom{7}{i} 1000^{i}=(1000+1)^{7}=1001^{7}=7^{7} \cdot 11^{7} \cdot 13^{7}
+$$
+
+12. [6] For how many integers $1 \leq k \leq 2013$ does the decimal representation of $k^{k}$ end with a 1 ?
+
+Answer: 202 We claim that this is only possible if $k$ has a units digit of 1 . Clearly, it is true in these cases. Additionally, $k^{k}$ cannot have a units digit of 1 when $k$ has a units digit of $2,4,5,6$, or 8 . If $k$ has a units digit of 3 or 7 , then $k^{k}$ has a units digit of 1 if and only if $4 \mid k$, a contradiction. Similarly, if $k$ has a units digit of 9 , then $k^{k}$ has a units digit of 1 if and only if $2 \mid k$, also a contradiction. Since there are 202 integers between 1 and 2013, inclusive, with a units digit of 1 , there are 202 such $k$ which fulfill our criterion.
+13. [8] Find the smallest positive integer $n$ such that $\frac{5^{n+1}+2^{n+1}}{5^{n}+2^{n}}>4.99$.
+
+Answer: 7 Writing $5^{n+1}=5 \cdot 5^{n}$ and $2^{n+1}=2 \cdot 2^{n}$ and cross-multiplying yields $0.01 \cdot 5^{n}>2.99 \cdot 2^{n}$, and re-arranging yields $(2.5)^{n}>299$. A straightforward calculation shows that the smallest $n$ for which this is true is $n=7$.
+14. [8] Consider triangle $A B C$ with $\angle A=2 \angle B$. The angle bisectors from $A$ and $C$ intersect at $D$, and the angle bisector from $C$ intersects $\overline{A B}$ at $E$. If $\frac{D E}{D C}=\frac{1}{3}$, compute $\frac{A B}{A C}$.
+Answer: $\quad \frac{7}{9} \quad$ Let $A E=x$ and $B E=y$. Using angle-bisector theorem on $\triangle A C E$ we have $x: D E=A C: D C$, so $A C=3 x$. Using some angle chasing, it is simple to see that $\angle A D E=\angle A E D$, so $A D=A E=x$. Then, note that $\triangle C D A \sim \triangle C E B$, so $y:(D C+D E)=x: D C$, so $y: x=1+\frac{1}{3}=\frac{4}{3}$, so $A B=x+\frac{4}{3} x=\frac{7}{3} x$. Thus the desired answer is $A B: A C=\frac{7}{3} x: 3 x=\frac{7}{9}$.
+15. [8] Tim and Allen are playing a match of tenus. In a match of tenus, the two players play a series of games, each of which is won by one of the two players. The match ends when one player has won exactly two more games than the other player, at which point the player who has won more games wins the match. In odd-numbered games, Tim wins with probability $3 / 4$, and in the even-numbered games, Allen wins with probability $3 / 4$. What is the expected number of games in a match?
+
+Answer: $\quad \frac{16}{3}$ Let the answer be $E$. If Tim wins the first game and Allen wins the second game or vice versa, which occurs with probability $(3 / 4)^{2}+(1 / 4)^{2}=5 / 8$, the expected number of additional games is just $E$, so the expected total number of games is $E+2$. If, on the other hand, one of Tim and Allen wins both of the first two games, with probability $1-(5 / 8)=3 / 8$, there are exactly 2 games in the match. It follows that
+
+$$
+E=\frac{3}{8} \cdot 2+\frac{5}{8} \cdot(E+2)
+$$
+
+and solving gives $E=\frac{16}{3}$.
+16. [8] The walls of a room are in the shape of a triangle $A B C$ with $\angle A B C=90^{\circ}, \angle B A C=60^{\circ}$, and $A B=6$. Chong stands at the midpoint of $B C$ and rolls a ball toward $A B$. Suppose that the ball bounces off $A B$, then $A C$, then returns exactly to Chong. Find the length of the path of the ball.
+Answer: $\quad 3 \sqrt{21}$ Let $C^{\prime}$ be the reflection of $C$ across $A B$ and $B^{\prime}$ be the reflection of $B$ across $A C^{\prime}$; note that $B^{\prime}, A, C$ are collinear by angle chasing. The image of the path under these reflections is just the line segment $M M^{\prime}$, where $M$ is the midpoint of $B C$ and $M^{\prime}$ is the midpoint of $B^{\prime} C^{\prime}$, so our answer is just the length of $M M^{\prime}$. Applying the Law of Cosines to triangle $M^{\prime} C^{\prime} M$, we have $M M^{\prime 2}=27+243-2 \cdot 3 \sqrt{3} \cdot 9 \sqrt{3} \cdot \frac{1}{2}=189$, so $M M^{\prime}=3 \sqrt{21}$.
+17. [11] The lines $y=x, y=2 x$, and $y=3 x$ are the three medians of a triangle with perimeter 1. Find the length of the longest side of the triangle.
+
+Answer: | $\frac{\sqrt{58}}{2+\sqrt{34}+\sqrt{58}}$ |
+| :---: | The three medians of a triangle contain its vertices, so the three vertices of the triangle are $(a, a),(b, 2 b)$ and $(c, 3 c)$ for some $a, b$, and $c$. Then, the midpoint of $(a, a)$ and $(b, 2 b)$, which is $\left(\frac{a+b}{2}, \frac{a+2 b}{2}\right)$, must lie along the line $y=3 x$. Therefore,
+
+$$
+\begin{aligned}
+\frac{a+2 b}{2} & =3 \cdot \frac{a+b}{2} \\
+a+2 b & =3 a+3 b \\
+-2 a & =b
+\end{aligned}
+$$
+
+Similarly, the midpoint of $(b, 2 b)$ and $(c, 3 c)$, which is $\left(\frac{b+c}{2}, \frac{2 b+3 c}{2}\right)$, must lie along the line $y=x$. Therefore,
+
+$$
+\begin{aligned}
+\frac{2 b+3 c}{2} & =\frac{b+c}{2} \\
+2 b+3 c & =b+c \\
+b & =-2 c \\
+c & =-\frac{1}{2} b=a
+\end{aligned}
+$$
+
+From this, three points can be represented as $(a, a),(-2 a,-4 a)$, and $(a, 3 a)$. Using the distance formula, the three side lengths of the triangle are $2|a|, \sqrt{34}|a|$, and $\sqrt{58}|a|$. Since the perimeter of the triangle is 1 , we find that $|a|=\frac{1}{2+\sqrt{34}+\sqrt{58}}$ and therefore the longest side length is $\frac{\sqrt{58}}{2+\sqrt{34}+\sqrt{58}}$.
+18. [11] Define the sequence of positive integers $\left\{a_{n}\right\}$ as follows. Let $a_{1}=1, a_{2}=3$, and for each $n>2$, let $a_{n}$ be the result of expressing $a_{n-1}$ in base $n-1$, then reading the resulting numeral in base $n$, then adding 2 (in base $n$ ). For example, $a_{2}=3_{10}=11_{2}$, so $a_{3}=11_{3}+2_{3}=6_{10}$. Express $a_{2013}$ in base ten.
+Answer: 23097 We claim that for nonnegative integers $m$ and for $0 \leq n<3 \cdot 2^{m}, a_{3 \cdot 2^{m}+n}=$ $\left(3 \cdot 2^{m}+n\right)(m+2)+2 n$. We will prove this by induction; the base case for $a_{3}=6$ (when $m=0$, $n=0$ ) is given in the problem statement. Now, suppose that this is true for some pair $m$ and $n$. We will divide this into two cases:
+
+- Case 1: $n<3 \cdot 2^{m}-1$. Then, we want to prove that this is true for $m$ and $n+1$. In particular, writing $a_{3 \cdot 2^{m}+n}$ in base $3 \cdot 2^{m}+n$ results in the digits $m+2$ and $2 n$. Consequently, reading it in base $3 \cdot 2^{m}+n+1$ gives $a_{3 \cdot 2^{m}+n+1}=2+\left(3 \cdot 2^{m}+n+1\right)(m+2)+2 n=\left(2 \cdot 2^{m}+n+1\right)(m+2)+2(n+1)$, as desired.
+- Case 2: $n=3 \cdot 2^{m}-1$. Then, we want to prove that this is true for $m+1$ and 0 . Similarly to the previous case, we get that $a_{3 \cdot 2^{m}+n+1}=a_{3 \cdot 2^{m+1}}=2+\left(3 \cdot 2^{m}+n+1\right)(m+2)+2 n=$ $2+\left(3 \cdot 2^{m+1}\right)(m+2)+2\left(3 \cdot 2^{m}-1\right)=\left(3 \cdot 2^{m+1}+0\right)((m+1)+2)+2(0)$, as desired.
+
+In both cases, we have proved our claim.
+19. [11] An isosceles trapezoid $A B C D$ with bases $A B$ and $C D$ has $A B=13, C D=17$, and height 3 . Let $E$ be the intersection of $A C$ and $B D$. Circles $\Omega$ and $\omega$ are circumscribed about triangles $A B E$ and $C D E$. Compute the sum of the radii of $\Omega$ and $\omega$.
+Answer: $\quad 39$ Let $\Omega$ have center $O$ and radius $R$ and let $\omega$ have center $P$ and radius $M$. Let $Q$ be the intersection of $A B$ and $O E$. Note that $O E$ is the perpendicular bisector of $A B$ because the trapezoid is isosceles. Also, we see $O E$ is the circumradius of $\Omega$. On the other hand, we know by similarity of $\triangle A E B$ and $\triangle C E D$ that $Q E=\frac{13}{13+17} \cdot 3=\frac{13}{30} \cdot 3$. And, because $B Q=13 / 2$ and is perpendicular to $O Q$, we can apply the Pythagorean theorem to $\triangle O Q B$ to see $O Q=\sqrt{R^{2}-\left(\frac{13}{2}\right)^{2}}$. Since $O E=O Q+Q E, R=\frac{13}{30} \cdot 3+\sqrt{R^{2}-\left(\frac{13}{2}\right)^{2}}$. Solving this equation for $R$ yields $R=\frac{13}{30} \cdot 39$. Since by similarity $M=\frac{17}{13} R$, we know $R+M=\frac{30}{13} R$, so $R+M=39$.
+20. [11] The polynomial $f(x)=x^{3}-3 x^{2}-4 x+4$ has three real roots $r_{1}, r_{2}$, and $r_{3}$. Let $g(x)=$ $x^{3}+a x^{2}+b x+c$ be the polynomial which has roots $s_{1}, s_{2}$, and $s_{3}$, where $s_{1}=r_{1}+r_{2} z+r_{3} z^{2}$, $s_{2}=r_{1} z+r_{2} z^{2}+r_{3}, s_{3}=r_{1} z^{2}+r_{2}+r_{3} z$, and $z=\frac{-1+i \sqrt{3}}{2}$. Find the real part of the sum of the coefficients of $g(x)$.
+Answer: -26 Note that $z=e^{\frac{2 \pi}{3} i}=\cos \frac{2 \pi}{3}+i \sin \frac{2 \pi}{3}$, so that $z^{3}=1$ and $z^{2}+z+1=0$. Also, $s_{2}=s_{1} z$ and $s_{3}=s_{1} z^{2}$.
+Then, the sum of the coefficients of $g(x)$ is $g(1)=\left(1-s_{1}\right)\left(1-s_{2}\right)\left(1-s_{3}\right)=\left(1-s_{1}\right)\left(1-s_{1} z\right)\left(1-s_{1} z^{2}\right)=$ $1-\left(1+z+z^{2}\right) s_{1}+\left(z+z^{2}+z^{3}\right) s_{1}^{2}-z^{3} s_{1}^{3}=1-s_{1}^{3}$.
+Meanwhile, $s_{1}^{3}=\left(r_{1}+r_{2} z+r_{3} z^{2}\right)^{3}=r_{1}^{3}+r_{2}^{3}+r_{3}^{3}+3 r_{1}^{2} r_{2} z+3 r_{1}^{2} r_{3} z^{2}+3 r_{2}^{2} r_{3} z+3 r_{2}^{2} r_{1} z^{2}+3 r_{3}^{2} r_{1} z+$ $3 r_{3}^{2} r_{2} z^{2}+6 r_{1} r_{2} r_{3}$.
+Since the real parts of both $z$ and $z^{2}$ are $-\frac{1}{2}$, and since all of $r_{1}, r_{2}$, and $r_{3}$ are real, the real part of $s_{1}^{3}$ is $r_{1}^{3}+r_{2}^{3}+r_{3}^{3}-\frac{3}{2}\left(r_{1}^{2} r_{2}+\cdots+r_{3}^{2} r_{2}\right)+6 r_{1} r_{2} r_{3}=\left(r_{1}+r_{2}+r_{3}\right)^{3}-\frac{9}{2}\left(r_{1}+r_{2}+r_{3}\right)\left(r_{1} r_{2}+r_{2} r_{3}+r_{3} r_{1}\right)+\frac{27}{2} r_{1} r_{2} r_{3}=$ $3^{3}-\frac{9}{2} \cdot 3 \cdot-4+\frac{27}{2} \cdot-4=27$.
+Therefore, the answer is $1-27=-26$.
+21. [14] Find the number of positive integers $j \leq 3^{2013}$ such that
+
+$$
+j=\sum_{k=0}^{m}\left((-1)^{k} \cdot 3^{a_{k}}\right)
+$$
+
+for some strictly increasing sequence of nonnegative integers $\left\{a_{k}\right\}$. For example, we may write $3=3^{1}$ and $55=3^{0}-3^{3}+3^{4}$, but 4 cannot be written in this form.
+Answer: $2^{2013}$ Clearly $m$ must be even, or the sum would be negative. Furthermore, if $a_{m} \leq 2013$, the sum cannot exceed $3^{2013}$ since $j=3^{a_{m}}+\sum_{k=0}^{m-1}\left((-1)^{k} \cdot 3^{a_{k}}\right) \leq 3^{a_{m}}$. Likewise, if $a_{m}>2013$, then the sum necessarily exceeds $3^{2013}$, which is not hard to see by applying the Triangle Inequality and summing a geometric series. Hence, the elements of $\left\{a_{k}\right\}$ can be any subset of $\{0,1, \ldots, 2013\}$ with an odd number of elements. Since the number of even-sized subsets is equal to the number of odd-sized elements, there are $\frac{2^{2014}}{2}=2^{2013}$ such subsets.
+Now, it suffices to show that given such an $\left\{a_{k}\right\}$, the value of $j$ can only be obtained in this way. Suppose for the the sake of contradiction that there exist two such sequences $\left\{a_{k}\right\}_{0 \leq k \leq m_{a}}$ and $\left\{b_{k}\right\}_{0 \leq k \leq m_{b}}$ which produce the same value of $j$ for $j$ positive or negative, where we choose $\left\{a_{k}\right\},\left\{b_{k}\right\}$ such that $\min \left(m_{a}, m_{b}\right)$ is as small as possible. Then, we note that since $3^{a_{0}}+3^{a_{1}}+\ldots+3^{\left(a_{\left.m_{a}-1\right)}\right.} \leq 3^{0}+3^{1}+$ $\ldots+3^{\left(a_{m_{a}-1}\right)}<2\left(3^{\left(a_{m_{a}}-1\right)}\right)$, we have that $\sum_{k=0}^{m_{a}}\left((-1)^{k} \cdot 3^{a_{k}}\right)>3^{\left(a_{\left.m_{a}-1\right)}\right)}$. Similarly, we get that $3^{\left(a_{m_{b}}-1\right)} \geq \sum_{k=0}^{m_{b}}\left((-1)^{k} \cdot 3^{a_{k}}\right)>3^{\left(m_{b}-1\right)}$; for the two to be equal, we must have $m_{a}=m_{b}$. However, this means that the sequences obtained by removing $a_{m_{a}}$ and $a_{m_{b}}$ from $\left\{a_{k}\right\}\left\{b_{k}\right\}$ have smaller maximum value but still produce the same alternating sum, contradicting our original assumption.
+22. [14] Sherry and Val are playing a game. Sherry has a deck containing 2011 red cards and 2012 black cards, shuffled randomly. Sherry flips these cards over one at a time, and before she flips each card over, Val guesses whether it is red or black. If Val guesses correctly, she wins 1 dollar; otherwise, she loses 1 dollar. In addition, Val must guess red exactly 2011 times. If Val plays optimally, what is her expected profit from this game?
+Answer: $\frac{1}{4023}$ We will prove by induction on $r+b$ that the expected profit for guessing if there are $r$ red cards, $b$ black cards, and where $g$ guesses must be red, is equal to $(b-r)+\frac{2(r-b)}{(r+b)} g$. It is not difficult to check that this holds in the cases $(r, b, g)=(1,0,0),(0,1,0),(1,0,1),(0,1,1)$. Then, suppose that this is true as long as the number of cards is strictly less than $r+b$; we will prove that it also holds true when there are $r$ red and $b$ blue cards.
+Let $f(r, b, g)$ be her expected profit under these conditions. If she guesses red, her expected profit is
+
+$$
+\frac{r}{r+b}(1+f(r-1, b, g-1))+\frac{b}{r+b}(-1+f(r, b-1, g-1))=(b-r)+\frac{2(r-b)}{(r+b)} g
+$$
+
+Similarly, if she guesses black, her expected profit is
+
+$$
+\frac{r}{r+b}(-1+f(r-1, b, g))+\frac{b}{r+b}(1+f(r, b-1, g))=(b-r)+\frac{2(r-b)}{(r+b)} g .
+$$
+
+Plugging in the our starting values gives an expected profit of $\frac{1}{4023}$.
+23. [14] Let $A B C D$ be a parallelogram with $A B=8, A D=11$, and $\angle B A D=60^{\circ}$. Let $X$ be on segment $C D$ with $C X / X D=1 / 3$ and $Y$ be on segment $A D$ with $A Y / Y D=1 / 2$. Let $Z$ be on segment $A B$ such that $A X, B Y$, and $D Z$ are concurrent. Determine the area of triangle $X Y Z$.
+Answer: $\frac{19 \sqrt{3}}{2}$ Let $A X$ and $B D$ meet at $P$. We have $D P / P B=D X / A B=3 / 4$. Now, applying
+Ceva's Theorem in triangle $A B D$, we see that
+
+$$
+\frac{A Z}{Z B}=\frac{D P}{P B} \cdot \frac{A Y}{Y D}=\frac{3}{4} \cdot \frac{1}{2}=\frac{3}{8}
+$$
+
+Now,
+
+$$
+\frac{[A Y Z]}{[A B C D]}=\frac{[A Y Z]}{2[A B D]}=\frac{1}{2} \cdot \frac{1}{3} \cdot \frac{3}{11}=\frac{1}{22},
+$$
+
+and similarly
+
+$$
+\frac{[D Y X]}{[A B C D]}=\frac{1}{2} \cdot \frac{2}{3} \cdot \frac{3}{4}=\frac{1}{4} .
+$$
+
+Also,
+
+$$
+\frac{[X C B Z]}{[A B C D]}=\frac{1}{2}\left(\frac{1}{4}+\frac{8}{11}\right)=\frac{43}{88}
+$$
+
+The area of $X Y Z$ is the rest of the fraction of the area of $A B C D$ not covered by the three above polygons, which by a straightforward calculation $19 / 88$ the area of $A B C D$, so our answer is
+
+$$
+8 \cdot 11 \cdot \sin 60^{\circ} \cdot \frac{19}{88}=\frac{19 \sqrt{3}}{2}
+$$
+
+24. [14] Given a point $p$ and a line segment $l$, let $d(p, l)$ be the distance between them. Let $A, B$, and $C$ be points in the plane such that $A B=6, B C=8, A C=10$. What is the area of the region in the $(x, y)$-plane formed by the ordered pairs $(x, y)$ such that there exists a point $P$ inside triangle $A B C$ with $d(P, A B)+x=d(P, B C)+y=d(P, A C)$ ?
+Answer: $\quad \frac{288}{5}$. Place $A B C$ in the coordinate plane so that $A=(0,6), B=(0,0), C=(8,0)$. Consider a point $P=(a, b)$ inside triangle $A B C$. Clearly, $d(P, A B)=a, d(P, B C)=b$. Now, we see
+that the area of triangle $A B C$ is $\frac{6.8}{2}=24$, but may also be computed by summing the areas of triangles $P A B, P B C, P C A$. The area of triangle $P A B$ is $\frac{6 \cdot a}{2}=3 a$, and similarly the area of triangle $P B C$ is $4 b$. Thus, it follows easily that $d(P, C A)=\frac{24-3 a-4 b}{5}$. Now, we have
+
+$$
+(x, y)=\left(\frac{24}{5}-\frac{8}{5} a-\frac{4}{b} b, \frac{24}{5}-\frac{3}{5} a-\frac{9}{5} b\right)
+$$
+
+The desired region is the set of $(x, y)$ obtained by those $(a, b)$ subject to the constraints $a \geq 0, b \geq$ $0,6 a+8 b \leq 48$.
+Consequently, our region is the triangle whose vertices are obtained by evaluating $(x, y)$ at the vertices $(a, b)$ of the triangle. To see this, let $f(a, b)$ output the corresponding $(x, y)$ according to the above. Then, we can write every point $P$ in $A B C$ as $P=m(0,0)+n(0,6)+p(8,0)$ for some $m+n+p=1$. Then, $f(P)=m f(0,0)+n f(0,6)+p f(8,0)=m\left(\frac{24}{5}, \frac{24}{5}\right)+n(-8,0)+p(0,-6)$, so $f(P)$ ranges over the triangle with those three vertices.
+Therefore, we need the area of the triangle with vertices $\left(\frac{24}{5}, \frac{24}{5}\right),(0,-6),(-8,0)$, which is easily computed (for example, using determinants) to be $\frac{288}{5}$.
+25. [17] The sequence $\left(z_{n}\right)$ of complex numbers satisfies the following properties:
+
+- $z_{1}$ and $z_{2}$ are not real.
+- $z_{n+2}=z_{n+1}^{2} z_{n}$ for all integers $n \geq 1$.
+- $\frac{z_{n+3}}{z_{n}^{2}}$ is real for all integers $n \geq 1$.
+- $\left|\frac{z_{3}}{z_{4}}\right|=\left|\frac{z_{4}}{z_{5}}\right|=2$.
+
+Find the product of all possible values of $z_{1}$.
+Answer: 65536 All complex numbers can be expressed as $r(\cos \theta+i \sin \theta)=r e^{i \theta}$. Let $z_{n}$ be $r_{n} e^{i \theta_{n}}$.
+$\frac{z_{n+3}}{z_{n}^{2}}=\frac{z_{n+2}^{2} z_{n+1}}{z_{n}^{2}}=\frac{z_{n+1}^{5} z_{n}^{2}}{z_{n}^{2}}=z_{n+1}^{5}$ is real for all $n \geq 1$, so $\theta_{n}=\frac{\pi k_{n}}{5}$ for all $n \geq 2$, where $k_{n}$ is an integer. $\theta_{1}+2 \theta_{2}=\theta_{3}$, so we may write $\theta_{1}=\frac{\pi k_{1}}{5}$ with $k_{1}$ an integer.
+$\frac{r_{3}}{r_{4}}=\frac{r_{4}}{r_{5}} \Rightarrow r_{5}=\frac{r_{4}^{2}}{r_{3}}=r_{4}^{2} r_{3}$, so $r_{3}=1 . \frac{r_{3}}{r_{4}}=2 \Rightarrow r_{4}=\frac{1}{2}, r_{4}=r_{3}^{2} r_{2} \Rightarrow r_{2}=\frac{1}{2}$, and $r_{3}=r_{2}^{2} r_{1} \Rightarrow r_{1}=4$.
+Therefore, the possible values of $z_{1}$ are the nonreal roots of the equation $x^{10}-4^{10}=0$, and the product of the eight possible values is $\frac{4^{10}}{4^{2}}=4^{8}=65536$. For these values of $z_{1}$, it is not difficult to construct a sequence which works, by choosing $z_{2}$ nonreal so that $\left|z_{2}\right|=\frac{1}{2}$.
+26. [17] Triangle $A B C$ has perimeter 1. Its three altitudes form the side lengths of a triangle. Find the set of all possible values of $\min (A B, B C, C A)$.
+Answer: $\quad\left(\frac{3-\sqrt{5}}{4}, \frac{1}{3}\right]$ Let $a, b, c$ denote the side lengths $B C, C A$, and $A B$, respectively. Without loss of generality, assume $a \leq b \leq c$; we are looking for the possible range of $a$.
+First, note that the maximum possible value of $a$ is $\frac{1}{3}$, which occurs when $A B C$ is equilateral. It remains to find a lower bound for $a$.
+Now rewrite $c=x a$ and $b=y a$, where we have $x \geq y \geq 1$. Note that for a non-equilateral triangle, $x>1$. The triangle inequality gives us $a+b>c$, or equivalently, $y>x-1$. If we let $K$ be the area, the condition for the altitudes gives us $\frac{2 K}{c}+\frac{2 K}{b}>\frac{2 K}{a}$, or equivalently, $\frac{1}{b}>\frac{1}{a}-\frac{1}{c}$, which after some manipulation yields $y<\frac{x}{x-1}$. Putting these conditions together yields $x-1<\frac{x}{x-1}$, and after rearranging and solving a quadratic, we get $x<\frac{3+\sqrt{5}}{2}$.
+
+We now use the condition $a(1+x+y)=1$, and to find a lower bound for $a$, we need an upper bound for $1+x+y$. We know that $1+x+y<1+x+\frac{x}{x-1}=x-1+\frac{1}{x-1}+3$.
+Now let $f(x)=x-1+\frac{1}{x-1}+3$. If $1
Team Round
+
+1. [10] Let $a$ and $b$ be real numbers such that $\frac{a b}{a^{2}+b^{2}}=\frac{1}{4}$. Find all possible values of $\frac{\left|a^{2}-b^{2}\right|}{a^{2}+b^{2}}$.
+
+Answer: $\frac{\sqrt{3}}{2}$ The hypothesis statement is equivalent to
+
+$$
+\begin{gathered}
+a^{2}+b^{2}=4 a b \\
+1:(a+b)^{2}=6 a b \\
+2:(a-b)^{2}=2 a b
+\end{gathered}
+$$
+
+Multiplying equations 1 and 2,
+
+$$
+\begin{aligned}
+& \left(a^{2}-b^{2}\right)^{2}=12(a b)^{2} \\
+& \left|a^{2}-b^{2}\right|= \pm \sqrt{12} a b
+\end{aligned}
+$$
+
+Since the left hand side and $a b$ are both positive,
+
+$$
+\begin{gathered}
+\left|a^{2}-b^{2}\right|=\sqrt{12} a b \\
+\frac{\left|a^{2}-b^{2}\right|}{a^{2}+b^{2}}=\frac{\sqrt{12} a b}{a^{2}+b^{2}}=\frac{\sqrt{12}}{4}=\frac{\sqrt{3}}{2}
+\end{gathered}
+$$
+
+(It is clear that such $a$ and $b$ exist: for example, we can take $a=1$ and solve for $b$ by way of the quadratic formula.)
+2. [15] A cafe has 3 tables and 5 individual counter seats. People enter in groups of size between 1 and 4 , inclusive, and groups never share a table. A group of more than 1 will always try to sit at a table, but will sit in counter seats if no tables are available. Conversely, a group of 1 will always try to sit at the counter first. One morning, $M$ groups consisting of a total of $N$ people enter and sit down. Then, a single person walks in, and realizes that all the tables and counter seats are occupied by some person or group. What is the minimum possible value of $M+N$ ?
+Answer: 16 We first show that $M+N \geq 16$. Consider the point right before the last table is occupied. We have two cases: first suppose there exists at least one open counter seat. Then, every table must contribute at least 3 to the value of $M+N$, because no groups of 1 will have taken a table with one of the counter seats open. By the end, the counter must contribute at least $5+2=7$ to $M+N$, as there must be at least two groups sitting at the counter. It follows that $M+N \geq 16$. For the second case, assume the counter is full right before the last table is taken. Then, everybody sitting at the counter must have entered as a singleton, since they entered when a table was still available. Consequently, the counter must contribute 10 to $M+N$, and each table contributes at least 2 , so once again $M+N \geq 16$.
+Now, $M+N=16$ is achievable with eight groups of one, who first fill the counter seats, then the three tables. Thus, our answer is 16 .
+3. [15] Let $A B C$ be a triangle with circumcenter $O$ such that $A C=7$. Suppose that the circumcircle of $A O C$ is tangent to $B C$ at $C$ and intersects the line $A B$ at $A$ and $F$. Let $F O$ intersect $B C$ at $E$. Compute BE.
+Answer: $E B=\frac{7}{2} \quad O$ is the circumcenter of $\triangle A B C \Longrightarrow A O=C O \Longrightarrow O C A=\angle O A C$. Because $A C$ is an inscribed arc of circumcircle $\triangle A O C, \angle O C A=\angle O F A$. Furthermore $B C$ is tangent to circumcircle $\triangle A O C$, so $\angle O A C=\angle O C B$. However, again using the fact that $O$ is the circumcenter of $\triangle A B C, \angle O C B=\angle O B C$.
+We now have that $C O$ bisects $\angle A C B$, so it follows that triangle $C A=C B$. Also, by AA similarity we have $E O B \sim E B F$. Thus, $E B^{2}=E O \cdot E F=E C^{2}$ by the similarity and power of a point, so $E B=B C / 2=A C / 2=7 / 2$.
+4. [20] Let $a_{1}, a_{2}, a_{3}, a_{4}, a_{5}$ be real numbers whose sum is 20 . Determine with proof the smallest possible value of
+
+$$
+\sum_{1 \leq i
Saturday 16 February 2013
HMIC
+
+1. [5] Let $\mathcal{S}$ be a set of size $n$, and $k$ be a positive integer. For each $1 \leq i \leq k n$, there is a subset $S_{i} \subset \mathcal{S}$ such that $\left|S_{i}\right|=2$. Furthermore, for each $e \in \mathcal{S}$, there are exactly $2 k$ values of $i$ such that $e \in S_{i}$. Show that it is possible to choose one element from $S_{i}$ for each $1 \leq i \leq k n$ such that every element of $\mathcal{S}$ is chosen exactly $k$ times.
+
+Answer: N/A Consider the undirected graph $G=(\mathcal{S}, E)$ where the elements of $\mathcal{S}$ are the vertices, and for each $1 \leq i \leq k n$, there is an edge between the two elements of $S_{i}$. (Note that there might be multiedges if two subsets are the same, but there are no self-loops.) Consider any connected component $C$ of $G$, which must be a $2 k$-regular graph, and because $2 k$ is even, $C$ has an Eulerian circuit. Pick an orientation of the circuit, and hence a direction for each edge in $C$. Then, for each $i$ such that the edge corresponding to $S_{i}$ is in $C$, pick the element that is pointed to by that edge. Since the circuit goes into each vertex of $C k$ times, each element in $C$ is picked exactly $k$ times as desired. Repeating for each connected component finishes the problem.
+2. [7] Find all functions $f: \mathbb{R} \rightarrow \mathbb{R}$ such that, for all real numbers $x, y$,
+
+$$
+(x-y)(f(x)-f(y))=f(x-f(y)) f(f(x)-y)
+$$
+
+Answer: $\quad f(x)=0, f(x)=x$ First, suppose that $f(0) \neq 0$. Then, by letting $x=y=0$, we get that either $f(f(0))$ or $f(-f(0))$ is zero. The former gives a contradiction by plugging in $x=f(0), y=0$ into the original equation. Thus, $f(-f(0))=0$.
+Now plugging in $x=0, y=-f(0)$ gives that $f(2 f(0))=f(0)$. Finally, we note that by symmetry of the left hand side of the functional equation, $f(x-f(y)) f(f(x)-y)=f(y-f(x)) f(f(y)-x)$, and letting $y=0$ and $x=2 f(0)$ we get $f(f(0)) f(f(0))=f(-f(0)) f(-f(0))=0$, giving and so $f(f(0)=0$, again a contradiction. Therefore, $f(0)=0$.
+Setting $y=0$ yields $x f(x)=f(x) f(f(x))$, so if $f(x) \neq 0$, then $f(f(x))=x$. On the other hand, setting $y=f(x)$ yields $(x-f(x))(f(x)-f(f(x))=f(x-f(f(x))) f(0)$, so in fact $f(f(x))=f(x) \rightarrow f(x)=x$. Thus, for all $x, f(x)=0$ or $f(x)=x$.
+Clearly, $f \equiv 0$ satisfies the original equation, so suppose there exists a non-zero $x$ with $f(x)=x$. Then, for all $y \neq x$, if $f(y) \neq 0$, the original equation yields $x(x-y)=x f(x-y)$. Thus, $f(x-y)=x-y$. Similarly, if $f(y)=y$, we find $(x-y)^{2}=f(x-y)^{2}$, so $f(x-y)=x-y$. It follows that $f$ must be the identity, which indeed is a solution to the original equation. The proof is complete.
+3. [8] Triangle $A B C$ is inscribed in a circle $\omega$ such that $\angle A=60^{\circ}$ and $\angle B=75^{\circ}$. Let the bisector of angle $A$ meet $B C$ and $\omega$ at $E$ and $D$, respectively. Let the reflections of $A$ across $D$ and $C$ be $D^{\prime}$ and $C^{\prime}$, respectively. If the tangent to $\omega$ at $A$ meets line $B C$ at $P$, and the circumcircle of $A P D^{\prime}$ meets line $A C$ at $F \neq A$, prove that the circumcircle of $C^{\prime} F E$ is tangent to $B C$ at $E$.
+Answer: N/A We will show that $C E^{2}=(C F)\left(C C^{\prime}\right)$. By a simple computation using the given angles, one may find that this is equivalent to $C F=A C-A B$, or $A F=2 A C-A B$.
+We compute $A F$ by trigonometry. Assume for simplicity that $A C=\frac{1}{2}$, so $A D^{\prime}=2 A D=2 A C=1$ because $\triangle A C D$ is isosceles by angle chasing. We first compute $P D^{\prime}$ by the law of cosines on triangle $A P D^{\prime}$, which yields $P D^{\prime 2}=A P^{2}+A D^{\prime 2}-2(A P)\left(A D^{\prime}\right) \cos 75=A P^{2}+1-2 A P \cos 75$. We may easily compute $A P$ by the law of sines in triangle $B A P$ to be $\frac{1}{\sqrt{2}}$. Thus, $P D^{\prime 2}=\frac{1}{2}+1-\sqrt{2} \frac{\sqrt{6}-\sqrt{2}}{4}=\frac{4-\sqrt{3}}{2}$. By the law of sines within the circumcircle of $A P D^{\prime} F$, we have $\frac{F D^{\prime}}{\sin 30}=\frac{P D^{\prime}}{\sin 75}$. From this, we find that $F D^{\prime}=\frac{P D^{\prime} \sin 30}{\sin 75}=\frac{4-\sqrt{3}}{\sqrt{2}+\sqrt{6}}$. Thus, we have by the law of cosines on triangle $D^{\prime} A F$ that $A F^{2}+$ $A D^{\prime 2}-2(A F)\left(A D^{\prime}\right) \cos 30=A F^{2}+1-\sqrt{3} A F=F D^{\prime 2}=\frac{4-\sqrt{3}}{4+2 \sqrt{3}}$. Finally, solving for $A F$ yields $A F=\frac{\sqrt{3} \pm(2 \sqrt{3}-3)}{2}$ from which we indeed get $A F=\frac{3-\sqrt{3}}{2}$ which equals $2 A C-A B$.
+4. [10] A subset $U \subset \mathbb{R}$ is open if for any $x \in U$, there exist real numbers $a, b$ such that $x \in(a, b) \subset U$. Suppose $S \subset \mathbb{R}$ has the property that any open set intersecting $(0,1)$ also intersects $S$. Let $T$ be a countable collection of open sets containing $S$. Prove that the intersection of all of the sets of $T$ is not a countable subset of $\mathbb{R}$.
+(A set $\Gamma$ is countable if there exists a bijective function $f: \Gamma \rightarrow \mathbb{Z}$.)
+Answer: N/A If $S$ is uncountable then we're done, so assume $S$ is countable. We may also assume that the supersets are a chain $V_{1} \supset V_{2} \supset V_{3} \supset \cdots$ by taking intersections.
+
+We will use the following fact from point set topology:
+If $K_{1} \supset K_{2} \supset \cdots$ is a sequence of nonempty compact sets, then their intersection is nonempty.
+Now, we construct an uncountable family of such sequences $K_{1} \supset K_{2} \supset \cdots$ such that $K_{i}$ is a nontrivial (i.e. $[a, b]$ with $b>a$ ) closed interval contained in $V_{i}$, and any two such sequences have disjoint intersection. The construction proceeds as follows. At each step, we choose out of countably many options one closed interval $K_{i+1} \subset K_{i}$.
+To choose $K_{1}$, we claim that there exist countably many disjoint closed intervals in $V_{1}$. To do this, choose an open interval in $V_{1}$ of length at most $1 / 2$, and take some closed interval inside it. In the remainder of $(0,1)$, which has measure at least $1 / 2$ and where $V_{1}$ is still dense, choose another open interval of length at most $1 / 4$, and a closed interval inside it. This process can be repeated indefinitely to find a countably infinite family of nontrivial disjoint closed intervals in $V_{1}$. Choose one of them to be $K_{1}$.
+Now, inductively apply this construction on $K_{i}$ to find countably many choices for $K_{i+1}$, all disjoint. As a result, we get a total of $\mathbb{N}^{\mathbb{N}}$, i.e. uncountably many, choices of sequences $K_{i}$ satisfying the given properties. Any pair of sequences eventually have disjoint $K_{i}$ after some point, so no two intersections will intersect. Thus we can choose a point out of the intersection of each $K_{i}$ sequence to find uncountably many points in the intersection of all the $V_{i}$, as desired.
+5. [12]
+(a) Given a finite set $X$ of points in the plane, let $f_{X}(n)$ be the largest possible area of a polygon with at most $n$ vertices, all of which are points of $X$. Prove that if $m, n$ are integers with $m \geq n>2$, then $f_{X}(m)+f_{X}(n) \geq f_{X}(m+1)+f_{X}(n-1)$.
+(b) Let $P_{0}$ be a 1-by-2 rectangle (including its interior), and inductively define the polygon $P_{i}$ to be the result of folding $P_{i-1}$ over some line that cuts $P_{i-1}$ into two connected parts. The diameter of a polygon $P_{i}$ is the maximum distance between two points of $P_{i}$. Determine the smallest possible diameter of $P_{2013}$.
+(In other words, given a polygon $P_{i-1}$, a fold of $P_{i-1}$ consists of a line $l$ dividing $P_{i-1}$ into two connected parts $A$ and $B$, and the folded polygon $P_{i}=A \cup B_{l}$, where $B_{l}$ is the reflection of $B$ over the line l.)
+
+Answer: N/A
+Note from http://artofproblemsolving.com/community/c129h529051p3039219, Minor slip: In Section 1.3, Case 2 (for $\# 5$ ), how are $B^{\prime}$ and $A^{\prime}$ defined exactly? Right now it's not clear to me that they have $m+1$ and $n-1$ vertices, respectively, since it's not always possible to find $B_{i}, B_{i^{\prime}}$ with $f\left(i^{\prime}\right)-f(i)=i^{\prime}-i$, is it? (The simplest counterexample is when $m=3, n=5$, and the $A_{j}, B_{k}$ are pairwise distinct.)
+[b]Edit:[/b] I think it should be $f\left(i^{\prime}\right)-f(i)=i^{\prime}-i+1$ (which is not hard to find using a discrete continuity argument) and then $B^{\prime}=B_{1} \ldots B_{i} A_{f(i)+1} \ldots A_{f\left(i^{\prime}\right)} B_{i^{\prime}+1} \ldots B_{m}\left(A^{\prime}\right.$ the complement of $\left.B^{\prime}\right)$, in which case everything seems to work out. (We are assuming at most two points lie between $B_{k}, B_{k+1}$ for all $k$; otherwise we can just use Case 1.) Thanks to Tim for clarifying most of this! I probably should have tried the $m=3, n=5$ case a little harder before posting this, since it generalizes fairly easily.
+
+## 1 Convexity of the largest area of a polygon function
+
+(a)
+
+Let $V$ be a finite set of points in the plane. Let $f_{V}$ be a function that takes integers $\geq 3$ as input, and outputs a polygon of largest area with vertices in $V$.
+
+Lemma 1.1. $\left[f_{V}(a+1)\right]+\left[f_{V}(a-1)\right] \leq 2\left[f_{V}(a)\right]$, where $[P]$ represents the area of polygon $P$.
+Proof. Let the vertices of $f_{V}(a+1)$ be $1_{a+1}, 2_{a+1} \ldots,(a+1)_{a+1}$, and let the vertices of $f_{v}(a-1)$ be $1_{a-1}, 2_{a-1}, \ldots,(a-1)_{a-1}$.
+Lemma 1.2. The collection of vertices
+
+$$
+W=\left(1_{a-1}, 2_{a-1}, \ldots(a-1)_{a-1}, 1_{a+1}, \ldots,(a+1)_{a+1}\right)
+$$
+
+. It's clear that $W \subset V$. are in convex configuration.
+Proof. Suppose that the vertex $s_{x} \in W$ (for some integers $x \in\{a-1, a+1\}, s$ ) is inside the convex hull of $W$. Then there exists a vertex $k$ on the convex hull of $W$ such that replacing vertex $s_{x}$ in $f_{V}(x)$ with $k$ increases the area of the polygon $f_{V}(x)$. However, $f_{V}(x)$ is defined to be the polygon with $x$ sides with maximum area. Contradiction. This proves Lemma 2.
+
+Therefore the vertices in $W$ are in convex configuration. Label them with $1,2, \ldots 2 a$ in clockwise order, starting from an arbitrary vertex. Let (2a) denote the vertex labeled (2a). (The vertex (1) will be shorthanded as 1 when there is no ambiguity).
+Lemma 1.3. We have the inequality
+
+$$
+\left[f_{V}(a+1)\right]+\left[f_{V}(a-1)\right] \leq[\mathcal{P} 1357 \ldots(2 a-1)]+[\mathcal{P} 2468 \ldots(2 a)] .
+$$
+
+(Throughout, the symbol $\mathcal{P}$ denotes an arbitrary polygon.)
+Proof. It suffices to show that
+
+$$
+\begin{aligned}
+& 2[\mathcal{P} 1234 \ldots(2 a)]-\left[f_{V}(a+1)\right]-\left[f_{V}(a-1)\right] \\
+& \geq 2[\mathcal{P} 1234 \ldots(2 a)]-[\mathcal{P} 1357 \ldots(2 a-1)]-[\mathcal{P} 2468 \ldots(2 a)] .
+\end{aligned}
+$$
+
+We will do this using the next few lemmas.
+Lemma 1.4. Let $x$ and $y$ be integers $\leq 2 a$. If ray $\overrightarrow{(x)(x+1)}$ intersects (or is parallel to) ray $\overrightarrow{(y)(y-1)}$. Then $[\mathcal{P}(x)(x+1)(x+2) \ldots(y-1)(y)] \geq[\Delta(x)(x+1)(x+2)]+[\Delta(x+1)(x+2)(x+3)]+\ldots+\Delta[(y-$ $2)(y-1)(y)]$ (where $(2 a+k)$ is equivalent to ( $k$ ) for all $k$ ).
+
+Proof. $[\mathcal{P}(x)(x+1)(x+2) \ldots(y-1)(y)]=[\triangle(x)(x+1)(x+2)]+[\triangle(x)(x+2)(x+3)]+\ldots+[\Delta(x)(y-1)(y)]$. Suppose ray $\overline{(x)(x+1)}$ intersects ray $\overline{(y)(y-1)}$ at point $D$, the convexity of $W$ tells us that all vertices in between $x$ and $y$ exclusive going clockwise from $x$ are contained inside triangle $(x) D(y)$. It follows that for any $x^{\prime}$ between $x$ and $y$ exclusive going clockwise from $x$, that $(x)$ is farther from line $\overline{\left(x^{\prime}\right)\left(x^{\prime}+1\right)}$ than $\left(x^{\prime}-1\right)$. Therefore
+
+$$
+\left[\Delta(x)\left(x^{\prime}\right)\left(x^{\prime}+1\right)\right] \leq\left[\triangle\left(x^{\prime}-1\right)\left(x^{\prime}\right)\left(x^{\prime}+1\right)\right] .
+$$
+
+Summing these relations over all $x$ in between $x$ and $y$ exclusive going clockwise from $x$ gives the statement of Lemma 4, as desired.
+An identical argument works if ray $\overline{(x)(x+1)}$ and ray $\overline{(y)(y-1)}$ are parallel, except instead of $D$, all the points between $x$ and $y$ are bounded by the two rays and the line $\overline{(x)(y)}$.
+This proves Lemma 4.
+
+Let $z$ and $s$ be integers such that $z \in\{a-1, a+1\}$ and both vertices $s_{z}$ and $(s+1)_{z}$ are adjacent vertices of $f_{V}(z) . u$ and $v$ are positive integers defined such that $s_{z}$ has label ( $u$ ) and $s_{z+1}$ has label (v).
+
+Lemma 1.5. Rays $\overrightarrow{(u)(u+1)}$ and $\overrightarrow{(v)(v-1)}$ intersect or are parallel to each other.
+Proof. Since $(u),(u+1),(v-1),(v)$ are in convex formation, then either $\overrightarrow{(u)(u+1)}$ and $\overrightarrow{(v)(v-1)}$ intersect or are parallel to each other, or else $\overrightarrow{(u+1)(u)}$ and $\overrightarrow{(v-1)(v)}$ intersect. If we suppose that the lemma statement does not hold for the sake of contradiction, then it follows that rays $\overrightarrow{(u+1)(u)}$ and $\overrightarrow{(v-1)(v)}$ must intersect. Let $Q$ be the collection of vertices between $v$ and $u$ in $W$, going clockwise, inclusive. Since $Q$ is in convex formation (it's a subset of $W$ ), and $\overrightarrow{(u+1)(u)}$ and $\overrightarrow{(v+1)(v)}$ intersect, it follows that $u+1$ is farther than $u$ from any line joining two vertices of $Q$. Therefore removing $s_{z}$ (which is the same vertex as $(u)$ ) from $f_{V}(z)$ and replacing it with vertex $(u+1)$ increases the area of $f_{V}(z)$, contradicting the assertion that $f_{V}(z)$ was the polygon of $z$ vertices with maximal area on the set $V$. Therefore Lemma 5 is proven.
+
+Lemma 5 allows us to apply Lemma 4 to the polygons formed by taking ( $\mathcal{P} 1234 \ldots(2 a)$ ) and subtracting out $\left.f_{V}(a+1)\right]$, as well as the polygons formed by taking $(\mathcal{P} 1234 \ldots(2 a))$ and subtracting out $f_{V}(a-1)$. Adding the results tells us that
+
+$$
+\begin{aligned}
+& 2[\mathcal{P} 1234 \ldots(2 a)]-\left[f_{V}(a+1)\right]-\left[f_{V}(a-1)\right] \\
+& \geq 2[\mathcal{P} 1234 \ldots(2 a)]-[\mathcal{P} 1357 \ldots(2 a-1)]-[\mathcal{P} 2468 \ldots(2 a)]
+\end{aligned}
+$$
+
+which is sufficient to prove Lemma 3.
+Since $(\mathcal{P} 135 \ldots(2 a-1)]),(\mathcal{P} 246 \ldots(2 a)) \leq f_{V}(a)$ since $(1),(2), \ldots(2 a) \in V$. Using this fact with Lemma 3, we have proven Lemma 1 as desired.
+
+Lemma 1.6. Any function $g$ from integers to real numbers that satisfies $g(x+1)+g(x-1) \leq 2 g(x)$ satisfies the inequality $g(x)+g(y) \leq g(x+1)+g(y-1)$ for $y-1 \geq x+1$, and is thus a convex function.
+
+Proof. We proceed by induction on $y-x$. When $y-x=2$, the problem is trivial.
+For $y-x>2$, note that $g(x)+g(x+2)+g(y)+g(y-2) \leq 2 g(x+1)+2 g(y-1)$, but the inductive statement shows that $g(x+2)+g(y-2) \geq g(x+1)+g(y-1)$. It follows that $g(x)+g(y) \leq g(x+1)+g(y-1)$, which completes our induction as desired.
+
+It follows from the preceding lemma that $f_{V}(a)$ is a convex function, as desired.
+
+## 2 Folding a paper
+
+Let the smallest diameter be $M$. We claim that $M$ is $\frac{\sqrt{2}}{2^{1006}}$. Let the $P_{0}$ be a 1 by 2 rectangle. For $0 \leq i \leq 2012$, polygon $P_{i+1}$ is polygon $P_{i}$ folded across line $l_{i}$. Line $l_{i}$ splits $P_{i}$ into $P_{i}^{\prime}$ and $P_{i}^{\prime \prime}$, and $P_{i}^{\prime \prime}$ is reflected to $P_{i}^{\prime \prime \prime}$, and $P_{i+1}=P_{i}^{\prime} \cup P_{i}^{\prime \prime \prime}$.
+Claim 1. For $1 \leq i \leq 2013, P_{i}$ can be expressed as the union of no more than $2^{i}$ convex polygons, and the average number of sides of these polygons is not more than 4 .
+
+Proof. We proceed by induction. $P_{0}$ clearly satisfies the inductive hypothesis. Suppose that $P_{i}$ is the union of convex polygons $A_{1}, A_{2}, \ldots A_{n}$. Folding $A_{1}, A_{2}, \ldots A_{n}$ across $l_{i}$ and taking the union of the resulting polygons yields $P_{i+1}$.
+Let $S(P)$ be the number of sides of polygon $P$.
+Lemma. A convex polygon $Z$ is folded once. $Z^{\prime}$ and $Z^{\prime \prime \prime}$ are convex, and $S\left(Z^{\prime}\right)+S\left(Z^{\prime \prime \prime}\right) \leq S(Z)+4$.
+
+Proof. Any line $l$ through $Z$ splits $Z$ into two convex polygons, and four new vertices are formed by $l$. The number of vertices in a convex polygon equals the number of sides, proving our lemma.
+
+Thus $P_{i+1}$ can be expressed as the union of no more than $2^{i+1}$ convex polygons, and the average number of sides of these convex polygons does not exceed 4. Claim 1 is proven.
+
+Claim 2. For a quadrilateral of area $A$, the diameter has length less than $\sqrt{2 A}$.
+Proof. Without loss of generality, let the fixed area be 1. The diagonal is not longer than the diameter of the quadrilateral. Half of the product of the diagonals is not less than the area, and Claim 2 follows.
+
+Claim 1 tells us that $P_{2013}$ the union of no more than $2^{2013}$ convex polygons, whose average number of sides is no more than 4. Part (a) of the problem tells us that there is some quadrilateral with area $\geq \frac{1}{2^{2012}}$, with vertices at the vertices of the final folded figure. Claim 2 tells us that the diameter of this quadrilateral, and thus of $P_{2013}$, is $\geq \frac{\sqrt{2}}{2^{1006}}$.
+
diff --git a/HarvardMIT/md/en-171-2013-nov-gen-solutions.md b/HarvardMIT/md/en-171-2013-nov-gen-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..6708851168ba73ece86b0b867cee746d52ecf163
--- /dev/null
+++ b/HarvardMIT/md/en-171-2013-nov-gen-solutions.md
@@ -0,0 +1,33 @@
+# HMMT November 2013
Saturday 9 November 2013
General Test
+
+
General Test}
+
+1. [2] What is the smallest non-square positive integer that is the product of four prime numbers (not necessarily distinct)?
+
+Answer: $\quad 24$ The smallest two integers that are the product of four primes are $2^{4}=16$ and $2^{3} \cdot 3=24$. Since 16 is a perfect square and 24 is not, the answer is 24 .
+2. [3] Plot points $A, B, C$ at coordinates $(0,0),(0,1)$, and $(1,1)$ in the plane, respectively. Let $S$ denote the union of the two line segments $A B$ and $B C$. Let $X_{1}$ be the area swept out when Bobby rotates $S$ counterclockwise 45 degrees about point $A$. Let $X_{2}$ be the area swept out when Calvin rotates $S$ clockwise 45 degrees about point $A$. Find $\frac{X_{1}+X_{2}}{2}$.
+Answer: $\sqrt{\frac{\pi}{4}}$ It's easy to see $X_{1}=X_{2}$. Simple cutting and pasting shows that $X_{1}$ equals the area of $\frac{1}{8}$ of a circle with radius $A C=\sqrt{2}$, so $\frac{X_{1}+X_{2}}{2}=X_{1}=\frac{1}{8} \pi(\sqrt{2})^{2}=\frac{\pi}{4}$.
+3. [4] A 24-hour digital clock shows times $h: m: s$, where $h, m$, and $s$ are integers with $0 \leq h \leq 23$, $0 \leq m \leq 59$, and $0 \leq s \leq 59$. How many times $h: m: s$ satisfy $h+m=s$ ?
+Answer: 1164 We are solving $h+m=s$ in $0 \leq s \leq 59,0 \leq m \leq 59$, and $0 \leq h \leq 23$. If $s \geq 24$, each $h$ corresponds to exactly 1 solution, so we get $24(59-23)=24(36)$ in this case. If $s \leq 23$, we want the number of nonnegative integer solutions to $h+m \leq 23$, which by lattice point counting (or balls and urns) is $\binom{23+2}{2}=(23+2)(23+1) / 2=25 \cdot 12$. Thus our total is $12(72+25)=12(100-3)=1164$.
+4. [4] A 50 -card deck consists of 4 cards labeled " $i$ " for $i=1,2, \ldots, 12$ and 2 cards labeled " 13 ". If Bob randomly chooses 2 cards from the deck without replacement, what is the probability that his 2 cards have the same label?
+Answer: $\frac{73}{1225}$ All pairs of distinct cards (where we distinguish cards even with the same label) are equally likely. There are $\binom{2}{2}+12\binom{4}{2}=73$ pairs of cards with the same label and $\binom{50}{2}=100 \cdot \frac{49}{4}=1225$ pairs of cards overall, so the desired probability is $\frac{73}{1225}$.
+5. [5] Let $A B C$ be an isosceles triangle with $A B=A C$. Let $D$ and $E$ be the midpoints of segments $A B$ and $A C$, respectively. Suppose that there exists a point $F$ on ray $\overrightarrow{D E}$ outside of $A B C$ such that triangle $B F A$ is similar to triangle $A B C$. Compute $\frac{A B}{B C}$.
+Answer: $\sqrt{2}$ Let $\alpha=\angle A B C=\angle A C B, A B=2 x$, and $B C=2 y$, so $A D=D B=A E=E C=x$ and $D E=y$. Since $\triangle B F A \sim \triangle A B C$ and $B A=A C$, we in fact have $\triangle B F A \cong \triangle A B C$, so $B F=B A=2 x, F A=2 y$, and $\angle D A F=\alpha$. But $D E \| B C$ yields $\angle A D F=\angle A B C=\alpha$ as well, whence $\triangle F A D \sim \triangle A B C$ gives $\frac{2 y}{x}=\frac{F A}{A D}=\frac{A B}{B C}=\frac{2 x}{2 y} \Longrightarrow \frac{A B}{B C}=\frac{x}{y}=\sqrt{2}$.
+6. [5] Find the number of positive integer divisors of 12 ! that leave a remainder of 1 when divided by 3 .
+
+Answer: 66 First we factor $12!=2^{10} 3^{5} 5^{2} 7^{1} 11^{1}$, and note that $2,5,11 \equiv-1(\bmod 3)$ while $7 \equiv 1$ $(\bmod 3)$. The desired divisors are precisely $2^{a} 5^{b} 7^{c} 11^{d}$ with $0 \leq a \leq 10,0 \leq b \leq 2,0 \leq c \leq 1,0 \leq d \leq 1$, and $a+b+d$ even. But then for any choice of $a, b$, exactly one $d \in\{0,1\}$ makes $a+b+d$ even, so we have exactly one $1(\bmod 3)$-divisor for every triple $(a, b, c)$ satisfying the inequality constraints. This gives a total of $(10+1)(2+1)(1+1)=66$.
+7. [6] Find the largest real number $\lambda$ such that $a^{2}+b^{2}+c^{2}+d^{2} \geq a b+\lambda b c+c d$ for all real numbers $a, b, c, d$.
+Answer: $\left.\begin{array}{|c}\frac{3}{2} \\ \text { Let } \\ \\ \hline\end{array} a, b, c, d\right)=\left(a^{2}+b^{2}+c^{2}+d^{2}\right)-(a b+\lambda b c+c d)$. For fixed $(b, c, d), f$ is minimized at $a=\frac{b}{2}$, and for fixed $(a, b, c), f$ is minimized at $d=\frac{c}{2}$, so simply we want the largest $\lambda$ such that $f\left(\frac{b}{2}, b, c, \frac{c}{2}\right)=\frac{3}{4}\left(b^{2}+c^{2}\right)-\lambda b c$ is always nonnegative. By AM-GM, this holds if and only if $\lambda \leq 2 \frac{3}{4}=\frac{3}{2}$.
+8. [6] How many of the first 1000 positive integers can be written as the sum of finitely many distinct numbers from the sequence $3^{0}, 3^{1}, 3^{2}, \ldots$ ?
+Answer: 105 We want to find which integers have only 0's and 1's in their base 3 representation. Note that $1000_{10}=1101001_{3}$. We can construct a bijection from all such numbers to the binary strings, by mapping $x_{3} \leftrightarrow x_{2}$. Since $1101001_{2}=105_{10}$, we conclude that the answer is 105 .
+9. [7] Let $A B C$ be a triangle and $D$ a point on $B C$ such that $A B=\sqrt{2}, A C=\sqrt{3}, \angle B A D=30^{\circ}$, and $\angle C A D=45^{\circ}$. Find $A D$.
+Answer: $\quad \frac{\sqrt{6}}{2}$ OR $\frac{\sqrt{3}}{\sqrt{2}}$ Note that $[B A D]+[C A D]=[A B C]$. If $\alpha_{1}=\angle B A D, \alpha_{2}=\angle C A D$, then we deduce $\frac{\sin \left(\alpha_{1}+\alpha_{2}\right)}{A D}=\frac{\sin \alpha_{1}}{A C}+\frac{\sin \alpha_{2}}{A B}$ upon division by $A B \cdot A C \cdot A D$. Now
+
+$$
+A D=\frac{\sin \left(30^{\circ}+45^{\circ}\right)}{\frac{\sin 30^{\circ}}{\sqrt{3}}+\frac{\sin 45^{\circ}}{\sqrt{2}}}
+$$
+
+But $\sin \left(30^{\circ}+45^{\circ}\right)=\sin 30^{\circ} \cos 45^{\circ}+\sin 45^{\circ} \cos 30^{\circ}=\sin 30^{\circ} \frac{1}{\sqrt{2}}+\sin 45^{\circ} \frac{\sqrt{3}}{2}=\frac{\sqrt{6}}{2}\left(\frac{\sin 30^{\circ}}{\sqrt{3}}+\frac{\sin 45^{\circ}}{\sqrt{2}}\right)$, so our answer is $\frac{\sqrt{6}}{2}$.
+10. [8] How many functions $f:\{1,2, \ldots, 2013\} \rightarrow\{1,2, \ldots, 2013\}$ satisfy $f(j)
Guts Round
+
+
Guts Round}
+
+1. [5] Evaluate $2+5+8+\cdots+101$.
+
+Answer: 1751 There are $\frac{102}{3}=34$ terms with average $\frac{2+101}{2}$, so their sum is $17 \cdot 103=1751$.
+2. [5] Two fair six-sided dice are rolled. What is the probability that their sum is at least 10 ?
+Answer: $\boxed{\frac{1}{6}}$ There are 3, 2, 1 outcomes with sum 10, 11, 12, so the probability is $\frac{3+2+1}{6^2}=\frac{1}{6}$.
+3. [5] A square is inscribed in a circle of radius 1. Find the perimeter of the square.
+
+Answer: $4 \sqrt{2}$ OR $\frac{8}{\sqrt{2}}$ The square has diagonal length 2 , so side length $\sqrt{2}$ and perimeter $4 \sqrt{2}$.
+4. [6] Find the minimum possible value of $\left(x^{2}+6 x+2\right)^{2}$ over all real numbers $x$.
+
+Answer: 0 This is $\left((x+3)^{2}-7\right)^{2} \geq 0$, with equality at $x+3= \pm \sqrt{7}$.
+5. [6] How many positive integers less than 100 are relatively prime to 200? (Two numbers are relatively prime if their greatest common factor is 1 .)
+Answer: $401 \leq n<100$ is relatively prime to 200 if and only if it's relatively prime to 100 $\left(200,100\right.$ have the same prime factors). Thus our answer is $\phi(100)=100 \frac{1}{2} \frac{4}{5}=40$.
+6. [6] A right triangle has area 5 and a hypotenuse of length 5 . Find its perimeter.
+
+Answer: $\quad 5+3 \sqrt{5}$ If $x, y$ denote the legs, then $x y=10$ and $x^{2}+y^{2}=25$, so $x+y+\sqrt{x^{2}+y^{2}}=$ $\sqrt{\left(x^{2}+y^{2}\right)+2 x y}+5=\sqrt{45}+5=5+3 \sqrt{5}$.
+7. [7] Marty and three other people took a math test. Everyone got a non-negative integer score. The average score was 20. Marty was told the average score and concluded that everyone else scored below average. What was the minimum possible score Marty could have gotten in order to definitively reach this conclusion?
+Answer: 61 Suppose for the sake of contradiction Marty obtained a score of 60 or lower. Since the mean is 20 , the total score of the 4 test takers must be 80 . Then there exists the possibility of 2 students getting 0 , and the last student getting a score of 20 or higher. If so, Marty could not have concluded with certainty that everyone else scored below average.
+With a score of 61 , any of the other three students must have scored points lower or equal to 19 points. Thus Marty is able to conclude that everyone else scored below average.
+8. [7] Evaluate the expression
+
+where the digit 2 appears 2013 times.
+Answer: $\frac{\frac{2013}{2014}}{}$ Let $f(n)$ denote the corresponding expression with the digit 2 appearing exactly $n$ times. Then $f(1)=\frac{1}{2}$ and for $n>1, f(n)=\frac{1}{2-f(n-1)}$. By induction using the identity $\frac{1}{2-\frac{N-1}{N}}=\frac{N}{N+1}$, $f(n)=\frac{n}{n+1}$ for all $n \geq 1$, so $f(2013)=\frac{2013}{2014}$.
+9. [7] Find the remainder when $1^{2}+3^{2}+5^{2}+\cdots+99^{2}$ is divided by 1000 .
+
+Answer: 650 We have $S=\sum_{i=0}^{49}(2 i+1)^{2}=\sum_{i=0}^{49} 4 i^{2}+4 i+1=4 \cdot \frac{49 \cdot 50 \cdot 99}{6}+4 \cdot \frac{49 \cdot 50}{2}+50 \equiv$ $700+900+50(\bmod 1000) \equiv 650(\bmod 1000)$.
+10. [8] How many pairs of real numbers $(x, y)$ satisfy the equation
+
+$$
+y^{4}-y^{2}=x y^{3}-x y=x^{3} y-x y=x^{4}-x^{2}=0 ?
+$$
+
+Answer: 9 We can see that if they solve the first and fourth equations, they are automatically solutions to the second and third equations. Hence, the solutions are just the $3^{2}=9$ points where $x, y$ can be any of $-1,0,1$.
+11. [8] David has a unit triangular array of 10 points, 4 on each side. A looping path is a sequence $A_{1}, A_{2}, \ldots, A_{10}$ containing each of the 10 points exactly once, such that $A_{i}$ and $A_{i+1}$ are adjacent (exactly 1 unit apart) for $i=1,2, \ldots, 10$. (Here $A_{11}=A_{1}$.) Find the number of looping paths in this array.
+Answer: 60 There are $10 \cdot 2$ times as many loop sequences as loops. To count the number of loops, first focus on the three corners of the array: their edges are uniquely determined. It's now easy to see there are 3 loops (they form " $V$-shapes"), so the answer is $10 \cdot 2 \cdot 3=60$.
+12. [8] Given that $62^{2}+122^{2}=18728$, find positive integers $(n, m)$ such that $n^{2}+m^{2}=9364$.
+
+Answer: $(30,92)$ OR $(92,30)$ If $a^{2}+b^{2}=2 c$, then $\left(\frac{a+b}{2}\right)^{2}+\left(\frac{a-b}{2}\right)^{2}=\frac{2 a^{2}+2 b^{2}}{4}=\frac{a^{2}+b^{2}}{2}=c$. Thus, $n=\frac{62+122}{2}=92$ and $m=\frac{122-62}{2}=30$ works.
+13. [9] Let $S=\{1,2, \ldots, 2013\}$. Find the number of ordered triples $(A, B, C)$ of subsets of $S$ such that $A \subseteq B$ and $A \cup B \cup C=S$.
+Answer: $5^{2013}$ OR $125^{671}$ Let $n=2013$. Each of the $n$ elements can be independently placed in 5 spots: there are $2^{3}-1$ choices with element $x$ in at least one set, and we subtract the $2^{1}$ choices with element $x$ in set $A$ but not $B$. Specifying where the elements go uniquely determines $A, B, C$, so there are $5^{n}=5^{2013}$ ordered triples.
+14. [9] Find all triples of positive integers $(x, y, z)$ such that $x^{2}+y-z=100$ and $x+y^{2}-z=124$.
+
+Answer: $(12,13,57)$ Cancel $z$ to get $24=(y-x)(y+x-1)$. Since $x, y$ are positive, we have $y+x-1 \geq 1+1-1>0$, so $0b>\frac{1}{2} a$. Place two squares of side lengths $a, b$ next to each other, such that the larger square has lower left corner at $(0,0)$ and the smaller square has lower left corner at $(a, 0)$. Draw the line passing through $(0, a)$ and $(a+b, 0)$. The region in the two squares lying above the line has area 2013. If $(a, b)$ is the unique pair maximizing $a+b$, compute $\frac{a}{b}$.
+Answer: $\quad \frac{5}{3}$ Let $t=\frac{a}{b} \in(1,2)$; we will rewrite the sum $a+b$ as a function of $t$. The area condition easily translates to $\frac{a^{2}-a b+2 b^{2}}{2}=2013$, or $b^{2}\left(t^{2}-t+2\right)=4026 \Longleftrightarrow b=\sqrt{\frac{4026}{t^{2}-t+2}}$. Thus $a+b$ is a function $f(t)=(1+t) \sqrt{\frac{4026}{t^{2}-t+2}}$ of $t$, and our answer is simply the value of $t$ maximizing $f$, or equivalently $g(t)=\frac{f^{2}}{4026}=\frac{(1+t)^{2}}{t^{2}-t+2}$, over the interval $(1,2)$. (In general, such maximizers/maximums need not exist, but we shall prove there's a unique maximum here.)
+We claim that $\lambda=\frac{16}{7}$ is the maximum of $\frac{(1+t)^{2}}{t^{2}-t+2}$. Indeed,
+
+$$
+\begin{aligned}
+\lambda-g(t) & =\frac{(\lambda-1) t^{2}-(\lambda+2) t+(2 \lambda-1)}{t^{2}-t+2} \\
+& =\frac{1}{7} \frac{9 t^{2}-30 t+25}{t^{2}-t+2}=\frac{1}{7} \frac{(3 t-5)^{2}}{\left(t-\frac{1}{2}\right)^{2}+\frac{7}{4}} \geq 0
+\end{aligned}
+$$
+
+for all reals $t$ (not just $t \in(1,2)$ ), with equality at $t=\frac{5}{3} \in(1,2)$.
+Comment. To motivate the choice of $\lambda$, suppose $\lambda$ were the maximum of $f$, attained at $t_{0} \in(1,2)$; then $h(t)=\lambda\left(t^{2}-t+2\right)-(t+1)^{2}$ is quadratic and nonnegative on $(1,2)$, but zero at $t=t_{0}$. If $g$ is a nontrivial quadratic (nonzero leading coefficient), then $t_{0}$ must be a double root, so $g$ has determinant 0 . Of course, $g$ could also be constant or linear over $(1,2)$, but we can easily rule out both of these possibilities.
+Alternatively, we can simply take a derivative of $f$ to find critical points.
+26. [13] Trapezoid $A B C D$ is inscribed in the parabola $y=x^{2}$ such that $A=\left(a, a^{2}\right), B=\left(b, b^{2}\right)$, $C=\left(-b, b^{2}\right)$, and $D=\left(-a, a^{2}\right)$ for some positive reals $a, b$ with $a>b$. If $A D+B C=A B+C D$, and $A B=\frac{3}{4}$, what is $a$ ?
+ $t^{2}=(a-b)^{2}\left[1+(a+b)^{2}\right]=(a-b)^{2}\left[1+t^{2}\right]$. Thus $a=\frac{t+\frac{t}{\sqrt{1+t^{2}}}}{2}=\frac{\frac{3}{4}+\frac{3}{5}}{2}=\frac{27}{40}$.
+27. [13] Find all triples of real numbers $(a, b, c)$ such that $a^{2}+2 b^{2}-2 b c=16$ and $2 a b-c^{2}=16$.
+
+Answer: $(4,4,4),(-4,-4,-4)$ (need both, but order doesn't matter) $a^{2}+2 b^{2}-2 b c$ and $2 a b-c^{2}$ are both homogeneous degree 2 polynomials in $a, b, c$, so we focus on the homogeneous equation $a^{2}+$ $2 b^{2}-2 b c=2 a b-c^{2}$, or $(a-b)^{2}+(b-c)^{2}=0$. So $a=b=c$, and $a^{2}=2 a b-c^{2}=16$ gives the solutions $(4,4,4)$ and $(-4,-4,-4)$.
+28. [15] Triangle $A B C$ has $A B=4, B C=3$, and a right angle at $B$. Circles $\omega_{1}$ and $\omega_{2}$ of equal radii are drawn such that $\omega_{1}$ is tangent to $A B$ and $A C, \omega_{2}$ is tangent to $B C$ and $A C$, and $\omega_{1}$ is tangent to $\omega_{2}$. Find the radius of $\omega_{1}$.
+ of $\omega_{1}$ and $\omega_{2}$ respectively. Suppose $\omega_{i}$ hits $A C$ at $B_{i}$ for $i=1,2$, so that $O_{1} O_{2}=B_{1} B_{2}=2 r$.
+
+Extend angle bisector $A O_{1}$ to hit $B C$ at $P$. By the angle bisector theorem and triangle similarity $\triangle A B_{1} O_{1} \sim \triangle A B P$, we deduce $\frac{r}{A B_{1}}=\frac{B P}{A B}=\frac{3}{4+5}$. Similarly, $\frac{r}{C B_{2}}=\frac{4}{3+5}$, so
+
+$$
+5=A C=A B_{1}+B_{1} B_{2}+B_{2} C=3 r+2 r+2 r=7 r
+$$
+
+or $r=\frac{5}{7}$.
+Solution 2. Use the same notation as in the previous solution, and let $\alpha=\frac{1}{2} \angle A$. By constructing right triangles with hypotenuses $A O_{1}, O_{1} O_{2}$, and $O_{2} C$ and legs parallel to $A B$ and $B C$, we obtain
+
+$$
+4=A B=r \cot \alpha+2 r \cos \angle A+r .
+$$
+
+But $\cot \alpha=\frac{1+\cos 2 \alpha}{\sin 2 \alpha}=\frac{1+\frac{4}{5}}{\frac{3}{5}}=3$ and $\cos \angle A=\frac{4}{5}$, so the above equation simplifies to
+
+$$
+4=r\left(3+\frac{8}{5}+1\right)=\frac{28 r}{5}
+$$
+
+or $r=\frac{5}{7}$.
+29. [15] Let $\triangle X Y Z$ be a right triangle with $\angle X Y Z=90^{\circ}$. Suppose there exists an infinite sequence of equilateral triangles $X_{0} Y_{0} T_{0}, X_{1} Y_{1} T_{1}, \ldots$ such that $X_{0}=X, Y_{0}=Y, X_{i}$ lies on the segment $X Z$ for all $i \geq 0, Y_{i}$ lies on the segment $Y Z$ for all $i \geq 0, X_{i} Y_{i}$ is perpendicular to $Y Z$ for all $i \geq 0, T_{i}$ and $Y$ are separated by line $X Z$ for all $i \geq 0$, and $X_{i}$ lies on segment $Y_{i-1} T_{i-1}$ for $i \geq 1$.
+Let $\mathcal{P}$ denote the union of the equilateral triangles. If the area of $\mathcal{P}$ is equal to the area of $X Y Z$, find $\frac{X Y}{Y Z}$.
+Answer: 1 For any region $R$, let $[R]$ denote its area.
+Let $a=X Y, b=Y Z, r a=X_{1} Y_{1}$. Then $[\mathcal{P}]=\left[X Y T_{0}\right]\left(1+r^{2}+r^{4}+\cdots\right),[X Y Z]=\left[X Y Y_{1} X_{1}\right](1+$ $\left.r^{2}+r^{4}+\cdots\right), Y Y_{1}=r a \sqrt{3}$, and $b=r a \sqrt{3}\left(1+r+r^{2}+\cdots\right)$ (although we can also get this by similar triangles).
+Hence $\frac{a^{2} \sqrt{3}}{4}=\frac{1}{2}(r a+a)(r a \sqrt{3})$, or $2 r(r+1)=1 \Longrightarrow r=\frac{\sqrt{3}-1}{2}$. Thus $\frac{X Y}{Y Z}=\frac{a}{b}=\frac{1-r}{r \sqrt{3}}=1$.
+30. [15] Find the number of ordered triples of integers $(a, b, c)$ with $1 \leq a, b, c \leq 100$ and $a^{2} b+b^{2} c+c^{2} a=$ $a b^{2}+b c^{2}+c a^{2}$.
+Answer: 29800 This factors as $(a-b)(b-c)(c-a)=0$. By the inclusion-exclusion principle, we get $3 \cdot 100^{2}-3 \cdot 100+100=29800$.
+31. [17] Chords $\overline{A B}$ and $\overline{C D}$ of circle $\omega$ intersect at $E$ such that $A E=8, B E=2, C D=10$, and $\angle A E C=90^{\circ}$. Let $R$ be a rectangle inside $\omega$ with sides parallel to $\overline{A B}$ and $\overline{C D}$, such that no point in the interior of $R$ lies on $\overline{A B}, \overline{C D}$, or the boundary of $\omega$. What is the maximum possible area of $R$ ?
+Answer: $\quad 26+6 \sqrt{17}$ By power of a point, $(C E)(E D)=(A E)(E B)=16$, and $C E+E D=C D=$ 10. Thus $C E, E D$ are 2, 8 . Without loss of generality, assume $C E=8$ and $D E=2$.
+
+Assume our circle is centered at the origin, with points $A=(-3,5), B=(-3,-5), C=(5,-3)$, $D=(-5,-3)$, and the equation of the circle is $x^{2}+y^{2}=34$. Clearly the largest possible rectangle must lie in the first quadrant, and if we let $(x, y)$ be the upper-right corner of the rectangle, then the area of the rectangle is $(x+3)(y+3)=9+6(x+y)+x y \leq 9+12 \sqrt{\frac{x^{2}+y^{2}}{2}}+\frac{x^{2}+y^{2}}{2}=26+6 \sqrt{17}$, where equality holds if and only if $x=y=\sqrt{17}$.
+32. [17] Suppose that $x$ and $y$ are chosen randomly and uniformly from $(0,1)$. What is the probability that $\left\lfloor\sqrt{\frac{x}{y}}\right\rfloor$ is even? Hint: $\sum_{n=1}^{\infty} \frac{1}{n^{2}}=\frac{\pi^{2}}{6}$.
+
+Answer: $1-\frac{\pi^{2}}{24}$ OR $\frac{24-\pi^{2}}{24}$ Note that for every positive integer $n$, the probability that $\left\lfloor\sqrt{\frac{x}{y}}\right\rfloor=n$ is just the area of the triangle formed between $(0,0),\left(1, \frac{1}{n^{2}}\right),\left(1, \frac{1}{(n+1)^{2}}\right)$, which is just $\frac{1}{2}\left(\frac{1}{n^{2}}-\frac{1}{(n+1)^{2}}\right)$.
+
+Thus the probability that $\left\lfloor\sqrt{\frac{x}{y}}\right\rfloor$ is odd is
+
+$$
+\begin{aligned}
+\sum_{k=1}^{\infty} \frac{1}{2}\left(\frac{1}{(2 k-1)^{2}}-\frac{1}{(2 k)^{2}}\right) & =\frac{1}{2} \sum_{k=1}^{\infty}\left(\frac{1}{(2 k-1)^{2}}+\frac{1}{(2 k)^{2}}\right)-\sum_{k=1}^{\infty} \frac{1}{(2 k)^{2}} \\
+& =\frac{1}{2} \sum_{n=1}^{\infty} \frac{1}{n^{2}}-\frac{1}{4} \sum_{k=1}^{\infty} \frac{1}{k^{2}} \\
+& =\frac{\pi^{2}}{12}-\frac{\pi^{2}}{24}=\frac{\pi^{2}}{24}
+\end{aligned}
+$$
+
+Thus our answer is just $1-\frac{\pi^{2}}{24}$.
+33. [17] On each side of a 6 by 8 rectangle, construct an equilateral triangle with that side as one edge such that the interior of the triangle intersects the interior of the rectangle. What is the total area of all regions that are contained in exactly 3 of the 4 equilateral triangles?
+Answer: $\frac{96 \sqrt{3}-154}{\sqrt{3}}$ OR $\frac{288-154 \sqrt{3}}{3}$ OR $96-\frac{154}{\sqrt{3}}$ OR $96-\frac{154 \sqrt{3}}{3}$ Let the rectangle be $A B C D$ with $A B=8$ and $B C=6$. Let the four equilateral triangles be $A B P_{1}, B C P_{2}, C D P_{3}$, and $D A P_{4}$ (for convenience, call them the $P_{1^{-}}, P_{2^{-}}, P_{3^{-}}, P_{4^{-}}$triangles). Let $W=A P_{1} \cap D P_{3}, X=A P_{1} \cap D P_{4}$, and $Y=D P_{4} \cap C P_{2}$. Reflect $X, Y$ over the line $P_{2} P_{4}$ (the line halfway between $A B$ and $D C$ ) to points $X^{\prime}, Y^{\prime}$.
+First we analyze the basic configuration of the diagram. Since $A B=8<2 \cdot 6 \frac{\sqrt{3}}{2}$, the $P_{2^{-}}, P_{4^{-}}$triangles intersect. Furthermore, $A P_{1} \perp B P_{2}$, so if $T=B P_{2} \cap A P_{1}$, then $B P_{2}=6<4 \sqrt{3}=B T$. Therefore $P_{2}$ lies inside triangle $P_{1} B A$, and by symmetry, also triangle $P_{3} D C$.
+It follows that the area we wish to compute is the union of two (congruent) concave hexagons, one of which is $W X Y P_{2} Y^{\prime} X^{\prime}$. (The other is its reflection over $Y Y^{\prime}$, the mid-line of $A D$ and $B C$.) So we seek
+
+$$
+2\left[W X Y P_{2} Y^{\prime} X^{\prime}\right]=2\left(\left[W X P_{4} X^{\prime}\right]-\left[P_{2} Y P_{4} Y^{\prime}\right]\right)
+$$
+
+It's easy to see that $\left[W X P_{4} X^{\prime}\right]=\frac{1}{3}\left[A D P_{4}\right]=\frac{1}{3} \frac{6^{2} \sqrt{3}}{4}=3 \sqrt{3}$, since $W X P_{4} X^{\prime}$ and its reflections over lines $D W X^{\prime}$ and $A W X$ partition $\triangle A D P_{4}$.
+It remains to consider $P_{2} Y P_{4} Y^{\prime}$, a rhombus with (perpendicular) diagonals $P_{2} P_{4}$ and $Y Y^{\prime}$. If $O$ denotes the intersection of these two diagonals (also the center of $A B C D$ ), then $O P_{2}$ is $P_{2} B \frac{\sqrt{3}}{2}-\frac{1}{2} A B=3 \sqrt{3}-4$, the difference between the lengths of the $P_{2}$-altitude in $\triangle C B P_{2}$ and the distance between the parallel lines $Y Y^{\prime}, C B$. Easy angle chasing gives $O Y=\frac{O P_{2}}{\sqrt{3}}$, so
+
+$$
+\left[P_{2} Y P_{4} Y^{\prime}\right]=4 \cdot \frac{O P_{2} \cdot O Y}{2}=\frac{2}{\sqrt{3}} O P_{2}^{2}=\frac{2}{\sqrt{3}}(3 \sqrt{3}-4)^{2}=\frac{86-48 \sqrt{3}}{\sqrt{3}}
+$$
+
+and our desired area is
+
+$$
+2\left[W X P_{4} X^{\prime}\right]-2\left[P_{2} Y P_{4} Y^{\prime}\right]=6 \sqrt{3}-\frac{172-96 \sqrt{3}}{\sqrt{3}}=\frac{96 \sqrt{3}-154}{\sqrt{3}}
+$$
+
+or $\frac{288-154 \sqrt{3}}{3}$.
+34. [20] Find the number of positive integers less than 1000000 that are divisible by some perfect cube greater than 1. Your score will be $\max \left\{0,\left\lfloor 20-200\left|1-\frac{k}{S}\right|\right\rfloor\right\}$, where $k$ is your answer and $S$ is the actual answer.
+Answer: 168089 Using the following code, we get the answer (denoted by the variable ans):
+ans $=0$
+for $n$ in xrange $(1,1000000)$ :
+
+```
+ divisible_by_cube = True
+ for i in xrange(2,101):
+ if n%(i*i*i)==0:
+ divisible_by_cube = False
+ break
+ if divisible_by_cube: ans = ans + 1
+print ans
+```
+
+This gives the output
+168089
+Alternatively, let $N=1000000$ and denote by $P$ the set of primes. Then by PIE, the number of $n \in(0, N)$ divisible by a nontrivial cube, or equivalently, by $p^{3}$ for some $p \in P$, is
+
+$$
+\sum_{p \in P}\left\lfloor\frac{N-1}{p^{3}}\right\rfloor-\sum_{p
(N-1)^{1 / 3}} k^{-3}<(N-1)\left[(N-1)^{-1}+\int_{(N-1)^{1 / 3}}^{\infty} x^{-3} d x\right]=1+(N-1) \frac{(N-1)^{-2 / 3}}{2}=$ $O\left(N^{1 / 3}\right)$, for the remaining terms.
+
+So we are really interested in $10^{6}-10^{6} \prod_{p \in P}\left(1-p^{-3}\right)$ (which, for completeness, is $168092.627 \ldots$. . There are a few simple ways to approximate this:
+
+- We can use a partial product of $\prod_{p \in P}\left(1-p^{-3}\right)$. Using just $1-2^{-3}=0.875$ gives an answer of 125000 (this is also just the number of $x \leq N$ divisible by $\left.2^{3}=8\right),\left(1-2^{-3}\right)\left(1-3^{-3}\right) \approx 0.843$ gives 157000 (around the number of $x$ divisible by $2^{3}$ or $3^{3}$ ), etc. This will give a lower bound, of course, so we can guess a bit higher. For instance, while 157000 gives a score of around 7 , rounding up to 160000 gives $\approx 10$.
+- We can note that $\prod_{p \in P}\left(1-p^{-3}\right)=\zeta(3)^{-1}$ is the inverse of $1+2^{-3}+3^{-3}+\cdots$. This is a bit less efficient, but successive partial sums (starting with $1+2^{-3}$ ) give around 111000, 139000, 150000, 157000 , etc. Again, this gives a lower bound, so we can guess a little higher.
+- We can optimize the previous approach with integral approximation after the $r$ th term: $\zeta(3)$ is the sum of $1+2^{-3}+\cdots+r^{-3}$ plus something between $\int_{r+1}^{\infty} x^{-3} d x=\frac{1}{2}(r+1)^{-2}$ and $\int_{r}^{\infty} x^{-3} d x=$ $\frac{1}{2} r^{-2}$. Then starting with $r=1$, we get intervals of around $(111000,334000),(152000,200000)$, $(161000,179000),(165000,173000)$, etc. Then we can take something like the average of the two endpoints as our guess; such a strategy gets a score of around 10 for $r=2$ already, and $\approx 17$ for $r=3$.
+
+35. [20] Consider the following 4 by 4 grid with one corner square removed:
+
+You may start at any square in this grid and at each move, you may either stop or travel to an adjacent square (sharing a side, not just a corner) that you have not already visited (the square you start at is automatically marked as visited). Determine the distinct number of paths you can take. Your score will be max $\left\{0,\left\lfloor 20-200\left|1-\frac{k}{S}\right|\right\rfloor\right\}$, where $k$ is your answer and $S$ is the actual answer.
+Answer: 14007
+36. [20] Pick a subset of at least four of the following seven numbers, order them from least to greatest, and write down their labels (corresponding letters from A through G) in that order: (A) $\pi$; (B) $\sqrt{2}+\sqrt{3} ;(\mathrm{C}) \sqrt{10}$; (D) $\frac{355}{113}$; (E) $16 \tan ^{-1} \frac{1}{5}-4 \tan ^{-1} \frac{1}{240} ;(\mathrm{F}) \ln (23)$; and (G) $2^{\sqrt{e}}$. If the ordering of the numbers you picked is correct and you picked at least 4 numbers, then your score for this problem will be $(N-2)(N-3)$, where $N$ is the size of your subset; otherwise, your score is 0 .
+Answer: $F, G, A, D, E, B, C$ OR $F
Saturday 9 November 2013
Team Round
+
+
Team Round}
+
+1. [3] Tim the Beaver can make three different types of geometrical figures: squares, regular hexagons, and regular octagons. Tim makes a random sequence $F_{0}, F_{1}, F_{2}, F_{3}, \ldots$ of figures as follows:
+
+- $F_{0}$ is a square.
+- For every positive integer $i, F_{i}$ is randomly chosen to be one of the 2 figures distinct from $F_{i-1}$ (each chosen with equal probability $\frac{1}{2}$ ).
+- Tim takes 4 seconds to make squares, 6 to make hexagons, and 8 to make octagons. He makes one figure after another, with no breaks in between.
+
+Suppose that exactly 17 seconds after he starts making $F_{0}$, Tim is making a figure with $n$ sides. What is the expected value of $n$ ?
+Answer: 7 We write $F_{i}=n$ as shorthand for "the $i$ th figure is an $n$-sided polygon."
+If $F_{1}=8$, the $F_{2}=6$ or $F_{2}=4$. If $F_{2}=6$, Tim is making a 6 -gon at time 13 (probability contribution $1 / 4)$. If $F_{2}=4, F_{3}=6$ or $F_{3}=8$ will take the time 13 mark ( $1 / 8$ contribution each).
+If $F_{1}=6, F_{2}=8$ or $F_{2}=4$. If $F_{2}=8$, it takes the 13 mark $\left(1 / 4\right.$ contribution). If $F_{2}=4, F_{3}=6$ or $F_{3}=8$ will take the 13 mark ( $1 / 8$ contribution each).
+Thus, the expected value of the number of sides at time 13 is $0(4)+\left(\frac{1}{4}+\frac{1}{8}+\frac{1}{8}\right)(6)+\left(\frac{1}{8}+\frac{1}{4}+\frac{1}{8}\right)(8)=7$.
+2. [4] Gary plays the following game with a fair $n$-sided die whose faces are labeled with the positive integers between 1 and $n$, inclusive: if $n=1$, he stops; otherwise he rolls the die, and starts over with a $k$-sided die, where $k$ is the number his $n$-sided die lands on. (In particular, if he gets $k=1$, he will stop rolling the die.) If he starts out with a 6 -sided die, what is the expected number of rolls he makes?
+Answer: $\quad \frac{197}{60}$ If we let $a_{n}$ be the expected number of rolls starting with an $n$-sided die, we see immediately that $a_{1}=0$, and $a_{n}=1+\frac{1}{n} \sum_{i=1}^{n} a_{i}$ for $n>1$. Thus $a_{2}=2$, and for $n \geq 3$, $a_{n}=1+\frac{1}{n} a_{n}+\frac{n-1}{n}\left(a_{n-1}-1\right)$, or $a_{n}=a_{n-1}+\frac{1}{n-1}$. Thus $a_{n}=1+\sum_{i=1}^{n-1} \frac{1}{i}$ for $n \geq 2$, so $a_{6}=$ $1+\frac{60+30+20+15+12}{60}=\frac{197}{60}$.
+3. [6] The digits $1,2,3,4,5,6$ are randomly chosen (without replacement) to form the three-digit numbers $M=\overline{A B C}$ and $N=\overline{D E F}$. For example, we could have $M=413$ and $N=256$. Find the expected value of $M \cdot N$.
+Answer: 143745 By linearity of expectation and symmetry,
+
+$$
+\mathbb{E}[M N]=\mathbb{E}[(100 A+10 B+C)(100 D+10 E+F)]=111^{2} \cdot \mathbb{E}[A D]
+$$
+
+Since
+
+$$
+\mathbb{E}[A D]=\frac{(1+2+3+4+5+6)^{2}-\left(1^{2}+2^{2}+3^{2}+4^{2}+5^{2}+6^{2}\right)}{6 \cdot 5}=\frac{350}{30}
+$$
+
+our answer is $111 \cdot 35 \cdot 37=111 \cdot 1295=143745$.
+4. [4] Consider triangle $A B C$ with side lengths $A B=4, B C=7$, and $A C=8$. Let $M$ be the midpoint of segment $A B$, and let $N$ be the point on the interior of segment $A C$ that also lies on the circumcircle of triangle $M B C$. Compute $B N$.
+
+Answer: $\frac{\sqrt{210}}{4}$ OR $\frac{\sqrt{105}}{2 \sqrt{2}}$ Let $\angle B A C=\theta$. Then, $\cos \theta=\frac{4^{2}+8^{2}-7^{2}}{2 \cdot 4 \cdot 8}$. Since $A M=\frac{4}{2}=2$, and power of a point gives $A M \cdot A B=A N \cdot A C$, we have $A N=\frac{2 \cdot 4}{8}=1$, so $N C=8-1=7$. Law of cosines on triangle $B A N$ gives
+
+$$
+B N^{2}=4^{2}+1^{2}-2 \cdot 4 \cdot 1 \cdot \frac{4^{2}+8^{2}-7^{2}}{2 \cdot 4 \cdot 8}=17-\frac{16+15}{8}=15-\frac{15}{8}=\frac{105}{8}
+$$
+
+so $B N=\frac{\sqrt{210}}{4}$.
+5. [4] In triangle $A B C, \angle B A C=60^{\circ}$. Let $\omega$ be a circle tangent to segment $A B$ at point $D$ and segment $A C$ at point $E$. Suppose $\omega$ intersects segment $B C$ at points $F$ and $G$ such that $F$ lies in between $B$ and $G$. Given that $A D=F G=4$ and $B F=\frac{1}{2}$, find the length of $C G$.
+Answer: $\boxed{\frac{16}{5}}$ Let $x=CG$. First, by power of a point, $BD = \sqrt{BF(BF+FG)}=\frac{3}{2}$, and $C E=\sqrt{x(x+4)}$. By the law of cosines, we have
+
+$$
+\left(x+\frac{9}{2}\right)^{2}=\left(\frac{11}{2}\right)^{2}+(4+\sqrt{x(x+4)})^{2}-\frac{11}{2}(4+\sqrt{x(x+4)})
+$$
+
+which rearranges to $2(5 x-4)=5 \sqrt{x(x+4)}$. Squaring and noting $x>\frac{4}{5}$ gives $(5 x-16)(15 x-4)=$ $0 \Longrightarrow x=\frac{16}{5}$.
+6. [6] Points $A, B, C$ lie on a circle $\omega$ such that $B C$ is a diameter. $A B$ is extended past $B$ to point $B^{\prime}$ and $A C$ is extended past $C$ to point $C^{\prime}$ such that line $B^{\prime} C^{\prime}$ is parallel to $B C$ and tangent to $\omega$ at point $D$. If $B^{\prime} D=4$ and $C^{\prime} D=6$, compute $B C$.
+
+Answer: $\frac{24}{5}$ Let $x=A B$ and $y=A C$, and define $t>0$ such that $B B^{\prime}=t x$ and $C C^{\prime}=t y$. Then $10=B^{\prime} C^{\prime}=(1+t) \sqrt{x^{2}+y^{2}}, 4^{2}=t(1+t) x^{2}$, and $6^{2}=t(1+t) y^{2}$ (by power of a point), so $52=4^{2}+6^{2}=t(1+t)\left(x^{2}+y^{2}\right)$ gives $\frac{13}{25}=\frac{52}{10^{2}}=\frac{t(1+t)}{(1+t)^{2}}=\frac{t}{1+t} \Longrightarrow t=\frac{13}{12}$. Hence $B C=\sqrt{x^{2}+y^{2}}=$ $\frac{10}{1+t}=\frac{10}{25 / 12}=\frac{24}{5}$.
+7. [7] In equilateral triangle $A B C$, a circle $\omega$ is drawn such that it is tangent to all three sides of the triangle. A line is drawn from $A$ to point $D$ on segment $B C$ such that $A D$ intersects $\omega$ at points $E$ and $F$. If $E F=4$ and $A B=8$, determine $|A E-F D|$.
+
+Answer: $\frac{4}{\sqrt{5}}$ OR $\frac{4 \sqrt{5}}{5}$ Without loss of generality, $A, E, F, D$ lie in that order. Let $x=A E, y=D F$.
+By power of a point, $x(x+4)=4^{2} \Longrightarrow x=2 \sqrt{5}-2$, and $y(y+4)=(x+4+y)^{2}-(4 \sqrt{3})^{2} \Longrightarrow y=$ $\frac{48-(x+4)^{2}}{2(x+2)}=\frac{12-(1+\sqrt{5})^{2}}{\sqrt{5}}$. It readily follows that $x-y=\frac{4}{\sqrt{5}}=\frac{4 \sqrt{5}}{5}$.
+8. [2] Define the sequence $\left\{x_{i}\right\}_{i \geq 0}$ by $x_{0}=x_{1}=x_{2}=1$ and $x_{k}=\frac{x_{k-1}+x_{k-2}+1}{x_{k-3}}$ for $k>2$. Find $x_{2013}$.
+
+Answer: 9 We have $x_{3}=\frac{1+1+1}{1}=3, x_{4}=\frac{3+1+1}{1}=5, x_{5}=\frac{5+3+1}{1}=9, x_{6}=\frac{9+5+1}{3}=5$. By the symmetry of our recurrence (or just further computation-it doesn't matter much), $x_{7}=3$ and $x_{8}=x_{9}=x_{10}=1$, so our sequence has period 8. Thus $x_{2013}=x_{13}=x_{5}=9$.
+9. [7] For an integer $n \geq 0$, let $f(n)$ be the smallest possible value of $|x+y|$, where $x$ and $y$ are integers such that $3 x-2 y=n$. Evaluate $f(0)+f(1)+f(2)+\cdots+f(2013)$.
+Answer: 2416 First, we can use $3 x-2 y=n$ to get $x=\frac{n+2 y}{3}$. Thus $|x+y|=\left|\frac{n+5 y}{3}\right|$. Given a certain $n$, the only restriction on $y$ is that $3|n+2 y \Longleftrightarrow 3| n+5 y$. Hence the set of possible $x+y$ equals the set of integers of the form $\frac{n+5 y}{3}$, which in turn equals the set of integers congruent to $3^{-1} n \equiv 2 n(\bmod 5)$. (Prove this!)
+Thus $f(n)=|x+y|$ is minimized when $x+y$ equals the least absolute remainder $(2 n)_{5}$ when $2 n$ is divided by 5 , i.e. the number between -2 and 2 (inclusive) congruent to $2 n$ modulo 5 . We immediately find $f(n)=f(n+5 m)$ for all integers $m$, and the following initial values of $f: f(0)=\left|(0)_{5}\right|=0$; $f(1)=\left|(2)_{5}\right|=2 ; f(2)=\left|(4)_{5}\right|=1 ; f(3)=\left|(6)_{5}\right|=1$; and $f(4)=\left|(8)_{5}\right|=2$.
+Since $2013=403 \cdot 5-2$, it follows that $f(0)+f(1)+\cdots+f(2013)=403[f(0)+f(1)+\cdots+f(4)]-f(2014)=$ $403 \cdot 6-2=2416$.
+10. [7] Let $\omega=\cos \frac{2 \pi}{727}+i \sin \frac{2 \pi}{727}$. The imaginary part of the complex number
+
+$$
+\prod_{k=8}^{13}\left(1+\omega^{3^{k-1}}+\omega^{2 \cdot 3^{k-1}}\right)
+$$
+
+is equal to $\sin \alpha$ for some angle $\alpha$ between $-\frac{\pi}{2}$ and $\frac{\pi}{2}$, inclusive. Find $\alpha$.
+Answer: $\frac{12 \pi}{727}$ Note that $727=3^{6}-2$. Our product telescopes to $\frac{1-\omega^{3^{13}}}{1-\omega^{3^{7}}}=\frac{1-\omega^{12}}{1-\omega^{6}}=1+\omega^{6}$, which has imaginary part $\sin \frac{12 \pi}{727}$, giving $\alpha=\frac{12 \pi}{727}$.
+
diff --git a/HarvardMIT/md/en-171-2013-nov-thm-solutions.md b/HarvardMIT/md/en-171-2013-nov-thm-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..7c1ec257a5b9fc531e04ee4eadb265e8ec00463c
--- /dev/null
+++ b/HarvardMIT/md/en-171-2013-nov-thm-solutions.md
@@ -0,0 +1,97 @@
+# HMMT November 2013
Saturday 9 November 2013
Theme Round
+
+1. [2] Two cars are driving directly towards each other such that one is twice as fast as the other. The distance between their starting points is 4 miles. When the two cars meet, how many miles is the faster car from its starting point?
+
+Answer: | $\frac{8}{3}$ |
+| :---: |
+| Note that the faster car traveled twice the distance of the slower car, and together, | the two cars traveled the total distance between the starting points, which is 4 miles. Let the distance that the faster car traveled be $x$. Then, $x+\frac{x}{2}=4 \Longrightarrow x=\frac{8}{3}$. Thus, the faster car traveled $\frac{8}{3}$ miles from the starting point.
+
+2. [4] You are standing at a pole and a snail is moving directly away from the pole at $1 \mathrm{~cm} / \mathrm{s}$. When the snail is 1 meter away, you start "Round 1 ". In Round $n(n \geq 1)$, you move directly toward the snail at $n+1 \mathrm{~cm} / \mathrm{s}$. When you reach the snail, you immediately turn around and move back to the starting pole at $n+1 \mathrm{~cm} / \mathrm{s}$. When you reach the pole, you immediately turn around and Round $n+1$ begins.
+At the start of Round 100, how many meters away is the snail?
+Answer: 5050 Suppose the snail is $x_{n}$ meters away at the start of round $n$, so $x_{1}=1$, and the runner takes $\frac{100 x_{n}}{(n+1)-1}=\frac{100 x_{n}}{n}$ seconds to catch up to the snail. But the runner takes the same amount of time to run back to the start, so during round $n$, the snail moves a distance of $x_{n+1}-x_{n}=\frac{200 x_{n}}{n} \frac{1}{100}=\frac{2 x_{n}}{n}$.
+Finally, we have $x_{100}=\frac{101}{99} x_{99}=\frac{101}{99} \frac{100}{98} x_{98}=\cdots=\frac{101!/ 2!}{99!} x_{1}=5050$.
+3. [5] Let $A B C$ be a triangle with $A B=5, B C=4$, and $C A=3$. Initially, there is an ant at each vertex. The ants start walking at a rate of 1 unit per second, in the direction $A \rightarrow B \rightarrow C \rightarrow A$ (so the ant starting at $A$ moves along ray $\overrightarrow{A B}$, etc.). For a positive real number $t$ less than 3 , let $A(t)$ be the area of the triangle whose vertices are the positions of the ants after $t$ seconds have elapsed. For what positive real number $t$ less than 3 is $A(t)$ minimized?
+
+Answer: | $\frac{47}{24}$ | We instead maximize the area of the remaining triangles. This area (using $\frac{1}{2} x y \sin \theta$ ) |
+| :---: | :---: | is $\frac{1}{2}(t)(5-t) \frac{3}{5}+\frac{1}{2}(t)(3-t) \frac{4}{5}+\frac{1}{2}(t)(4-t) 1=\frac{1}{10}\left(-12 t^{2}+47 t\right)$, which has a maximum at $t=\frac{47}{24} \in(0,3)$.
+
+4. [7] There are 2 runners on the perimeter of a regular hexagon, initially located at adjacent vertices. Every second, each of the runners independently moves either one vertex to the left, with probability $\frac{1}{2}$, or one vertex to the right, also with probability $\frac{1}{2}$. Find the probability that after a 2013 second run (in which the runners switch vertices 2013 times each), the runners end up at adjacent vertices once again.
+
+Answer: $\quad \frac{2}{3}+\frac{1}{3}\left(\frac{1}{4}\right)^{2013}$ OR $\frac{2^{4027}+1}{3 \cdot 2^{4026}}$ OR $\frac{2}{3}+\frac{1}{3}\left(\frac{1}{2}\right)^{4026}$ OR $\frac{2}{3}+\frac{1}{3}\left(\frac{1}{64}\right)^{671}$ Label the runners $A$ and $B$ and arbitrarily fix an orientation of the hexagon. Let $p_{t}(i)$ be the probability that $A$ is $i(\bmod 6)$ vertices to the right of $B$ at time $t$, so without loss of generality $p_{0}(1)=1$ and $p_{0}(2)=\cdots=p_{0}(6)=0$. Then for $t>0, p_{t}(i)=\frac{1}{4} p_{t-1}(i-2)+\frac{1}{2} p_{t-1}(i)+\frac{1}{4} p_{t-1}(i+2)$.
+In particular, $p_{t}(2)=p_{t}(4)=p_{t}(6)=0$ for all $t$, so we may restrict our attention to $p_{t}(1), p_{t}(3), p_{t}(5)$. Thus $p_{t}(1)+p_{t}(3)+p_{t}(5)=1$ for all $t \geq 0$, and we deduce $p_{t}(i)=\frac{1}{4}+\frac{1}{4} p_{t-1}(i)$ for $i=1,3,5$.
+Finally, let $f(t)=p_{t}(1)+p_{t}(5)$ denote the probability that $A, B$ are 1 vertex apart at time $t$, so $f(t)=\frac{1}{2}+\frac{1}{4} f(t-1) \Longrightarrow f(t)-\frac{2}{3}=\frac{1}{4}\left[f(t-1)-\frac{2}{3}\right]$, and we conclude that $f(2013)=\frac{2}{3}+\frac{1}{3}\left(\frac{1}{4}\right)^{2013}$.
+5. [7] Let $A B C$ be a triangle with $A B=13, B C=14, C A=15$. Company XYZ wants to locate their base at the point $P$ in the plane minimizing the total distance to their workers, who are located at vertices $A, B$, and $C$. There are 1,5 , and 4 workers at $A, B$, and $C$, respectively. Find the minimum possible total distance Company XYZ's workers have to travel to get to $P$.
+Answer: $\quad 69$ We want to minimize $1 \cdot P A+5 \cdot P B+4 \cdot P C$. By the triangle inequality, $(P A+$ $P B)+4(P B+P C) \geq A B+4 B C=13+56=69$, with equality precisely when $P=[A B] \cap[B C]=B$.
+6. [2] Evaluate 1201201-4.
+
+Answer: 2017 The answer is $1+2(-4)^{2}+(-4)^{3}+2(-4)^{5}+(-4)^{6}=1-2 \cdot 4^{2}+2 \cdot 4^{5}=2049-32=$ 2017.
+7. [3] Express -2013 in base -4 .
+
+Answer: $200203-2013 \equiv 3(\bmod 4)$, so the last digit is 3 ; now $\frac{-2013-3}{-4}=504 \equiv 0$, so the next digit (to the left) is 0 ; then $\frac{504-0}{-4}=-126 \equiv 2 ; \frac{-126-2}{-4}=32 \equiv 0 ; \frac{32-0}{-4}=-8 \equiv 0 ; \frac{-8-0}{-4}=2$.
+Thus $-2013_{10}=200203_{-4}$.
+8. [5] Let $b(n)$ be the number of digits in the base -4 representation of $n$. Evaluate $\sum_{i=1}^{2013} b(i)$.
+
+Answer: 12345 We have the following:
+
+- $b(n)=1$ for $n$ between 1 and 3 .
+- $b(n)=3$ for $n$ between $4^{2}-3 \cdot 4=4$ and $3 \cdot 4^{2}+3=51$. (Since $a \cdot 4^{2}-b \cdot 4+c$ takes on $3 \cdot 4 \cdot 4$ distinct values over $1 \leq a \leq 3,0 \leq b \leq 3,0 \leq c \leq 3$, with minimum 4 and maximum 51.)
+- $b(n)=5$ for $n$ between $4^{4}-3 \cdot 4^{3}-3 \cdot 4=52$ and $3 \cdot 4^{4}+3 \cdot 4^{2}+3=819$.
+- $b(n)=7$ for $n$ between $4^{6}-3 \cdot 4^{5}-3 \cdot 4^{3}-3 \cdot 4^{1}=820$ and $3 \cdot 4^{6}+3 \cdot 4^{4}+3 \cdot 4^{2}+3>2013$.
+
+Thus
+
+$$
+\sum_{i=1}^{2013} b(i)=7(2013)-2(819+51+3)=14091-2(873)=14091-1746=12345 .
+$$
+
+9. [7] Let $N$ be the largest positive integer that can be expressed as a 2013-digit base -4 number. What is the remainder when $N$ is divided by 210 ?
+Answer: 51 The largest is $\sum_{i=0}^{1006} 3 \cdot 4^{2 i}=3 \frac{16^{1007}-1}{16-1}=\frac{16^{1007}-1}{5}$.
+This is $1(\bmod 2), 0(\bmod 3), 3 \cdot 1007 \equiv 21 \equiv 1(\bmod 5)$, and $3\left(2^{1007}-1\right) \equiv 3\left(2^{8}-1\right) \equiv 3\left(2^{2}-1\right) \equiv 2$ $(\bmod 7)$, so we need $1(\bmod 10)$ and $9(\bmod 21)$, which is $9+2 \cdot 21=51(\bmod 210)$.
+10. [8] Find the sum of all positive integers $n$ such that there exists an integer $b$ with $|b| \neq 4$ such that the base -4 representation of $n$ is the same as the base $b$ representation of $n$.
+Answer: 1026 All 1 digit numbers, $0,1,2,3$, are solutions when, say, $b=5$. (Of course, $d \in$ $\{0,1,2,3\}$ works for any base $b$ of absolute value greater than $d$ but not equal to 4.)
+Consider now positive integers $n=\left(a_{d} \ldots a_{1} a_{0}\right)_{4}$ with more than one digit, so $d \geq 1, a_{d} \neq 0$, and $0 \leq a_{k} \leq 3$ for $k=0,1, \ldots, d$. Then $n$ has the same representation in base $b$ if and only if $|b|>\max a_{k}$ and $\sum_{k=0}^{d} a_{k}(-4)^{k}=\sum_{k=0}^{d} a_{k} b^{k}$, or equivalently, $\sum_{k=0}^{d} a_{k}\left(b^{k}-(-4)^{k}\right)=0$.
+First we prove that $b \leq 3$. Indeed, if $b \geq 4$, then $b \neq 4 \Longrightarrow b \geq 5$, so $b^{k}-(-4)^{k}$ is positive for all $k \geq 1$ (and zero for $k=0$ ). But then $\sum_{k=0}^{d} a_{k}\left(b^{k}-(-4)^{k}\right) \geq a_{d}\left(b^{d}-(-4)^{d}\right)$ must be positive, and cannot vanish.
+Next, we show $b \geq 2$. Assume otherwise for the sake of contradiction; $b$ cannot be $0, \pm 1$ (these bases don't make sense in general) or -4 , so we may label two distinct negative integers $-r,-s$ with $r-1 \geq s \geq 2$ such that $\{r, s\}=\{4,-b\}, s>\max a_{k}$, and $\sum_{k=0}^{d} a_{k}\left((-r)^{k}-(-s)^{k}\right)=0$, which, combined with the fact that $r^{k}-s^{k} \geq 0$ (equality only at $k=0$ ), yields
+
+$$
+\begin{aligned}
+r^{d}-s^{d} \leq a_{d}\left(r^{d}-s^{d}\right) & =\sum_{k=0}^{d-1}(-1)^{d-1-k} a_{k}\left(r^{k}-s^{k}\right) \\
+& \leq \sum_{k=0}^{d-1}(s-1)\left(r^{k}-s^{k}\right)=(s-1) \frac{r^{d}-1}{r-1}-\left(s^{d}-1\right)
+\end{aligned}
+$$
+
+Hence $r^{d}-1 \leq(s-1) \frac{r^{d}-1}{r-1}<(r-1) \frac{r^{d}-1}{r-1}=r^{d}-1$, which is absurd.
+
+Thus $b \geq 2$, and since $b \leq 3$ we must either have $b=2$ or $b=3$. In particular, all $a_{k}$ must be at most $b-1$. We now rewrite our condition as
+
+$$
+a_{d}\left(4^{d}-(-b)^{d}\right)=\sum_{k=0}^{d-1}(-1)^{d-1-k} a_{k}\left(4^{k}-(-b)^{k}\right)
+$$
+
+Since $4^{k}-(-b)^{k} \geq 0$ for $k \geq 0$, with equality only at $k=0$, we deduce
+
+$$
+a_{d}\left(4^{d}-(-b)^{d}\right) \leq \sum_{k \equiv d-1}(b-1)\left(4^{k}-(-b)^{k}\right)
+$$
+
+If $d-1$ is even ( $d$ is odd), this gives
+
+$$
+a_{d}\left(4^{d}+b^{d}\right) \leq(b-1) \frac{4^{d+1}-4^{0}}{4^{2}-1}-(b-1) \frac{b^{d+1}-b^{0}}{b^{2}-1}
+$$
+
+so $4^{d}<(b-1) \frac{4^{d+1}}{15} \Longrightarrow b>1+\frac{15}{4}$, which is impossible.
+Thus $d-1$ is odd ( $d$ is even), and we get
+
+$$
+a_{d}\left(4^{d}-b^{d}\right) \leq(b-1) \frac{4^{d+1}-4^{1}}{4^{2}-1}+(b-1) \frac{b^{d+1}-b^{1}}{b^{2}-1} \Longleftrightarrow \frac{b^{d}-1}{4^{d}-1} \geq \frac{a_{d}-\frac{4}{15}(b-1)}{a_{d}+\frac{b}{b+1}}
+$$
+
+If $b=2$, then $a_{d}=1$, so $\frac{1}{2^{d}+1}=\frac{2^{d}-1}{4^{d}-1} \geq \frac{11}{25}$, which is clearly impossible $(d \geq 2)$.
+If $b=3$ and $a_{d}=2$, then $\frac{9^{d / 2}-1}{16^{d / 2}-1} \leq \frac{8}{15}$. Since $d$ is even, it's easy to check this holds only for $d / 2=1$, with equality, so $a_{k}=b-1$ if $k \equiv d-1(\bmod 2)$. Thus $\left(a_{d}, \ldots, a_{0}\right)=\left(2,2, a_{0}\right)$, yielding solutions $(22 x)_{3}$ (which do work; note that the last digit doesn't matter).
+Otherwise, if $b=3$ and $a_{d}=14$, then $\frac{9^{d / 2}-1}{16^{d / 2}-1} \leq \frac{4}{15}$. It's easy to check $d / 2 \in\{1,2\}$.
+If $d / 2=1$, we're solving $16 a_{2}-4 a_{1}+a_{0}=9 a_{2}+3 a_{1}+a_{0} \Longleftrightarrow a_{2}=a_{1}$. We thus obtain the working solution $(11 x)_{3}$. (Note that $110=\frac{1}{2} 220$ in bases $-4,3$.)
+If $d / 2=2$, we want $256 a_{4}-64 a_{3}+16 a_{2}-4 a_{1}+a_{0}=81 a_{4}+27 a_{3}+9 a_{2}+3 a_{1}+a_{0}$, or $175=91 a_{3}-7 a_{2}+7 a_{1}$, which simplifies to $25=13 a_{3}-a_{2}+a_{1}$. This gives the working solutions $(1210 x)_{3},(1221 x)_{3}$. (Note that $12100=110^{2}$ and $12210=110^{2}+110$ in bases $-4,3$.)
+The list of all nontrivial ( $\geq 2$-digit) solutions (in base -4 and $b$ ) is then $11 x, 22 x, 1210 x, 1221 x$, where $b=3$ and $x \in\{0,1,2\}$. In base 10 , they are $12+x, 2 \cdot 12+x, 12^{2}+x, 12^{2}+12+x$, with sum $3\left(2 \cdot 12^{2}+4 \cdot 12\right)+4(0+1+2)=1020$.
+Finally, we need to include the trivial solutions $n=1,2,3$, for a total sum of 1026 .
+
diff --git a/HarvardMIT/md/en-172-2014-feb-alg-solutions.md b/HarvardMIT/md/en-172-2014-feb-alg-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..baf49350e7507485c5249e5ba10a0c547f62b54b
--- /dev/null
+++ b/HarvardMIT/md/en-172-2014-feb-alg-solutions.md
@@ -0,0 +1,190 @@
+## HMMT 2014
+
+## Saturday 22 February 2014
+
+## Algebra
+
+1. Given that $x$ and $y$ are nonzero real numbers such that $x+\frac{1}{y}=10$ and $y+\frac{1}{x}=\frac{5}{12}$, find all possible values of $x$.
+Answer: 4,6 OR 6,4 Let $z=\frac{1}{y}$. Then $x+z=10$ and $\frac{1}{x}+\frac{1}{z}=\frac{5}{12}$. Since $\frac{1}{x}+\frac{1}{z}=\frac{x+z}{x z}=\frac{10}{x z}$, we have $x z=24$. Thus, $x(10-x)=24$, so $x^{2}-10 x+24=(x-6)(x-4)=0$, whence $x=6$ or $x=4$.
+
+Alternate solution: Clearing denominators gives $x y+1=10 y$ and $y x+1=\frac{5}{12} x$, so $x=24 y$. Thus we want to find all real (nonzero) $x$ such that $\frac{x^{2}}{24}+1=\frac{5}{12} x$ (and for any such $x, y=x / 24$ will satisfy the original system of equations). This factors as $(x-4)(x-6)=0$, so precisely $x=4,6$ work.
+2. Find the integer closest to
+
+$$
+\frac{1}{\sqrt[4]{5^{4}+1}-\sqrt[4]{5^{4}-1}}
+$$
+
+Answer: 250 Let $x=\left(5^{4}+1\right)^{1 / 4}$ and $y=\left(5^{4}-1\right)^{1 / 4}$. Note that $x$ and $y$ are both approximately 5. We have
+
+$$
+\begin{aligned}
+\frac{1}{x-y} & =\frac{(x+y)\left(x^{2}+y^{2}\right)}{(x-y)(x+y)\left(x^{2}+y^{2}\right)}=\frac{(x+y)\left(x^{2}+y^{2}\right)}{x^{4}-y^{4}} \\
+& =\frac{(x+y)\left(x^{2}+y^{2}\right)}{2} \approx \frac{(5+5)\left(5^{2}+5^{2}\right)}{2}=250
+\end{aligned}
+$$
+
+Note: To justify the $\approx$, note that $1=x^{4}-5^{4}$ implies
+
+$$
+0
Guts
+
+1. [4] Compute the prime factorization of 159999.
+
+Answer: $3 \cdot 7 \cdot 19 \cdot 401$ We have $159999=160000-1=20^{4}-1=(20-1)(20+1)\left(20^{2}+1\right)=$ 3•7•19•401.
+2. [4] Let $x_{1}, \ldots, x_{100}$ be defined so that for each $i, x_{i}$ is a (uniformly) random integer between 1 and 6 inclusive. Find the expected number of integers in the set $\left\{x_{1}, x_{1}+x_{2}, \ldots, x_{1}+x_{2}+\ldots+x_{100}\right\}$ that are multiples of 6 .
+Answer: $\boxed{\frac{50}{3}}$ Note that for any $i$, the probability that $x_1 + x_2 + ... + x_i$ is a multiple of 6 is $\frac{1}{6}$ because exactly 1 value out of 6 possible values of $x_{i}$ works. Because these 100 events are independent, the expected value is $100 \cdot \frac{1}{6}=\frac{50}{3}$.
+3. [4] Let $A B C D E F$ be a regular hexagon. Let $P$ be the circle inscribed in $\triangle B D F$. Find the ratio of the area of circle $P$ to the area of rectangle $A B D E$.
+Answer: $\quad \frac{\pi \sqrt{3}}{12}$ Let the side length of the hexagon be $s$. The length of $B D$ is $s \sqrt{3}$, so the area of rectangle $A B D E$ is $s^{2} \sqrt{3}$. Equilateral triangle $B D F$ has side length $s \sqrt{3}$. The inradius of an equilateral triangle is $\sqrt{3} / 6$ times the length of its side, and so has length $\frac{s}{2}$. Thus, the area of circle $P$ is $\frac{\pi s^{2}}{4}$, so the ratio is $\frac{\pi s^{2} / 4}{s^{2} \sqrt{3}}=\frac{\pi \sqrt{3}}{12}$.
+4. [4] Let $D$ be the set of divisors of 100 . Let $Z$ be the set of integers between 1 and 100, inclusive. Mark chooses an element $d$ of $D$ and an element $z$ of $Z$ uniformly at random. What is the probability that $d$ divides $z$ ?
+Answer: $\frac{217}{900}$ As $100=2^{2} \cdot 5^{2}$, there are $3 \cdot 3=9$ divisors of 100 , so there are 900 possible pairs of $d$ and $z$ that can be chosen.
+If $d$ is chosen, then there are $\frac{100}{d}$ possible values of $z$ such that $d$ divides $z$, so the total number of valid pairs of $d$ and $z$ is $\sum_{d \mid 100} \frac{100}{d}=\sum_{d \mid 100} d=\left(1+2+2^{2}\right)\left(1+5+5^{2}\right)=7 \cdot 31=217$. The answer is therefore $\frac{217}{900}$.
+5. [5] If four fair six-sided dice are rolled, what is the probability that the lowest number appearing on any die is exactly 3 ?
+Answer: $175 / 1296$ The probability that all the die rolls are at least 3 is $\frac{4^{4}}{6}$. The probability they are all at least 4 is $\frac{3^{4}}{6}$. The probability of being in the former category but not the latter is thus $\frac{4}{6}^{4}-\frac{3}{6}^{4}=\frac{256-81}{1296}=\frac{175}{1296}$.
+6. [5] Find all integers $n$ for which $\frac{n^{3}+8}{n^{2}-4}$ is an integer.
+
+Answer: $0,1,3,4,6$ We have $\frac{n^{3}+8}{n^{2}-4}=\frac{(n+2)\left(n^{2}-2 n+4\right)}{(n+2)(n-2)}=\frac{n^{2}-2 n+4}{n-2}$ for all $n \neq-2$. Then $\frac{n^{2}-2 n+4}{n-2}=n+\frac{4}{n-2}$, which is an integer if and only if $\frac{4}{n-2}$ is an integer. This happens when $n-2=-4,-2,-1,1,2,4$, corresponding to $n=-2,0,1,3,4,6$, but we have $n \neq-2$ so the answers are $0,1,3,4,6$.
+7. [5] The Evil League of Evil is plotting to poison the city's water supply. They plan to set out from their headquarters at $(5,1)$ and put poison in two pipes, one along the line $y=x$ and one along the line $x=7$. However, they need to get the job done quickly before Captain Hammer catches them. What's the shortest distance they can travel to visit both pipes and then return to their headquarters?
+Answer: $4 \sqrt{5}$ After they go to $y=x$, we reflect the remainder of their path in $y=x$, along with the second pipe and their headquarters. Now, they must go from $(5,1)$ to $y=7$ crossing $y=x$,
+and then go to $(1,5)$. When they reach $y=7$, we reflect the remainder of their path again, so now their reflected headquarters is at $(1,9)$. Thus, they just go from $(5,1)$ to $(1,9)$ in some path that inevitably crosses $y=x$ and $y=7$. The shortest path they can take is a straight line with length $\sqrt{4^{2}+8^{2}}=4 \sqrt{5}$.
+Comment. These ideas can be used to prove that the orthic triangle of an acute triangle has the smallest possible perimeter of all inscribed triangles.
+Also, see if you can find an alternative solution using Minkowski's inequality!
+8. [5] The numbers $2^{0}, 2^{1}, \cdots, 2^{15}, 2^{16}=65536$ are written on a blackboard. You repeatedly take two numbers on the blackboard, subtract one from the other, erase them both, and write the result of the subtraction on the blackboard. What is the largest possible number that can remain on the blackboard when there is only one number left?
+Answer: 131069 If we reverse the order of the numbers in the final subtraction we perform, then the final number will be negated. Thus, the possible final numbers come in pairs with opposite signs. Therefore, the largest possible number is the negative of the smallest possible number. To get the smallest possible number, clearly we can take the smallest number originally on the board and subtract all of the other numbers from it (you can make this rigorous pretty easily if needed), so the smallest possible number is $1-\sum_{k=1}^{16} 2^{k}=1-131070=-131069$, and thus the largest possible number is 131069 .
+9. [6] Compute the side length of the largest cube contained in the region
+
+$$
+\left\{(x, y, z): x^{2}+y^{2}+z^{2} \leq 25 \text { and } x \geq 0\right\}
+$$
+
+of three-dimensional space.
+Answer: $\sqrt{\frac{5 \sqrt{6}}{3}}$ The given region is a hemisphere, so the largest cube that can fit inside it has one face centered at the origin and the four vertices of the opposite face on the spherical surface. Let the side length of this cube be $s$. Then, the radius of the circle is the hypotenuse of a triangle with side lengths $s$ and $\frac{\sqrt{2}}{2} s$. So, by the Pythagorean Theorem, the radius equals $\frac{\sqrt{6}}{2} s$. Since the radius of the hemisphere is 5 , the side length of the cube is $\frac{5 \sqrt{6}}{3}$.
+10. [6] Find the number of nonempty sets $\mathcal{F}$ of subsets of the set $\{1, \ldots, 2014\}$ such that:
+(a) For any subsets $S_{1}, S_{2} \in \mathcal{F}, S_{1} \cap S_{2} \in \mathcal{F}$.
+(b) If $S \in \mathcal{F}, T \subseteq\{1, \ldots, 2014\}$, and $S \subseteq T$, then $T \in \mathcal{F}$.
+
+Answer: $2^{2014}$ For a subset $S$ of $\{1, \ldots, 2014\}$, let $\mathcal{F}_{S}$ be the set of all sets $T$ such that $S \subseteq T \subseteq$ $\{1, \ldots, 2014\}$. It can be checked that the sets $\mathcal{F}_{S}$ satisfy the conditions 1 and 2 . We claim that the $\mathcal{F}_{S}$ are the only sets of subsets of $\{1, \ldots, 2014\}$ satisfying the conditions 1 and 2 . (Thus, the answer is the number of subsets $S$ of $\{1, \ldots, 2014\}$, which is $2^{2014}$.)
+Suppose that $\mathcal{F}$ satisfies the conditions 1 and 2 , and let $S$ be the intersection of all the sets of $\mathcal{F}$. We claim that $\mathcal{F}=\mathcal{F}_{S}$. First, by definition of $S$, all elements $T \in \mathcal{F}$ are supersets of $S$, so $\mathcal{F} \subseteq \mathcal{F}_{S}$. On the other hand, by iterating condition 1 , it follows that $S$ is an element of $\mathcal{F}$, so by condition 2 any set $T$ with $S \subseteq T \subseteq\{1, \ldots, 2014\}$ is an element of $\mathcal{F}$. So $\mathcal{F} \supseteq \mathcal{F}_{S}$. Thus $\mathcal{F}=\mathcal{F}_{S}$.
+11. [6] Two fair octahedral dice, each with the numbers 1 through 8 on their faces, are rolled. Let $N$ be the remainder when the product of the numbers showing on the two dice is divided by 8 . Find the expected value of $N$.
+Answer: $\frac{11}{4}$ If the first die is odd, which has $\frac{1}{2}$ probability, then $N$ can be any of $0,1,2,3$, $4,5,6,7$ with equal probability, because multiplying each element of $\{0, \ldots, 7\}$ with an odd number and taking modulo 8 results in the same numbers, as all odd numbers are relatively prime to 8 . The expected value in this case is 3.5 .
+
+If the first die is even but not a multiple of 4 , which has $\frac{1}{4}$ probability, then using similar reasoning, $N$ can be any of $0,2,4,6$ with equal probability, so the expected value is 3 .
+If the first die is 4 , which has $\frac{1}{8}$ probability, then $N$ can by any of 0,4 with equal probability, so the expected value is 2 .
+Finally, if the first die is 8 , which has $\frac{1}{8}$ probability, then $N=0$. The total expected value is $\frac{1}{2}(3.5)+$ $\frac{1}{4}(3)+\frac{1}{8}(2)+\frac{1}{8}(0)=\frac{11}{4}$.
+12. [6] Find a nonzero monic polynomial $P(x)$ with integer coefficients and minimal degree such that $P(1-\sqrt[3]{2}+\sqrt[3]{4})=0$. (A polynomial is called monic if its leading coefficient is 1.)
+Answer: $x^{3}-3 x^{2}+9 x-9$ Note that $(1-\sqrt[3]{2}+\sqrt[3]{4})(1+\sqrt[3]{2})=3$, so $1-\sqrt[3]{2}+\sqrt[3]{4}=\frac{3}{1+\sqrt[3]{2}}$.
+Now, if $f(x)=x^{3}-2$, we have $f(\sqrt[3]{2})=0$, so if we let $g(x)=f(x-1)=(x-1)^{3}-2=x^{3}-3 x^{2}+3 x-3$, then $g(1+\sqrt[3]{2})=f(\sqrt[3]{2})=0$. Finally, we let $h(x)=g\left(\frac{3}{x}\right)=\frac{27}{x^{3}}-\frac{27}{x^{2}}+\frac{9}{x}-3$ so $h\left(\frac{3}{1+\sqrt[3]{2}}\right)=g(1+\sqrt[3]{2})=0$. To make this a monic polynomial, we multiply $h(x)$ by $-\frac{x^{3}}{3}$ to get $x^{3}-3 x^{2}+9 x-9$.
+13. [8] An auditorium has two rows of seats, with 50 seats in each row. 100 indistinguishable people sit in the seats one at a time, subject to the condition that each person, except for the first person to sit in each row, must sit to the left or right of an occupied seat, and no two people can sit in the same seat. In how many ways can this process occur?
+Answer: $\boxed{\binom{100}{50} 2^{49}}$ First, note that there are $2^{49}$ ways a single row can be filled, because each of the 49 people after the first in a row must sit to the left or to the right of the current group of people in the row, so there are 2 possibilities for each of these 49 people.
+Now, there are $\binom{100}{50}$ ways to choose the order in which people are added to the rows, and $2^{49}$ ways to fill up each row separately, for a total of $\binom{100}{50} 2^{98}$ ways to fill up the auditorium.
+14. [8] Let $A B C D$ be a trapezoid with $A B \| C D$ and $\angle D=90^{\circ}$. Suppose that there is a point $E$ on $C D$ such that $A E=B E$ and that triangles $A E D$ and $C E B$ are similar, but not congruent. Given that $\frac{C D}{A B}=2014$, find $\frac{B C}{A D}$.
+Answer: $\sqrt{4027}$ Let $M$ be the midpoint of $A B$. Let $A M=M B=E D=a, M E=A D=b$, and $A E=B E=c$. Since $\triangle B E C \sim \triangle D E A$, but $\triangle B E C$ is not congruent to $\triangle D A E$, we must have $\triangle B E C \sim \triangle D E A$. Thus, $B C / B E=A D / D E=b / a$, so $B C=b c / a$, and $C E / E B=A E / E D=c / a$, so $E C=c^{2} / a$. We are given that $C D / A B=\frac{\frac{c^{2}}{a}+a}{2 a}=\frac{c^{2}}{2 a^{2}}+\frac{1}{2}=2014 \Rightarrow \frac{c^{2}}{a^{2}}=4027$. Thus, $B C / A D=\frac{b c / a}{b}=c / a=\sqrt{4027}$.
+15. [8] Given a regular pentagon of area 1, a pivot line is a line not passing through any of the pentagon's vertices such that there are 3 vertices of the pentagon on one side of the line and 2 on the other. A pivot point is a point inside the pentagon with only finitely many non-pivot lines passing through it. Find the area of the region of pivot points.
+Answer: $\frac{1}{2}(7-3 \sqrt{5})$ Let the pentagon be labeled $A B C D E$. First, no pivot point can be on the same side of $A C$ as vertex $B$. Any such point $P$ has the infinite set of non-pivot lines within the hourglass shape formed by the acute angles between lines $P A$ and $P C$. Similar logic can be applied to points on the same side of $B D$ as $C$, and so on. The set of pivot points is thus a small pentagon with sides on $A C, B D, C E, D A, E B$. The side ratio of this small pentagon to the large pentagon is
+
+$$
+\left(2 \cos \left(72^{\circ}\right)\right)^{2}=\frac{3-\sqrt{5}}{2}
+$$
+
+so the area of the small pentagon is
+
+$$
+\left(\frac{3-\sqrt{5}}{2}\right)^{2}=\frac{1}{2}(7-3 \sqrt{5})
+$$
+
+16. [8] Suppose that $x$ and $y$ are positive real numbers such that $x^{2}-x y+2 y^{2}=8$. Find the maximum possible value of $x^{2}+x y+2 y^{2}$.
+Answer: $\frac{72+32 \sqrt{2}}{7}$ Let $u=x^{2}+2 y^{2}$. By AM-GM, $u \geq \sqrt{8} x y$, so $x y \leq \frac{u}{\sqrt{8}}$. If we let $x y=k u$ where $k \leq \frac{1}{\sqrt{8}}$, then we have
+
+$$
+\begin{gathered}
+u(1-k)=8 \\
+u(1+k)=x^{2}+x y+2 y^{2}
+\end{gathered}
+$$
+
+that is, $u(1+k)=8 \cdot \frac{1+k}{1-k}$. It is not hard to see that the maximum value of this expression occurs at $k=\frac{1}{\sqrt{8}}$, so the maximum value is $8 \cdot \frac{1+\frac{1}{\sqrt{8}}}{1-\frac{1}{\sqrt{8}}}=\frac{72+32 \sqrt{2}}{7}$.
+17. [11] Let $f: \mathbb{N} \rightarrow \mathbb{N}$ be a function satisfying the following conditions:
+(a) $f(1)=1$.
+(b) $f(a) \leq f(b)$ whenever $a$ and $b$ are positive integers with $a \leq b$.
+(c) $f(2 a)=f(a)+1$ for all positive integers $a$.
+
+How many possible values can the 2014-tuple $(f(1), f(2), \ldots, f(2014))$ take?
+Answer: 1007 Note that $f(2014)=f(1007)+1$, so there must be exactly one index $1008 \leq i \leq 2014$ such that $f(i)=f(i-1)+1$, and for all $1008 \leq j \leq 2014, j \neq i$ we must have $f(j)=f(j-1)$. We first claim that each value of $i$ corresponds to exactly one 2014-tuple $(f(1), \ldots, f(2014))$. To prove this, note that $f(1024)=11$, so each $i$ uniquely determines the values of $f(1007), \ldots, f(2014)$. Then all of $f(1), \ldots, f(1006)$ can be uniquely determined from these values because for any $1 \leq k \leq 1006$, there exists a unique $n$ such that $1007 \leq k \cdot 2^{n} \leq 2014$. It's also clear that these values satisfy the condition that $f$ is nondecreasing, so we have a correspondence from each $1008 \leq i \leq 2014$ to a unique 2014-tuple.
+Also, given any valid 2014-tuple $(f(1), \ldots, f(2014)$ ), we know that $f(1), \ldots, f(1006)$ can be uniquely determined by $f(1007), \ldots, f(2014)$, which yields some $1008 \leq i \leq 2014$ where $f(i)=f(i-1)+1$, so we actually have a bijection between possible values of $i$ and 2014-tuples. Therefore, the total number of possible 2014-tuples is 1007 .
+18. [11] Find the number of ordered quadruples of positive integers $(a, b, c, d)$ such that $a, b, c$, and $d$ are all (not necessarily distinct) factors of 30 and $a b c d>900$.
+Answer: 1940 Since $a b c d>900 \Longleftrightarrow \frac{30}{a} \frac{30}{b} \frac{30}{c} \frac{30}{d}<900$, and there are $\binom{4}{2}^{3}$ solutions to $a b c d=2^{2} 3^{2} 5^{2}$, the answer is $\frac{1}{2}\left(8^{4}-\binom{4}{2}^{3}\right)=1940$ by symmetry.
+19. [11] Let $A B C D$ be a trapezoid with $A B \| C D$. The bisectors of $\angle C D A$ and $\angle D A B$ meet at $E$, the bisectors of $\angle A B C$ and $\angle B C D$ meet at $F$, the bisectors of $\angle B C D$ and $\angle C D A$ meet at $G$, and the bisectors of $\angle D A B$ and $\angle A B C$ meet at $H$. Quadrilaterals $E A B F$ and $E D C F$ have areas 24 and 36, respectively, and triangle $A B H$ has area 25 . Find the area of triangle $C D G$.
+Answer: $\boxed{\frac{256}{7}}$ Let $M, N$ be the midpoints of $AD, BC$ respectively. Since $AE$ and $DE$ are bisectors of supplementary angles, the triangle $A E D$ is right with right angle $E$. Then $E M$ is the median of a right triangle from the right angle, so triangles $E M A$ and $E M D$ are isosceles with vertex $M$. But then $\angle M E A=\angle E A M=\angle E A B$, so $E M \| A B$. Similarly, $F N \| B A$. Thus, both $E$ and $F$ are on the midline of this trapezoid. Let the length of $E F$ be $x$. Triangle $E F H$ has area 1 and is similar to triangle $A B H$, which has area 25 , so $A B=5 x$. Then, letting the heights of trapezoids $E A B F$ and $E D C F$ be $h$ (they are equal since $E F$ is on the midline), the area of trapezoid $E A B F$ is $\frac{6 x h}{2}=24$. So the area of trapezoid $E D C F$ is $36=\frac{9 x h}{2}$. Thus $D C=8 x$. Then, triangle $G E F$ is similar to and has $\frac{1}{64}$ times the area of triangle $C D G$. So the area of triangle $C D G$ is $\frac{64}{63}$ times the area of quadrilateral $E D C F$, or $\frac{256}{7}$.
+20. [11] A deck of 8056 cards has 2014 ranks numbered 1-2014. Each rank has four suits-hearts, diamonds, clubs, and spades. Each card has a rank and a suit, and no two cards have the same rank and the same suit. How many subsets of the set of cards in this deck have cards from an odd number of distinct ranks?
+Answer: $\frac{1}{2}\left(16^{2014}-14^{2014}\right)$ There are $\binom{2014}{k}$ ways to pick $k$ ranks, and 15 ways to pick the suits in each rank (because there are 16 subsets of suits, and we must exclude the empty one). We therefore want to evaluate the sum $\binom{2014}{1} 15^{1}+\binom{2014}{3} 15^{3}+\cdots+\binom{2014}{2013} 15^{2013}$.
+Note that $(1+15)^{2014}=1+\binom{2014}{1} 15^{1}+\binom{2014}{2} 15^{2}+\ldots+\binom{2014}{2013} 15^{2013}+15^{2014}$ and $(1-15)^{2014}=$ $1-\binom{2014}{1} 15^{1}+\binom{2014}{2} 15^{2}-\ldots-\binom{2014}{2013} 15^{2013}+15^{2014}$, so our sum is simply $\frac{(1+15)^{2014}-(1-15)^{2014}}{2}=$ $\frac{1}{2}\left(16^{2014}-14^{2014}\right)$.
+21. [14] Compute the number of ordered quintuples of nonnegative integers ( $a_{1}, a_{2}, a_{3}, a_{4}, a_{5}$ ) such that $0 \leq a_{1}, a_{2}, a_{3}, a_{4}, a_{5} \leq 7$ and 5 divides $2^{a_{1}}+2^{a_{2}}+2^{a_{3}}+2^{a_{4}}+2^{a_{5}}$.
+Answer: 6528 Let $f(n)$ denote the number of $n$-tuples $\left(a_{1}, \ldots, a_{n}\right)$ such that $0 \leq a_{1}, \ldots, a_{n} \leq 7$ and $5 \mid 2^{a_{1}}+\ldots+2^{a_{n}}$. To compute $f(n+1)$ from $f(n)$, we note that given any $n$-tuple $\left(a_{1}, \ldots, a_{n}\right)$ such that $0 \leq a_{1}, \ldots, a_{n} \leq 7$ and $5 \nmid 2^{a_{1}}+\ldots+2^{a_{n}}$, there are exactly two possible values for $a_{n+1}$ such that $0 \leq a_{n+1} \leq 7$ and $5 \mid 2^{a_{1}}+\ldots+2^{a_{n+1}}$, because $2^{n} \equiv 1,2,4,3,1,2,4,3(\bmod 5)$ for $n=0,1,2,3,4,5,6,7$ respectively.
+
+Also, given any valid $(n+1)$-tuple $\left(a_{1}, \ldots, a_{n+1}\right)$, we can remove $a_{n+1}$ to get an $n$-tuple $\left(a_{1}, \ldots, a_{n}\right)$ such that $0 \leq a_{1}, \ldots, a_{n} \leq 7$ and $5 \nmid 2^{a_{1}}+\ldots+2^{a_{n}}$, so these are in bijection. There are a total of $8^{n}$ $n$-tuples, $f(n)$ of which satisfy $5 \mid 2^{a_{1}}+\ldots+2^{a_{n}}$, so there are $8^{n}-f(n)$ for which $5 \nmid 2^{a_{1}}+\ldots+2^{a_{n}}$. Therefore, $f(n+1)=2\left(8^{n}-f(n)\right)$.
+We now have $f(1)=0, f(2)=2(8-0)=16, f(3)=2(64-16)=96, f(4)=2(512-96)=832$, $f(5)=2(4096-832)=6528$.
+22. [14] Let $\omega$ be a circle, and let $A B C D$ be a quadrilateral inscribed in $\omega$. Suppose that $B D$ and $A C$ intersect at a point $E$. The tangent to $\omega$ at $B$ meets line $A C$ at a point $F$, so that $C$ lies between $E$ and $F$. Given that $A E=6, E C=4, B E=2$, and $B F=12$, find $D A$.
+Answer: $2 \sqrt{42}$ By power of a point, we have $E D \cdot E B=E A \cdot E C$, whence $E D=12$. Additionally, by power of a point, we have $144=F B^{2}=F C \cdot F A=F C(F C+10)$, so $F C=8$. Note that $\angle F B C=$ $\angle F A B$ and $\angle C F B=\angle A F B$, so $\triangle F B C \sim \triangle F A B$. Thus, $A B / B C=F A / F B=18 / 12=3 / 2$, so $A B=3 k$ and $B C=2 k$ for some $k$. Since $\triangle B E C \sim \triangle A E D$, we have $A D / B C=A E / B E=3$, so $A D=3 B C=6 k$. By Stewart's theorem on $\triangle E B F$, we have
+
+$$
+(4)(8)(12)+(2 k)^{2}(12)=(2)^{2}(8)+(12)^{2}(4) \Longrightarrow 8+k^{2}=8 / 12+12
+$$
+
+whence $k^{2}=14 / 3$. Thus,
+
+$$
+D A=6 k=6 \sqrt{14 / 3}=6 \frac{\sqrt{42}}{3}=2 \sqrt{42} .
+$$
+
+23. [14] Let $S=\{-100,-99,-98, \ldots, 99,100\}$. Choose a 50 -element subset $T$ of $S$ at random. Find the expected number of elements of the set $\{|x|: x \in T\}$.
+
+Answer: $\square$ Let us solve a more generalized version of the problem: Let $S$ be a set with $2 n+1$ elements, and partition $S$ into sets $A_{0}, A_{1}, \ldots, A_{n}$ such that $\left|A_{0}\right|=1$ and $\left|A_{1}\right|=\left|A_{2}\right|=\cdots=\left|A_{n}\right|=2$. (In this problem, we have $A_{0}=\{0\}$ and $A_{k}=\{k,-k\}$ for $k=1,2, \ldots, 100$.) Let $T$ be a randomly chosen $m$-element subset of $S$. What is the expected number of $A_{k}$ 's that have a representative in $T$ ?
+For $k=0,1, \ldots, n$, let $w_{k}=1$ if $T \cap A_{k} \neq \emptyset$ and 0 otherwise, so that the number of $A_{k}$ 's that have a representative in $T$ is equal to $\sum_{k=0}^{n} w_{k}$. It follows that the expected number of $A_{k}$ 's that have a representative in $T$ is equal to
+
+$$
+\mathrm{E}\left[w_{0}+w_{1}+\cdots+w_{n}\right]=\mathrm{E}\left[w_{0}\right]+\mathrm{E}\left[w_{1}\right]+\cdots+\mathrm{E}\left[w_{n}\right]=\mathrm{E}\left[w_{0}\right]+n \mathrm{E}\left[w_{1}\right]
+$$
+
+since $\mathrm{E}\left[w_{1}\right]=\mathrm{E}\left[w_{2}\right]=\cdots=\mathrm{E}\left[w_{n}\right]$ by symmetry.
+Now $\mathrm{E}\left[w_{0}\right]$ is equal to the probability that $T \cap A_{0} \neq \emptyset$, that is, the probability that the single element of $A_{0}$ is in $T$, which is $T\left|/|S|=m /(2 n+1)\right.$. Similarly, $\mathrm{E}\left[w_{1}\right]$ is the probability that $T \cap A_{1} \neq \emptyset$, that is, the probability that at least one of the two elements of $A_{1}$ is in $T$. Since there are $\binom{2 n-1}{m} m$-element subsets of $S$ that exclude both elements of $A_{1}$, and there are $\binom{2 n+1}{m} m$-element subsets of $S$ in total, we have that
+
+$$
+\mathrm{E}\left[w_{1}\right]=1-\frac{\binom{2 n-1}{m}}{\binom{2 n+1}{m}}=1-\frac{(2 n-m)(2 n-m+1)}{2 n(2 n+1)}
+$$
+
+Putting this together, we find that the expected number of $A_{k}$ 's that have a representative in $T$ is
+
+$$
+\frac{m}{2 n+1}+n-\frac{(2 n-m+1)(2 n-m)}{2(2 n+1)}
+$$
+
+In this particular problem, we have $n=100$ and $m=50$, so substituting these values gives our answer of $\frac{8825}{201}$.
+24. [14] Let $A=\left\{a_{1}, a_{2}, \ldots, a_{7}\right\}$ be a set of distinct positive integers such that the mean of the elements of any nonempty subset of $A$ is an integer. Find the smallest possible value of the sum of the elements in $A$.
+Answer: 1267 For $2 \leq i \leq 6$, we claim that $a_{1} \equiv \ldots \equiv a_{7}(\bmod i)$. This is because if we consider any $i-1$ of the 7 numbers, the other $7-(i-1)=8-i$ of them must all be equal modulo $i$, because we want the sum of all subsets of size $i$ to be a multiple of $i$. However, $8-i \geq 2$, and this argument applies to any $8-i$ of the 7 integers, so in fact all of them must be equal modulo $i$.
+We now have that all of the integers are equivalent modulo all of $2, \ldots, 6$, so they are equivalent modulo 60 , their least common multiple. Therefore, if the smallest integer is $k$, then the other 6 integers must be at least $k+60, k+60 \cdot 2, \ldots, k+60 \cdot 6$. This means the sum is $7 k+60 \cdot 21 \geq 7+60 \cdot 21=1267$. 1267 is achievable with $\{1,1+60, \ldots, 1+60 \cdot 6\}$, so it is the answer.
+25. [17] Let $A B C$ be an equilateral triangle of side length 6 inscribed in a circle $\omega$. Let $A_{1}, A_{2}$ be the points (distinct from $A$ ) where the lines through $A$ passing through the two trisection points of $B C$ meet $\omega$. Define $B_{1}, B_{2}, C_{1}, C_{2}$ similarly. Given that $A_{1}, A_{2}, B_{1}, B_{2}, C_{1}, C_{2}$ appear on $\omega$ in that order, find the area of hexagon $A_{1} A_{2} B_{1} B_{2} C_{1} C_{2}$.
+Answer: $\frac{846 \sqrt{3}}{49}$ Let $A^{\prime}$ be the point on $B C$ such that $2 B A^{\prime}=A^{\prime} C$. By law of cosines on triangle $A A^{\prime} B$, we find that $A A^{\prime}=2 \sqrt{7}$. By power of a point, $A^{\prime} A_{1}=\frac{2 * 4}{2 \sqrt{7}}=\frac{4}{\sqrt{7}}$. Using side length ratios, $A_{1} A_{2}=2 \frac{A A_{1}}{A A^{\prime}}=2 \frac{2 \sqrt{7}+\frac{4}{\sqrt{7}}}{2 \sqrt{7}}=\frac{18}{7}$.
+
+Now our hexagon can be broken down into equilateral triangle $A_{1} B_{1} C_{1}$ and three copies of triangle $A_{1} C_{1} C_{2}$. Since our hexagon has rotational symmetry, $\angle C_{2}=120$, and using law of cosines on this triangle with side lengths $\frac{18}{7}$ and 6 , a little algebra yields $A_{1} C_{2}=\frac{30}{7}$ (this is a 3-5-7 triangle with an angle 120).
+
+The area of the hexagon is therefore $\frac{6^{2} \sqrt{3}}{4}+3 * \frac{1}{2} \frac{18}{7} \frac{30}{7} \frac{\sqrt{3}}{2}=\frac{846 \sqrt{3}}{49}$
+26. [17] For $1 \leq j \leq 2014$, define
+
+$$
+b_{j}=j^{2014} \prod_{i=1, i \neq j}^{2014}\left(i^{2014}-j^{2014}\right)
+$$
+
+where the product is over all $i \in\{1, \ldots, 2014\}$ except $i=j$. Evaluate
+
+$$
+\frac{1}{b_{1}}+\frac{1}{b_{2}}+\cdots+\frac{1}{b_{2014}}
+$$
+
+Answer: $\frac{1}{2014!^{2014}}$ We perform Lagrange interpolation on the polynomial $P(x)=1$ through the points $1^{2014}, 2^{2014}, \ldots, 2014^{2014}$. We have
+
+$$
+1=P(x)=\sum_{j=1}^{2014} \frac{\prod_{i=1, i \neq j}^{2014}\left(x-i^{2014}\right)}{\prod_{i=1, i \neq j}^{2014}\left(j^{2014}-i^{2014}\right)} .
+$$
+
+Thus,
+
+$$
+1=P(0)=\sum_{j=1}^{2014} \frac{\left((-1)^{2013}\right) \frac{2014!^{2014}}{j^{014}}}{(-1)^{2013} \prod_{i=1, i \neq j}^{2014}\left(i^{2014}-j^{2014}\right)}
+$$
+
+which equals
+
+$$
+2014!^{2014} \sum_{j=1}^{2014} \frac{1}{j^{2014} \prod_{i=1, i \neq j}^{2014}\left(i^{2014}-j^{2014}\right)}=2014!^{2014}\left(\frac{1}{b_{1}}+\frac{1}{b_{2}}+\cdots+\frac{1}{b_{2014}}\right)
+$$
+
+so the desired sum is $\frac{1}{2014!^{2014}}$.
+27. [17] Suppose that $\left(a_{1}, \ldots, a_{20}\right)$ and $\left(b_{1}, \ldots, b_{20}\right)$ are two sequences of integers such that the sequence $\left(a_{1}, \ldots, a_{20}, b_{1}, \ldots, b_{20}\right)$ contains each of the numbers $1, \ldots, 40$ exactly once. What is the maximum possible value of the sum
+
+$$
+\sum_{i=1}^{20} \sum_{j=1}^{20} \min \left(a_{i}, b_{j}\right) ?
+$$
+
+Answer: 5530 Let $x_{k}$, for $1 \leq k \leq 40$, be the number of integers $i$ with $1 \leq i \leq 20$ such that $a_{i} \geq k$. Let $y_{k}$, for $1 \leq k \leq 40$, be the number of integers $j$ with $1 \leq j \leq 20$ such that $b_{j} \geq k$. It follows from the problem statement that $x_{k}+y_{k}$ is the number of elements of the set $\{1, \ldots, 40\}$ which are greater than or equal to 40 , which is just $41-k$.
+Note that if $1 \leq i, j \leq 20$, and $1 \leq k \leq 40$, then $\min \left(a_{i}, b_{j}\right) \geq k$ if and only if $a_{i} \geq k$ and $b_{j} \geq k$. So for a fixed $k$ with $1 \leq k \leq 40$, the number of pairs $(i, j)$ with $1 \leq i, j \leq 20 \operatorname{such}$ that $\min \left(a_{i}, b_{j}\right) \geq k$ is equal to $x_{k} y_{k}$. So we can rewrite
+
+$$
+\sum_{i=1}^{20} \sum_{j=1}^{20} \min \left(a_{i}, b_{j}\right)=\sum_{k=1}^{40} x_{k} y_{k}
+$$
+
+Since $x_{k}+y_{k}=41-k$ for $1 \leq k \leq 40$, we have
+
+$$
+x_{k} y_{k} \leq\left\lfloor\frac{41-k}{2}\right\rfloor\left\lceil\frac{41-k}{2}\right\rceil
+$$
+
+by a convexity argument. So
+
+$$
+\sum_{i=1}^{20} \sum_{j=1}^{20} \min \left(a_{i}, b_{j}\right) \leq \sum_{k=1}^{40}\left\lfloor\frac{41-k}{2}\right\rfloor\left\lceil\frac{41-k}{2}\right\rceil=5530 .
+$$
+
+Equality holds when $\left(a_{1}, \ldots, a_{20}\right)=(2,4, \ldots, 38,40)$ and $\left(b_{1}, \ldots, b_{20}\right)=(1,3, \ldots, 37,39)$.
+28. [17] Let $f(n)$ and $g(n)$ be polynomials of degree 2014 such that $f(n)+(-1)^{n} g(n)=2^{n}$ for $n=$ $1,2, \ldots, 4030$. Find the coefficient of $x^{2014}$ in $g(x)$.
+Answer: $\frac{3^{2014}}{2^{2014} \cdot 2014!}$ Define the polynomial functions $h_{1}$ and $h_{2}$ by $h_{1}(x)=f(2 x)+g(2 x)$ and $h_{2}(x)=f(2 x-1)-g(2 x-1)$. Then, the problem conditions tell us that $h_{1}(x)=2^{2 x}$ and $h_{2}(x)=2^{2 x-1}$ for $x=1,2, \ldots, 2015$.
+
+By the Lagrange interpolation formula, the polynomial $h_{1}$ is given by
+
+$$
+h_{1}(x)=\sum_{i=1}^{2015} 2^{2 i} \prod_{\substack{j=1 \\ i \neq j}}^{2015} \frac{x-j}{i-j}
+$$
+
+So the coefficient of $x^{2014}$ in $h_{1}(x)$ is
+
+$$
+\sum_{i=1}^{2015} 2^{2 i} \prod_{\substack{j=1 \\ i \neq j}}^{2015} \frac{1}{i-j}=\frac{1}{2014!} \sum_{i=1}^{2015} 2^{2 i}(-1)^{2015-i}\binom{2014}{i-1}=\frac{4 \cdot 3^{2014}}{2014!}
+$$
+
+where the last equality follows from the binomial theorem. By a similar argument, the coefficient of $x^{2014}$ in $h_{2}(x)$ is $\frac{2 \cdot 3^{2014}}{2014!}$.
+We can write $g(x)=\frac{1}{2}\left(h_{1}(x / 2)-h_{2}((x+1) / 2)\right)$. So, the coefficient of $x^{2014}$ in $g(x)$ is
+
+$$
+\frac{1}{2}\left(\frac{4 \cdot 3^{2014}}{2^{2014} \cdot 2014!}-\frac{2 \cdot 3^{2014}}{2^{2014} \cdot 2014!}\right)=\frac{3^{2014}}{2^{2014} \cdot 2014!}
+$$
+
+29. [20] Natalie has a copy of the unit interval $[0,1]$ that is colored white. She also has a black marker, and she colors the interval in the following manner: at each step, she selects a value $x \in[0,1]$ uniformly at random, and
+(a) If $x \leq \frac{1}{2}$ she colors the interval $\left[x, x+\frac{1}{2}\right]$ with her marker.
+(b) If $x>\frac{1}{2}$ she colors the intervals $[x, 1]$ and $\left[0, x-\frac{1}{2}\right]$ with her marker.
+
+What is the expected value of the number of steps Natalie will need to color the entire interval black?
+Answer: 5 The first choice always wipes out half the interval. So we calculate the expected value of the amount of time needed to wipe out the other half.
+Solution 1 (non-calculus):
+We assume the interval has $2 n$ points and we start with the last $n$ colored black. We let $f(k)$ be the expected value of the number of turns we need if there are $k$ white points left. So we must calculate $f(n)$.
+We observe that
+
+$$
+\begin{gathered}
+f(k)=1+\frac{(n-k+1) \cdot 0+(n-k+1) \cdot f(k)+2 \sum_{i=1}^{k-1} f(i)}{2 n} \\
+f(k) \frac{n+k-1}{2 n}=1+\frac{\sum_{i=1}^{k-1} f(i)}{n} \\
+f(k+1) \frac{n+k}{2 n}=1+\frac{\sum_{i=1}^{k} f(i)}{n} \\
+f(k+1)=f(k) \frac{n+k+1}{n+k} \\
+f(k)=f(1) \frac{n+k}{n+1}
+\end{gathered}
+$$
+
+And note that $f(1)=2$ so $f(n)=\frac{4 n}{n+1}$ and $\lim _{n \rightarrow \infty} f(n)=4$.
+Therefore adding the first turn, the expected value is 5 .
+Solution 2 (calculus):
+We let $f(x)$ be the expected value with length $x$ uncolored. Like above, $\lim _{x \rightarrow 0} f(x)=2$.
+
+Similarly we have the recursion
+
+$$
+\begin{gathered}
+f(x)=1+\left(\frac{1}{2}-x\right) f(x)+2 \int_{0}^{x} f(y) d y \\
+f^{\prime}(x)=0+\frac{1}{2} f^{\prime}(x)-f(x)-x f^{\prime}(x)+2 f(x) \\
+\frac{f^{\prime}(x)}{f(x)}=\frac{1}{x+\frac{1}{2}}
+\end{gathered}
+$$
+
+And solving yields $f(x)=c\left(\frac{1}{2}+x\right)$ and since $\lim _{x \rightarrow 0} f(x)=2, c=4$. So $f(x)=2+4 x$ and $f\left(\frac{1}{2}\right)=4$. Therefore adding the first turn, our expected value is 5 .
+30. [20] Let $A B C$ be a triangle with circumcenter $O$, incenter $I, \angle B=45^{\circ}$, and $O I \| B C$. Find $\cos \angle C$.
+
+Answer: $1-\frac{\sqrt{2}}{2}$ Let $M$ be the midpoint of $B C$, and $D$ the foot of the perpendicular of $I$ with $B C$. Because $O I \| B C$, we have $O M=I D$. Since $\angle B O C=2 \angle A$, the length of $O M$ is $O A \cos \angle B O M=$ $O A \cos A=R \cos A$, and the length of $I D$ is $r$, where $R$ and $r$ are the circumradius and inradius of $\triangle A B C$, respectively.
+Thus, $r=R \cos A$, so $1+\cos A=(R+r) / R$. By Carnot's theorem, $(R+r) / R=\cos A+\cos B+\cos C$, so we have $\cos B+\cos C=1$. Since $\cos B=\frac{\sqrt{2}}{2}$, we have $\cos C=1-\frac{\sqrt{2}}{2}$.
+31. [20] Compute
+
+$$
+\sum_{k=1}^{1007}\left(\cos \left(\frac{\pi k}{1007}\right)\right)^{2014}
+$$
+
+
+Our desired expression is
+
+$$
+\frac{1}{2^{2014}} \sum_{k=1}^{1007}\left(\omega^{k}+\omega^{-k}\right)^{2014}
+$$
+
+Using binomial expansion and switching the order of the resulting summation, this is equal to
+
+$$
+\frac{1}{2^{2014}} \sum_{j=0}^{2014}\binom{2014}{j} \sum_{k=1}^{1007}\left(\omega^{2014-2 j}\right)^{k}
+$$
+
+Note that unless $\omega^{2014-2 j}=1$, the summand
+
+$$
+\sum_{k=1}^{1007}\left(\omega^{2014-2 j}\right)^{k}
+$$
+
+is the sum of roots of unity spaced evenly around the unit circle in the complex plane (in particular the 1007 th, 19 th, and 53 rd roots of unity), so it is zero. Thus, we must only sum over those $j$ for which $\omega^{2014-2 j}=1$, which holds for $j=0,1007,2014$. This yields the answer
+
+$$
+\frac{1}{2^{2014}}\left(1007+1007\binom{2014}{1007}+1007\right)=\frac{2014\left(1+\binom{2013}{1007}\right)}{2^{2014}}
+$$
+
+32. [20] Find all ordered pairs $(a, b)$ of complex numbers with $a^{2}+b^{2} \neq 0, a+\frac{10 b}{a^{2}+b^{2}}=5$, and $b+\frac{10 a}{a^{2}+b^{2}}=4$.
+
+Answer: $(1,2),(4,2),\left(\frac{5}{2}, 2 \pm \frac{3}{2} i\right)$ Solution 1. First, it is easy to see that $a b \neq 0$. Thus, we can write
+
+$$
+\frac{5-a}{b}=\frac{4-b}{a}=\frac{10}{a^{2}+b^{2}} .
+$$
+
+Then, we have
+
+$$
+\frac{10}{a^{2}+b^{2}}=\frac{4 a-a b}{a^{2}}=\frac{5 b-a b}{b^{2}}=\frac{4 a+5 b-2 a b}{a^{2}+b^{2}} .
+$$
+
+Therefore, $4 a+5 b-2 a b=10$, so $(2 a-5)(b-2)=0$. Now we just plug back in and get the four solutions: $(1,2),(4,2),\left(\frac{5}{2}, 2 \pm \frac{3}{2} i\right)$. It's not hard to check that they all work.
+Solution 2. The first equation plus $i$ times the second yields $5+4 i=a+b i+\frac{10(b+a i)}{a^{2}+b^{2}}=a+b i-\frac{10 i}{a+b i}$, which is equivalent to $a+b i=\frac{(5 \pm 3)+4 i}{2}$ by the quadratic formula.
+Similarly, the second equation plus $i$ times the first yields $4+5 i=b+a i-\frac{10 i}{b+a i}$, which is equivalent to $b+a i=\frac{4+(5 \pm 3) i}{2}$.
+Letting $\epsilon_{1}, \epsilon_{2} \in\{-1,1\}$ be the signs in $a+b i$ and $b+a i$, we get $(a, b)=\frac{1}{2}(a+b i, b+a i)-\frac{1}{2} i(b+a i, a+b i)=$ $\left(\frac{10+\left(\epsilon_{1}+\epsilon_{2}\right) 3}{4}, \frac{8+\left(\epsilon_{2}-\epsilon_{1}\right) 3 i}{4}\right)$.
+Comment. Many alternative approaches are possible. For instance, $\frac{5-a}{b}=\frac{4-b}{a} \Longrightarrow b-2=$ $\epsilon \sqrt{(a-1)(a-4)}$ for some $\epsilon \in\{-1,1\}$, and substituting in and expanding gives $0=\left(-2 a^{2}+5 a\right) \epsilon \sqrt{(a-1)(a-4)}$.
+More symmetrically, we may write $a=\lambda(4-b), b=\lambda(5-a)$ to get $(a, b)=\frac{\lambda}{1-\lambda^{2}}(4-5 \lambda, 5-4 \lambda)$, and then plug into $a^{2}+b^{2}=10 \lambda$ to get $0=10\left(\lambda^{4}+1\right)-41\left(\lambda^{3}+\lambda\right)+60 \lambda^{2}=(\lambda-2)(2 \lambda-1)\left(5 \lambda^{2}-8 \lambda+5\right)$.
+33. [25] An up-right path from $(a, b) \in \mathbb{R}^{2}$ to $(c, d) \in \mathbb{R}^{2}$ is a finite sequence $\left(x_{1}, y_{1}\right), \ldots,\left(x_{k}, y_{k}\right)$ of points in $\mathbb{R}^{2}$ such that $(a, b)=\left(x_{1}, y_{1}\right),(c, d)=\left(x_{k}, y_{k}\right)$, and for each $1 \leq i
Team
+
+1. [10] Let $\omega$ be a circle, and let $A$ and $B$ be two points in its interior. Prove that there exists a circle passing through $A$ and $B$ that is contained in the interior of $\omega$.
+Answer: N/A WLOG, suppose $O A \geq O B$. Let $\omega^{\prime}$ be the circle of radius $O A$ centered at $O$. We have that $B$ lies inside $\omega^{\prime}$. Thus, it is possible to scale $\omega^{\prime}$ down about the point $A$ to get a circle $\omega^{\prime \prime}$ passing through both $A$ and $B$. Since $\omega^{\prime \prime}$ lies inside $\omega^{\prime}$ and $\omega^{\prime}$ lies inside $\omega, \omega^{\prime \prime}$ lies inside $\omega$.
+Alternative solution 1: WLOG, suppose $O A \geq O B$. Since $O A \geq O B$, the perpendicular bisector of $A B$ intersects segment $O A$ at some point $C$. We claim that the circle $\omega^{\prime}$ passing through $A$ and $B$ and centered at $C$ lies entirely in $\omega$. Let $x=O A$ and $y=A C=B C$. Note that $y$ is the length of the radius of $\omega^{\prime}$. By definition, any point $P$ contained in $\omega^{\prime}$ is of distance at most $y$ from $C$. Applying the triangle inequality to $O C P$, we see that $O P \leq O C+C P \leq(x-y)+y=x$, so $P$ lies in $\omega$. Since $P$ was arbitrary, it follows that $\omega^{\prime}$ lies entirely in $\omega$.
+Alternative solution 2: Draw line $A B$, and let it intersect $\omega$ at $A^{\prime}$ and $B^{\prime}$, where $A$ and $A^{\prime}$ are on the same side of $B$. Choose $X$ inside the segment $A B$ so that $A^{\prime} X / A X=B^{\prime} X / B X$; such a point exists by the intermediate value theorem. Notice that $X$ is the center of a dilation taking $A^{\prime} B^{\prime}$ to $A B$ - the same dilation carries $\omega$ to $\omega^{\prime}$ which goes through $A$ and $B$. Since $\omega^{\prime}$ is $\omega$ dilated with respect to a point in its interior, it's clear that $\omega^{\prime}$ must be contained entirely within $\omega$, and so we are done.
+2. [15] Let $a_{1}, a_{2}, \ldots$ be an infinite sequence of integers such that $a_{i}$ divides $a_{i+1}$ for all $i \geq 1$, and let $b_{i}$ be the remainder when $a_{i}$ is divided by 210 . What is the maximal number of distinct terms in the sequence $b_{1}, b_{2}, \ldots$ ?
+Answer: $\quad 127$ It is clear that the sequence $\left\{a_{i}\right\}$ will be a concatenation of sequences of the form $\left\{v_{i}\right\}_{i=1}^{N_{0}},\left\{w_{i} \cdot p_{1}\right\}_{i=1}^{N_{1}},\left\{x_{i} \cdot p_{1} p_{2}\right\}_{i=1}^{N_{2}},\left\{y_{i} \cdot p_{1} p_{2} p_{3}\right\}_{i=1}^{N_{3}}$, and $\left\{z_{i} \cdot p_{1} p_{2} p_{3} p_{4}\right\}_{i=1}^{N_{4}}$, for some permutation $\left(p_{1}, p_{2}, p_{3}, p_{4}\right)$ of $(2,3,5,7)$ and some sequences of integers $\left\{v_{i}\right\} \cdot\left\{w_{i}\right\} \cdot\left\{x_{i}\right\} \cdot\left\{y_{i}\right\} \cdot\left\{z_{i}\right\}$, each coprime with 210.
+
+In $\left\{v_{i}\right\}_{i=1}^{N_{0}}$, there are a maximum of $\phi(210)$ distinct terms $\bmod 210$. In $\left\{w_{i} \cdot p_{1}\right\}_{i=1}^{N_{1}}$, there are a maximum of $\phi\left(\frac{210}{p_{1}}\right)$ distinct terms mod 210. In $\left\{x_{i} \cdot p_{1} p_{2}\right\}_{i=1}^{N_{2}}$, there are a maximum of $\phi\left(\frac{210}{p_{1} p_{2}}\right)$ distinct terms mod 210. In $\left\{y_{i} \cdot p_{1} p_{2} p_{3}\right\}_{i=1}^{N_{3}}$, there are a maximum of $\phi\left(\frac{210}{p_{1} p_{2} p_{3}}\right)$ distinct terms mod 210. In $\left\{z_{i} \cdot p_{1} p_{2} p_{3} p_{4}\right\}_{i=1}^{N_{4}}$, there can only be one distinct term $\bmod 210$.
+Therefore we wish to maximize $\phi(210)+\phi\left(\frac{210}{p_{1}}\right)+\phi\left(\frac{210}{p_{1} p_{2}}\right)+\phi\left(\frac{210}{p_{1} p_{2} p_{3}}\right)+1$ over all permutations $\left(p_{1}, p_{2}, p_{3}, p_{4}\right)$ of $(2,3,5,7)$. It's easy to see that the maximum occurs when we take $p_{1}=2, p_{2}=$ $3, p_{3}=5, p_{4}=7$ for an answer of $\phi(210)+\phi(105)+\phi(35)+\phi(7)+1=127$. This upper bound is clearly attainable by having the $v_{i}$ 's cycle through the $\phi(210)$ integers less than 210 coprime to 210 , the $w_{i}$ 's cycle through the $\phi\left(\frac{210}{p_{1}}\right)$ integers less than $\frac{210}{p_{1}}$ coprime to $\frac{210}{p_{1}}$, etc.
+3. [15] There are $n$ girls $G_{1}, \ldots, G_{n}$ and $n$ boys $B_{1}, \ldots, B_{n}$. A pair $\left(G_{i}, B_{j}\right)$ is called suitable if and only if girl $G_{i}$ is willing to marry boy $B_{j}$. Given that there is exactly one way to pair each girl with a distinct boy that she is willing to marry, what is the maximal possible number of suitable pairs?
+
+Answer: $\frac{n(n+1)}{2}$ We represent the problem as a graph with vertices $G_{1}, \ldots, G_{n}, B_{1}, \ldots, B_{n}$ such that there is an edge between vertices $G_{i}$ and $B_{j}$ if and only if $\left(G_{i}, B_{j}\right)$ is suitable, so we want to maximize the number of edges while having a unique matching.
+We claim the answer is $\frac{n(n+1)}{2}$. First, note that this can be achieved by having an edge between $G_{i}$ and $B_{j}$ for all pairs $j \leq i$, because the only possible matching in this case is pairing $G_{i}$ with $B_{i}$ for all $i$. To prove that this is maximal, we first assume without loss of generality that our unique matching consists of pairing $G_{i}$ with $B_{i}$ for all $i$, which takes $n$ edges. Now, note that for any $i, j$, at most one of the two edges $G_{i} B_{j}$ and $G_{j} B_{i}$ can be added, because if both were added, we could pair $G_{i}$ with $B_{j}$
+and $G_{j}$ with $B_{i}$ instead to get another valid matching. Therefore, we may add at most $\binom{n}{2} \cdot 1=\frac{n(n-1)}{2}$ edges, so the maximal number of edges is $n+\frac{n(n-1)}{2}=\frac{n(n+1)}{2}$ as desired.
+4. [20] Compute
+
+$$
+\sum_{k=0}^{100}\left\lfloor\frac{2^{100}}{2^{50}+2^{k}}\right\rfloor
+$$
+
+(Here, if $x$ is a real number, then $\lfloor x\rfloor$ denotes the largest integer less than or equal to $x$.)
+Answer: $101 \cdot 2^{49}-50$ Let $a_{k}=\frac{2^{100}}{2^{50}+2^{k}}$. Notice that, for $k=0,1, \ldots, 49$,
+
+$$
+a_{k}+a_{100-k}=\frac{2^{100}}{2^{50}+2^{k}}+\frac{2^{100}}{2^{50}+2^{100-k}}=\frac{2^{100}}{2^{50}+2^{k}}+\frac{2^{50+k}}{2^{k}+2^{50}}=2^{50}
+$$
+
+It is clear that for $k=0,1, \ldots, 49, a_{k}, a_{100-k} \notin \mathbb{Z}$, so $\left\lfloor a_{k}\right\rfloor+\left\lfloor a_{100-k}\right\rfloor=2^{50}-1$ (since the sum of floors is an integer less than $a_{k}+a_{100-k}$ but greater than $\left.a_{k}-1+a_{100-k}-1\right)$. Thus,
+
+$$
+\sum_{k=0}^{100}\left\lfloor a_{k}\right\rfloor=50 \cdot\left(2^{50}-1\right)+2^{49}=101 \cdot 2^{49}-50
+$$
+
+5. [25] Prove that there exists a nonzero complex number $c$ and a real number $d$ such that
+
+$$
+\left.\|\left|\frac{1}{1+z+z^{2}}\right|-\left|\frac{1}{1+z+z^{2}}-c\right| \right\rvert\,=d
+$$
+
+for all $z$ with $|z|=1$ and $1+z+z^{2} \neq 0$. (Here, $|z|$ denotes the absolute value of the complex number $z$, so that $|a+b i|=\sqrt{a^{2}+b^{2}}$ for real numbers $a, b$.)
+
+Answer: $\quad$| $\frac{4}{3}$ |
+| :---: |
+| Let |
+| $f(z)$ |$=\left|\frac{1}{1+z+z^{2}}\right|$. Parametrize $z=e^{i t}=\cos t+i \sin t$ and let $g(t)=f\left(e^{i t}\right)$, $0 \leq t<2 \pi$. Writing out $\frac{1}{1+z+z^{2}}$ in terms of $t$ and simplifying, we find that $g(t)=\frac{\cos t-i \sin t}{1+2 \cos t}$. Letting $x(t)=\Re(g(t))$ and $y(t)=\Im(g(t))$ (the real and imaginary parts of $g(t)$, respectively), what we wish to prove is equivalent to showing that $\{(x(t), y(t)) \mid 0 \leq t<2 \pi\}$ is a hyperbola with one focus at $(0,0)$. However
+
+$$
+9\left(x(t)-\frac{2}{3}\right)^{2}-3 y(t)^{2}=1
+$$
+
+holds for all $t$, so from this equation we find that the locus of points $(x(t), y(t))$ is a hyperbola, with center $\left(\frac{2}{3}, 0\right)$ and focal length $\frac{2}{3}$, so the foci are at $(0,0)$ and $\left(\frac{4}{3}, 0\right)$. Hence $c=\frac{4}{3}$.
+6. [25] Let $n$ be a positive integer. A sequence $\left(a_{0}, \ldots, a_{n}\right)$ of integers is acceptable if it satisfies the following conditions:
+(a) $0=\left|a_{0}\right|<\left|a_{1}\right|<\cdots<\left|a_{n-1}\right|<\left|a_{n}\right|$.
+(b) The sets $\left\{\left|a_{1}-a_{0}\right|,\left|a_{2}-a_{1}\right|, \ldots,\left|a_{n-1}-a_{n-2}\right|,\left|a_{n}-a_{n-1}\right|\right\}$ and $\left\{1,3,9, \ldots, 3^{n-1}\right\}$ are equal.
+
+Prove that the number of acceptable sequences of integers is $(n+1)$ !.
+Answer: N/A We actually prove a more general result via strong induction on $n$.
+First, we state the more general result we wish to prove.
+For $n>0$, define a great sequence to be a sequence of integers $\left(a_{0}, \ldots, a_{n}\right)$ such that
+
+1. $0=\left|a_{0}\right|<\left|a_{1}\right|<\cdots<\left|a_{n-1}\right|<\left|a_{n}\right|$
+2. Let $\left(b_{1}, b_{2}, \ldots, b_{n}\right)$ be a set of positive integers such that $3 b_{i} \leq b_{i+1}$ for all $i$. The sets $\left\{\left|a_{1}-a_{0}\right|, \mid a_{2}-\right.$ $a_{1}\left|, \ldots,\left|a_{n-1}-a_{n-2}\right|,\left|a_{n}-a_{n-1}\right|\right\}$ and $\left\{b_{1}, b_{2}, \ldots, b_{n}\right\}$ are equal.
+Then, the number of great sequences is $(n+1)$ !.
+If we prove this statement, then we can just consider the specific case of $b_{1}=1,3 b_{i}=b_{i+1}$ to solve our problem.
+
+Before we proceed, we will prove a lemma.
+Lemma: Let $\left(b_{1}, b_{2}, \ldots, b_{n}\right)$ be a set of positive integers such that $3 b_{i} \leq b_{i+1}$ for all $i$. Then $b_{i}>$ $2 \sum_{k=1}^{i-1} b_{k}$.
+Proof: $\frac{b_{i}}{2}=\frac{b_{i}}{3}+\frac{b_{i}}{9}+\cdots \geq \sum_{k=1}^{i-1} b_{k}$. Equality only occurs when the sequence $b_{i}$ is infinite, which is not the case, so the inequality holds.
+
+We can now proceed with the induction. The base case is obvious. Assume it is true up to $n=j-1$. Next, consider some permutation of the set $B=\left\{b_{1}, b_{2}, b_{3}, \cdots, b_{j}\right\}$. Denote it as $C=\left\{c_{1}, c_{2}, \ldots, c_{j}\right\}$. Find the element $c_{k}=b_{j}$. For the first $k-1$ elements of $C$, we can put them in order and apply the inductive hypothesis. The number of great sequences such that the set of differences $\left\{\mid a_{1}-\right.$ $a_{0}\left|, \ldots,\left|a_{k-1}-a_{k-2}\right|\right\}$ is equal to $\left\{c_{1}, c_{2}, \ldots, c_{k-1}\right\}$ is $k!$.
+Then, $a_{k}$ can be either $a_{k-1}+c_{k}$ or $a_{k-1}-c_{k}$. This is because, by the lemma, $c_{k}>2 \sum_{m=1}^{k-1} c_{m}=$ $2 \sum_{m=1}^{k-1}\left|a_{m}-a_{m-1}\right| \geq 2\left|a_{k-1}-a_{k-2}+a_{k-2}-a_{k-3}+\cdots+a_{1}-a_{0}\right|=2\left|a_{k-1}\right|$. It is easy to check that for either possible value of $a_{k},\left|a_{k}\right|>\left|a_{k-1}\right|$. After that, there is only one possible value for $a_{k+1}, \ldots, a_{j}$ because only one of $a_{i} \pm c_{i+1}$ will satisfy $\left|a_{i}\right|>\left|a_{i-1}\right|$.
+There are $\binom{j-1}{k-1}$ possible ways to choose $c_{1}, c_{2}, \ldots, c_{k-1}$ from $B$. Given those elements of $C$, there are $k$ ! ways to make a great sequence $\left(a_{0}, a_{1}, \ldots, a_{k-1}\right)$. Then, there are 2 possible values for $a_{k}$. After that, there are $(j-k)$ ! ways to order the remaining elements of $C$, and for each such ordering, there is exactly 1 possible great sequence $\left(a_{0}, a_{1}, \ldots, a_{j}\right)$.
+Now, counting up all the possible ways to do this over all values of $k$, we get that the number of great sequences is equal to $\sum_{k=1}^{j}\binom{j-1}{k-1} k!2(j-k)!=\sum_{k=1}^{j} 2(j-1)!(k)=2(j-1)!\frac{j(j+1)}{2}=(j+1)!$. The induction is complete, and this finishes the proof.
+
+Alternate solution: Another method of performing the induction is noting that any acceptable sequence $\left(a_{0}, \ldots, a_{n}\right)$ can be matched with $n+2$ acceptable sequences of length $n+2$ because we can take $\left(3 a_{0}, \ldots, 3 a_{n}\right)$ and add an element with a difference of 1 in any of $n+2$ positions.
+7. [30] Find the maximum possible number of diagonals of equal length in a convex hexagon.
+
+Answer: 7 First, we will prove that 7 is possible. Consider the following hexagon $A B C D E F$ whose vertices are located at $A(0,0), B\left(\frac{1}{2}, 1-\frac{\sqrt{3}}{2}\right), C\left(\frac{1}{2}, \frac{\sqrt{3}}{2}\right), D(0,1), E\left(-\frac{1}{2}, \frac{\sqrt{3}}{2}\right), F\left(-\frac{1}{2}, 1-\frac{\sqrt{3}}{2}\right)$. One can easily verify that all diagonals but $B E$ and $C F$ have length 1.
+
+Now suppose that there are at least 8 diagonals in a certain convex hexagon $A B C D E F$ whose lengths are equal. There must be a diagonal such that, with this diagonal taken out, the other 8 have equal length. There are two cases.
+Case I. The diagonal is one of $A C, B D, C E, D F, E A, F B$. WLOG, assume it is $A C$. We have $E C=$ $E B=F B=F C$. Thus, $B$ and $C$ are both on the perpendicular bisector of $E F$. Since $A B C D E F$ is convex, both $B$ and $C$ must be on the same side of line $E F$, but this is impossible as one of $B$ or $C$, must be contained in triangle $C E F$. Contradiction.
+
+Case II: The diagonal is one of $A D, B E, C F$. WLOG, assume it is $A D$. Again, we have $E C=E B=$ $F B=F C$. By the above reasoning, this is a contradiction.
+Thus, 7 is the maximum number of possible diagonals.
+8. [35] Let $A B C$ be an acute triangle with circumcenter $O$ such that $A B=4, A C=5$, and $B C=6$. Let $D$ be the foot of the altitude from $A$ to $B C$, and $E$ be the intersection of $A O$ with $B C$. Suppose that $X$ is on $B C$ between $D$ and $E$ such that there is a point $Y$ on $A D$ satisfying $X Y \| A O$ and $Y O \perp A X$. Determine the length of $B X$.
+
+Answer: $96 / 41$ Let $A X$ intersect the circumcircle of $\triangle A B C$ again at $K$. Let $O Y$ intersect $A K$ and $B C$ at $T$ and $L$, respectively. We have $\angle L O A=\angle O Y X=\angle T D X=\angle L A K$, so $A L$ is tangent to the circumcircle. Furthermore, $O L \perp A K$, so $\triangle A L K$ is isosceles with $A L=A K$, so $A K$ is also tangent to the circumcircle. Since $B C$ and the tangents to the circumcircle at $A$ and $K$ all intersect at the same point $L, C L$ is a symmedian of $\triangle A C K$. Then $A K$ is a symmedian of $\triangle A B C$. Then we can use $\frac{B X}{X C}=\frac{(A B)^{2}}{(A C)^{2}}$ to compute $B X=\frac{96}{41}$.
+9. [35] For integers $m, n \geq 1$, let $A(n, m)$ be the number of sequences $\left(a_{1}, \cdots, a_{n m}\right)$ of integers satisfying the following two properties:
+(a) Each integer $k$ with $1 \leq k \leq n$ occurs exactly $m$ times in the sequence $\left(a_{1}, \cdots, a_{n m}\right)$.
+(b) If $i, j$, and $k$ are integers such that $1 \leq i \leq n m$ and $1 \leq j \leq k \leq n$, then $j$ occurs in the sequence $\left(a_{1}, \cdots, a_{i}\right)$ at least as many times as $k$ does.
+
+For example, if $n=2$ and $m=5$, a possible sequence is $\left(a_{1}, \cdots, a_{10}\right)=(1,1,2,1,2,2,1,2,1,2)$. On the other hand, the sequence $\left(a_{1}, \cdots, a_{10}\right)=(1,2,1,2,2,1,1,1,2,2)$ does not satisfy property (2) for $i=5, j=1$, and $k=2$.
+Prove that $A(n, m)=A(m, n)$.
+Answer: N/A Solution 1: We show that $A(n, m)$ is equal to the the number of standard Young tableaux with $n$ rows and $m$ columns (i.e. fillings of an $n \times m$ matrix with the numbers $1,2, \ldots, n m$ so that numbers are increasing in each row and column). Consider the procedure where every time a $k$ appears in the sequences, you add a number to the leftmost empty spot of the $k$-th row. Doing this procedure will result in a valid standard Young tableau. The entries are increasing along every row because new elements are added from left to right. The elements are also increasing along every column. This is because the condition about the sequences implies that there will always be at least as many elements in row $i$ as there are in row $j$ for $i
Saturday 22 February 2014
HMIC
+
+1. [20] Consider a regular $n$-gon with $n>3$, and call a line acceptable if it passes through the interior of this $n$-gon. Draw $m$ different acceptable lines, so that the $n$-gon is divided into several smaller polygons.
+(a) Prove that there exists an $m$, depending only on $n$, such that any collection of $m$ acceptable lines results in one of the smaller polygons having 3 or 4 sides.
+(b) Find the smallest possible $m$ which guarantees that at least one of the smaller polygons will have 3 or 4 sides.
+
+Answer: N/A We will prove that if $m \geq n-4$, then there is guaranteed to be a smaller polygon with 3 or 4 sides, while if $m \leq n-5$, there might not be a polygon with 3 or 4 sides. This will solve both parts of the problem.
+Given a configuration of lines, let $P_{1}, \ldots, P_{k}$ be all of the resulting smaller polygons. Let $E\left(P_{i}\right)$ be the number of edges in polygon $P_{i}$, and let $E=E\left(P_{1}\right)+\cdots+E\left(P_{k}\right)$. First, note that whenever a new polygon is formed, it must have been because a larger polygon was split into two smaller polygons by a line passing through it. When this happens, $k$ increases by 1 and $E$ increases by at most 4 (it might be less than 4 if the line passes through vertices of the larger polygon). Therefore, if adding an acceptable line increases the number of polygons by $a$, then $E$ increases by at most $4 a$.
+Now, assume $m \geq n-4$. At the beginning, we have $k=1$ and $E=n$. If the number of polygons at the end is $p+1$, then $E \leq n+4 p$, so the average number of edges per polygon is less than or equal to $\frac{n+4 p}{1+p}$. Now, note that each acceptable line introduces at least one new polygon, so $p \geq m \geq n-4$. Also, note that as $p$ increases, $\frac{n+4 p}{1+p}$ strictly decreases, so it is maximized at $p=n-4$, where $\frac{n+4 p}{1+p}=$ $\frac{5 n-16}{n-3}=5-\frac{1}{n-3}<5$. Therefore, the average number of edges per polygon is less than 5 , so there must exist a polygon with either 3 or 4 edges, as desired.
+We will now show that if $m \leq n-5$, then we can draw $m$ acceptable lines in a regular $n$-gon $A_{1} A_{2} \ldots A_{n}$ such that there are no polygons with 3 or 4 sides. Let $M_{1}$ be the midpoint of $A_{3} A_{4}$, $M_{2}$ be the midpoint of $A_{4} A_{5}, \ldots, M_{n-5}$ be the midpoint of $A_{n-3} A_{n-4}$. Let the $m$ acceptable lines be $A_{1} M_{1}, A_{1} M_{2}, \ldots, A_{1} M_{m}$. We can see that all resulting polygons have 5 sides or more, so we are done.
+2. [25] 2014 triangles have non-overlapping interiors contained in a circle of radius 1 . What is the largest possible value of the sum of their areas?
+Answer: N/A This problem turned out to be much trickier than we expected. We have yet to see a complete solution, but let us know if you find one!
+Comment. We apologize for the oversight on our part. Our test-solvers essentially all misread the problem to contain the additional assumption that all triangle vertices lie on the circumference (which is not the case).
+3. [30] Fix positive integers $m$ and $n$. Suppose that $a_{1}, a_{2}, \ldots, a_{m}$ are reals, and that pairwise distinct vectors $v_{1}, \ldots, v_{m} \in \mathbb{R}^{n}$ satisfy
+
+$$
+\sum_{j \neq i} a_{j} \frac{v_{j}-v_{i}}{\left\|v_{j}-v_{i}\right\|^{3}}=0
+$$
+
+for $i=1,2, \ldots, m$.
+Prove that
+
+$$
+\sum_{1 \leq i
Saturday 15 November 2014
General Test
+
+1. Two circles $\omega$ and $\gamma$ have radii 3 and 4 respectively, and their centers are 10 units apart. Let $x$ be the shortest possible distance between a point on $\omega$ and a point on $\gamma$, and let $y$ be the longest possible distance between a point on $\omega$ and a point on $\gamma$. Find the product $x y$.
+Answer: 51 Let $\ell$ be the line connecting the centers of $\omega$ and $\gamma$. Let $A$ and $B$ be the intersections of $\ell$ with $\omega$, and let $C$ and $D$ be the intersections of $\ell$ with $\gamma$, so that $A, B, C$, and $D$ are collinear, in that order. The shortest distance between a point on $\omega$ and a point on $\gamma$ is $B C=3$. The longest distance is $A D=3+10+4=17$. The product is 51 .
+2. Let $A B C$ be a triangle with $\angle B=90^{\circ}$. Given that there exists a point $D$ on $A C$ such that $A D=D C$ and $B D=B C$, compute the value of the ratio $\frac{A B}{B C}$.
+Answer: $\sqrt{3} \quad D$ is the circumcenter of $A B C$ because it is the midpoint of the hypotenuse. Therefore, $D B=D A=D C$ because they are all radii of the circumcircle, so $D B C$ is an equilateral triangle, and $\angle C=60^{\circ}$. This means that $A B C$ is a $30^{\circ}-60^{\circ}-90^{\circ}$ triangle, with $\frac{A B}{B C}=\sqrt{3}$.
+3. Compute the greatest common divisor of $4^{8}-1$ and $8^{12}-1$.
+
+Answer: 15 Let $d=\operatorname{gcd}(a, b)$ for some $a, b \in \mathbb{Z}^{+}$.
+Then, we can write $d=a x-b y$, where $x, y \in \mathbb{Z}^{+}$, and
+
+$$
+\begin{aligned}
+& 2^{a}-1 \mid 2^{a x}-1 \\
+& 2^{b}-1 \mid 2^{b y}-1
+\end{aligned}
+$$
+
+Multiplying the right-hand side of (2) by $2^{d}$, we get,
+
+$$
+2^{b}-1 \mid 2^{a x}-2^{d}
+$$
+
+Thus, $\operatorname{gcd}\left(2^{a}-1,2^{b}-1\right)=2^{d}-1=2^{\operatorname{gcd}(a, b)}-1$.
+
+Using $a=16$ and $b=36$, we get
+
+$$
+\operatorname{gcd}\left(2^{16}-1,2^{36}-1\right)=2^{\operatorname{gcd}(16,36)}-1=2^{4}-1=15
+$$
+
+4. In rectangle $A B C D$ with area 1 , point $M$ is selected on $\overline{A B}$ and points $X, Y$ are selected on $\overline{C D}$ such that $A X Saturday 15 November 2014
Guts Round
+
+1. [5] Solve for $x$ in the equation $20 \cdot 14+x=20+14 \cdot x$.
+
+Answer: 20 By inspection, $20+14 \cdot 20=20 \cdot 14+20$. Alternatively, one can simply compute $x=\frac{20 \cdot 14-20}{14-1}=20$.
+2. [5] Find the area of a triangle with side lengths 14,48 , and 50.
+
+Answer: 336 Note that this is a multiple of the 7-24-25 right triangle. The area is therefore
+
+$$
+\frac{14(48)}{2}=336
+$$
+
+3. [5] Victoria wants to order at least 550 donuts from Dunkin' Donuts for the HMMT 2014 November contest. However, donuts only come in multiples of twelve. Assuming every twelve donuts cost $\$ 7.49$, what is the minimum amount Victoria needs to pay, in dollars? (Because HMMT is affiliated with MIT, the purchase is tax exempt. Moreover, because of the size of the order, there is no delivery fee.)
+Answer: 344.54 The smallest multiple of 12 larger than 550 is $552=12 \cdot 46$. So the answer is $46 \cdot \$ 7.49$. To make the multiplication easier, we can write this as $46 \cdot(\$ 7.5-\$ 0.01)=\$ 345-\$ 0.46=$ $\$ 344.54$.
+Note: this is the actual cost of donuts at the 2014 HMMT November contest.
+4. [6] How many two-digit prime numbers have the property that both digits are also primes?
+
+Answer: 4 When considering the 16 two-digit numbers with $2,3,5$, and 7 as digits, we find that only $23,37,53$, and 73 have this property.
+5. [6] Suppose that $x, y, z$ are real numbers such that
+
+$$
+x=y+z+2, \quad y=z+x+1, \quad \text { and } \quad z=x+y+4
+$$
+
+Compute $x+y+z$.
+Answer: $\quad-7$ Adding all three equations gives
+
+$$
+x+y+z=2(x+y+z)+7
+$$
+
+from which we find that $x+y+z=-7$.
+6. [6] In the octagon COMPUTER exhibited below, all interior angles are either $90^{\circ}$ or $270^{\circ}$ and we have $C O=O M=M P=P U=U T=T E=1$.
+
+
+Point $D$ (not to scale in the diagram) is selected on segment $R E$ so that polygons COMPUTED and $C D R$ have the same area. Find $D R$.
+Answer: 2 The area of the octagon $C O M P U T E R$ is equal to 6 . So, the area of $C D R$ must be 3. So, we have the equation $\frac{1}{2} * C D * D R=[C D R]=3$. And from $C D=3$, we have $D R=2$.
+7. [7] Let $A B C D$ be a quadrilateral inscribed in a circle with diameter $\overline{A D}$. If $A B=5, A C=6$, and $B D=7$, find $C D$.
+Answer: $\sqrt{38}$ We have $A D^{2}=A B^{2}+B D^{2}=A C^{2}+C D^{2}$, so $C D=\sqrt{A B^{2}+B D^{2}-A C^{2}}=\sqrt{38}$.
+8. [7] Find the number of digits in the decimal representation of $2^{41}$.
+
+Answer: $\quad 13$ Noticing that $2^{10}=1024 \approx 1000$ allows for a good estimate. Alternatively, the number of decimal digits of $n$ is given by $\left\lfloor\log _{10}(n)\right\rfloor+1$. Using $\log _{10}(2) \approx 0.31$ also gives the correct answer. The exact value of $2^{41}$ is 2199023255552 .
+9. [7] Let $f$ be a function from the nonnegative integers to the positive reals such that $f(x+y)=f(x) \cdot f(y)$ holds for all nonnegative integers $x$ and $y$. If $f(19)=524288 k$, find $f(4)$ in terms of $k$.
+Answer: $16 k^{4 / 19}$ The given condition implies $f(m n)=f(m)^{n}$, so
+
+$$
+f(4)^{19}=f(4 \cdot 19)=f(19 \cdot 4)=f(19)^{4}
+$$
+
+and it follows that $f(4)=16 k^{4 / 19}$.
+10. [8] Let $A B C$ be a triangle with $C A=C B=5$ and $A B=8$. A circle $\omega$ is drawn such that the interior of triangle $A B C$ is completely contained in the interior of $\omega$. Find the smallest possible area of $\omega$.
+Answer: $16 \pi$ We need to contain the interior of $\overline{A B}$, so the diameter is at least 8 . This bound is sharp because the circle with diameter $\overline{A B}$ contains all of $A B C$. Hence the minimal area is $16 \pi$.
+11. [8] How many integers $n$ in the set $\{4,9,14,19, \ldots, 2014\}$ have the property that the sum of the decimal digits of $n$ is even?
+Answer: 201
+We know that 2014 does not qualify the property. So, we'll consider $\{4,9,14, \ldots, 2009\}$ instead. Now, we partition this set into 2 sets: $\{4,14,24, \ldots, 2004\}$ and $\{9,19,29, \ldots, 2009\}$.
+For each so the first and second set are basically $x 4$ and $x 9$, where $x=0,1,2, \ldots, 200$, respectively. And we know that for each value of $x, x$ must be either even or odd, which makes exactly one of $\{x 4, x 9\}$ has even sum of decimal digits. Therefore, there are in total of 201 such numbers.
+12. [8] Sindy writes down the positive integers less than 200 in increasing order, but skips the multiples of 10. She then alternately places + and - signs before each of the integers, yielding an expression $+1-2+3-4+5-6+7-8+9-11+12-\cdots-199$. What is the value of the resulting expression?
+Answer: -100 Group the numbers into $(1-2+3-4+\ldots+18-19)+(21-22+\ldots+38-39)+$ $\ldots+(181-182+\ldots+198-199)$. We can easily show that each group is equal to -10 , and so the answer is -100 .
+13. [9] Let $A B C$ be a triangle with $A B=A C=\frac{25}{14} B C$. Let $M$ denote the midpoint of $\overline{B C}$ and let $X$ and $Y$ denote the projections of $M$ onto $\overline{A B}$ and $\overline{A C}$, respectively. If the areas of triangle $A B C$ and quadrilateral $A X M Y$ are both positive integers, find the minimum possible sum of these areas.
+Answer: 1201 By similar triangles, one can show that $[A X M Y]=2 \cdot[A M X]=\left(\frac{24}{25}\right)^{2} \cdot 2[A B M]=$ $\left(\frac{24}{25}\right)^{2} \cdot[A B C]$. Thus the answer is $25^{2}+24^{2}=1201$.
+14. [9] How many ways can the eight vertices of a three-dimensional cube be colored red and blue such that no two points connected by an edge are both red? Rotations and reflections of a given coloring are considered distinct.
+Answer: $\quad 35$ We do casework on $R$, the number of red vertices. Let the cube be called $A B C D E F G H$, with opposite faces $A B C D$ and $E F G H$, such that $A$ is directly above $E$.
+
+- $\underline{R=0}$ : There is one such coloring, which has only blue vertices.
+- $\underline{R=1}$ : There are 8 ways to choose the red vertex, and all other vertices must be blue. There are 8 colorings in this case.
+- $\underline{R=2}$ : Any pair not an edge works, so the answer is $\binom{8}{2}-12=16$.
+- $\underline{R}=3$ : Each face $A B C D$ and $E F G H$ has at most two red spots. Assume WLOG $A B C D$ has exactly two and $E F G H$ has exactly one (multiply by 2 at the end). There are two ways to pick those in $A B C D$ (two opposite corners), and two ways after that to pick $E F G H$. Hence the grand total for this subcase is $2 \cdot 2 \cdot 2=8$.
+- $\underline{R=4}$ : There are only two ways to do this.
+
+Hence, the sum is 35 .
+15. [9] Carl is on a vertex of a regular pentagon. Every minute, he randomly selects an adjacent vertex (each with probability $\frac{1}{2}$ ) and walks along the edge to it. What is the probability that after 10 minutes, he ends up where he had started?
+Answer: $\frac{127}{512}$ Let A denote a clockwise move and B denote a counterclockwise move. We want to have some combination of 10 A's and B's, with the number of A's and the number of B's differing by a multiple of 5 . We have $\binom{10}{0}+\binom{10}{5}+\binom{10}{10}=254$. Hence the answer is $\frac{254}{2^{10}}=\frac{127}{512}$.
+16. [10] A particular coin has a $\frac{1}{3}$ chance of landing on heads (H), $\frac{1}{3}$ chance of landing on tails ( T ), and $\frac{1}{3}$ chance of landing vertically in the middle (M). When continuously flipping this coin, what is the probability of observing the continuous sequence HMMT before HMT?
+Answer: $\frac{1}{4}$ For a string of coin flips $S$, let $P_{S}$ denote the probability of flipping HMMT before $H M T$ if $S$ is the starting sequence of flips. We know that the desired probability, $p$, is $\frac{1}{3} P_{H}+\frac{1}{3} P_{M}+\frac{1}{3} P_{T}$. Now, using conditional probability, we find that
+
+$$
+\begin{aligned}
+P_{H} & =\frac{1}{3} P_{H H}+\frac{1}{3} P_{H M}+\frac{1}{3} P_{H T} \\
+& =\frac{1}{3} P_{H}+\frac{1}{3} P_{H M}+\frac{1}{3} P_{T} .
+\end{aligned}
+$$
+
+We similarly find that
+
+$$
+\begin{aligned}
+& P_{M}=P_{T}=\frac{1}{3} P_{H}+\frac{1}{3} P_{M}+\frac{1}{3} P_{T} \\
+& P_{H M}=\frac{1}{3} P_{H M M}+\frac{1}{3} P_{H} \\
+& P_{H M M}=\frac{1}{3}+\frac{1}{3} P_{M}+\frac{1}{3} P_{H} .
+\end{aligned}
+$$
+
+Solving gives $P_{H}=P_{M}=P_{T}=\frac{1}{4}$. Thus, $p=\frac{1}{4}$.
+17. [10] Let $A B C$ be a triangle with $A B=A C=5$ and $B C=6$. Denote by $\omega$ the circumcircle of $A B C$. We draw a circle $\Omega$ which is externally tangent to $\omega$ as well as to the lines $A B$ and $A C$ (such a circle is called an $A$-mixtilinear excircle). Find the radius of $\Omega$.
+Answer: $\quad \frac{75}{8}$ Let $M$ be the midpoint of $B C$. Let $D$ be the point diametrically opposite $A$ on the circumcircle, and let the $A$-mixtilinear excircle be tangent to lines $A B$ and $A C$ at $X$ and $Y$. Let $O$ be the center of the $A$-mixtilinear excircle.
+Notice that $\triangle A O X \sim \triangle A B M$. If we let $x$ be the desired radius, we have
+
+$$
+\frac{x+A D}{x}=\frac{5}{3} .
+$$
+
+We can compute $\frac{A D}{5}=\frac{5}{4}$ since $\triangle A D B \sim \triangle A B M$, we derive $A D=\frac{25}{4}$. From here it follows that $x=\frac{75}{8}$.
+18. [10] For any positive integer $x$, define $\operatorname{Accident}(x)$ to be the set of ordered pairs $(s, t)$ with $s \in$ $\{0,2,4,5,7,9,11\}$ and $t \in\{1,3,6,8,10\}$ such that $x+s-t$ is divisible by 12 . For any nonnegative integer $i$, let $a_{i}$ denote the number of $x \in\{0,1, \ldots, 11\}$ for which $|\operatorname{Accident}(x)|=i$. Find
+
+$$
+a_{0}^{2}+a_{1}^{2}+a_{2}^{2}+a_{3}^{2}+a_{4}^{2}+a_{5}^{2}
+$$
+
+Answer: 26 Modulo twelve, the first set turns out to be $\{-1 \cdot 7,0 \cdot 7, \ldots, 5 \cdot 7\}$ and the second set turns out to be be $\{6 \cdot 7, \ldots, 10 \cdot 7\}$. We can eliminate the factor of 7 and shift to reduce the problem to $s \in\{0,1, \ldots, 6\}$ and $t \in\{7, \ldots, 11\}$. With this we can easily compute $\left(a_{0}, a_{1}, a_{2}, a_{3}, a_{4}, a_{5}\right)=$ $(1,2,2,2,2,3)$. Therefore, the answer is 26 .
+It turns out that the choice of the sets correspond to the twelve keys of a piano in an octave. The first set gives the locations of the white keys, while the second set gives the location of the black keys. Steps of seven then correspond to perfect fifths. See, for example:
+
+- http://en.wikipedia.org/wiki/Music_and_mathematics
+- http://en.wikipedia.org/wiki/Guerino_Mazzola
+
+19. [11] Let a sequence $\left\{a_{n}\right\}_{n=0}^{\infty}$ be defined by $a_{0}=\sqrt{2}, a_{1}=2$, and $a_{n+1}=a_{n} a_{n-1}^{2}$ for $n \geq 1$. The sequence of remainders when $a_{0}, a_{1}, a_{2}, \cdots$ are divided by 2014 is eventually periodic with some minimal period $p$ (meaning that $a_{m}=a_{m+p}$ for all sufficiently large integers $m$, and $p$ is the smallest such positive integer). Find $p$.
+Answer: 12 Let $a_{n}=2^{b_{n}}$, so notice $b_{1}=1, b_{2}=2$, and $b_{n+1}=b_{n}+2 b_{n-1}$ for $n \geq 1$, so by inspection $b_{n}=2^{n-1}$ for all $n$; thus $a_{n}=2^{2^{n-1}}$. 2014 $=2 \cdot 19 \cdot 53$ so we just want to find the lcm of the eventual periods of $2^{n} \bmod \operatorname{ord}_{19}(2)$ and $\operatorname{ord}_{53}(2)$. These orders divide 18 and 52 respectively, and we can manually check $\operatorname{ord}_{9}(2)=6$ and $\operatorname{ord}_{13}(2)=12$. The lcm of these is 12 , so to show the answer is 12 , it suffices to show that $13 \mid \operatorname{ord}_{53}(2)$. This is true since $2^{4} \not \equiv 1(\bmod 53)$. So, the answer is 12 .
+20. [11] Determine the number of sequences of sets $S_{1}, S_{2}, \ldots, S_{999}$ such that
+
+$$
+S_{1} \subseteq S_{2} \subseteq \cdots \subseteq S_{999} \subseteq\{1,2, \ldots, 999\}
+$$
+
+Here $A \subseteq B$ means that all elements of $A$ are also elements of $B$.
+Answer: $10^{2997}$ OR $1000^{999}$ The idea is to look at each element individually, rather than each subset. For each $k \in\{1,2, \ldots, 999\}$, there are 1000 choices for the first subset in the chain that contains $k$. This count includes the possibility that $k$ doesn't appear in any of the subsets. If $S_{i}$ is the first subset containing $k$, for some $i \in\{1,2, \ldots, 999\}$, then $k$ is also in $S_{j}$, for all $i
Team Round
+
+1. [3] What is the smallest positive integer $n$ which cannot be written in any of the following forms?
+
+- $n=1+2+\cdots+k$ for a positive integer $k$.
+- $n=p^{k}$ for a prime number $p$ and integer $k$.
+- $n=p+1$ for a prime number $p$.
+
+Answer: 22 Consider $1,2,3,4,5,7,8,9,11,13,16,17,19$ are in the form $p^{k}$. So we are left with $6,10,12,14,15,18,20,21,22, \ldots$
+Next, $6,12,14,18,20$ are in the form $p+1$, so we are left with $10,15,21,22, \ldots$
+Finally, $10,15,21$ are in the form $n=1+2+\cdots+k$, so we are left with $22, \ldots$
+Since $22=2 \cdot 11$ is not a prime power, $22-1=21$ is not prime, and $1+2+\cdots+6=21<22<28=$ $1+2+\cdots+7,22$ is the smallest number not in the three forms, as desired.
+2. [5] Let $f(x)=x^{2}+6 x+7$. Determine the smallest possible value of $f(f(f(f(x))))$ over all real numbers $x$.
+Answer: 23 Consider that $f(x)=x^{2}+6 x+7=(x+3)^{2}-2$. So $f(x) \geq-2$ for real numbers $x$. Also, $f$ is increasing on the interval $[-3, \infty)$. Therefore
+
+$$
+\begin{gathered}
+f(f(x)) \geq f(-2)=-1, \\
+f(f(f(x))) \geq f(-1)=2,
+\end{gathered}
+$$
+
+and
+
+$$
+f(f(f(f(x)))) \geq f(2)=23
+$$
+
+Thus, the minimum value of $f(f(f(f(x))))$ is 23 and equality is obtained when $x=-3$.
+3. [5] The side lengths of a triangle are distinct positive integers. One of the side lengths is a multiple of 42 , and another is a multiple of 72 . What is the minimum possible length of the third side?
+Answer: $\sqrt{7}$ Suppose that two of the side lengths are $42 a$ and $72 b$, for some positive integers $a$ and $b$. Let $c$ be the third side length. We know that $42 a$ is not equal to $72 b$, since the side lengths are distinct. Also, $6 \mid 42 a-72 b$. Therefore, by the triangle inequality, we get $c>|42 a-72 b| \geq 6$ and thus $c \geq 7$. Hence, the minimum length of the third side is 7 and equality is obtained when $a=7$ and $b=4$.
+4. [3] How many ways are there to color the vertices of a triangle red, green, blue, or yellow such that no two vertices have the same color? Rotations and reflections are considered distinct.
+Answer: 24 There are 4 ways to color the first vertex, then 3 ways to color the second vertex to be distinct from the first, and finally 2 ways to color the third vertex to be distinct from the earlier two vertices. Multiplying gives 24 ways.
+5. [5] Let $A, B, C, D, E$ be five points on a circle; some segments are drawn between the points so that each of the $\binom{5}{2}=10$ pairs of points is connected by either zero or one segments. Determine the number of sets of segments that can be drawn such that:
+
+- It is possible to travel from any of the five points to any other of the five points along drawn segments.
+- It is possible to divide the five points into two nonempty sets $S$ and $T$ such that each segment has one endpoint in $S$ and the other endpoint in $T$.
+
+Answer: 195 First we show that we can divide the five points into sets $S$ and $T$ according to the second condition in only one way. Assume that we can divide the five points into $S \cup T$ and $S^{\prime} \cup T^{\prime}$. Then, let $A=S^{\prime} \cap S, B=S^{\prime} \cap T, C=T^{\prime} \cap S$, and $D=T^{\prime} \cap T$. Since $S, T$ and $S^{\prime}, T^{\prime}$ partition the set of five points, $A, B, C, D$ also partition the set of five points.
+Now, according to the second condition, there can only be segments between $S$ and $T$ and between $S^{\prime}$ and $T^{\prime}$. Therefore, the only possible segments are between points in $A$ and $D$, or between points in $B$ and $C$. Since, according to the first condition, the points are all connected via segments, it must be that $A=D=\varnothing$ or $B=C=\varnothing$. If $A=D=\varnothing$, then it follows that $S^{\prime}=T$ and $T^{\prime}=S$. Otherwise, if $B=C=\varnothing$, then $S^{\prime}=S$ and $T^{\prime}=T$. In either case, $S, T$ and $S^{\prime}, T^{\prime}$ are the same partition of the five points, as desired.
+We now determine the possible sets of segments with regard to the sets $S$ and $T$.
+Case 1: the two sets contain 4 points and 1 point. Then, there are $\binom{5}{1}=5$ ways to partition the points in this manner. Moreover, the 1 point (in its own set) must be connected to each of the other 4 points, and these are the only possible segments. Therefore, there is only 1 possible set of segments, which, combining with the 5 ways of choosing the sets, gives 5 possible sets of segments.
+Case 2: the two sets contain 3 points and 2 points. Then, there are $\binom{5}{2}=10$ ways to partition the points in this manner. Let $S$ be the set containing 3 points and $T$ the set containing 2 points. We consider the possible degrees of the points in $T$.
+
+- If both points have degree 3 , then each point must connect to all points in $S$, and the five points are connected via segments. So the number of possible sets of segments is 1 .
+- If the points have degree 3 and 2 . Then, we can swap the points in 2 ways, and, for the point with degree 2 , we can choose the elements of $S$ it connects to in $\binom{3}{2}=3$ ways. In each case, the five points are guaranteed to be connected via segments. Hence 6 ways.
+- If the points have degree 3 and 1 . Similarly, we can swap the points in 2 ways and connect the point with degree 1 to the elements of $S$ in $\binom{3}{1}=3$ ways. Since all five points are connected in all cases, we have 6 ways.
+- If both points have degree 2. Then, in order for the five points to be connected, the two points must connect to a common element of $S$. Call this common element $A$. Then, for the other two elements of $S$, each one must be connected to exactly one element of $T$. We can choose $A$ in 3 ways, and swap the correspondence between the other two elements of $S$ with the elements of $T$ in 2 ways. Hence 6 ways.
+- If the points have degree 2 and 1 . Then, in order to cover $S$, the point with degree 2 must connect to 2 points in $S$, and the point with degree 1 to the remaining point in $S$. But then, the five points will not be connected via segments, an impossibility.
+- If both points have degree 1. Then, similar to the previous case, it is impossible to cover all the 3 points in $S$ with only 2 segments, a contradiction.
+
+Combining the subcases, we have $1+6+6+6=19$ possible sets of segments with regard to a partition. With 10 possible partitions, we have a total of $19 \cdot 10=190$ possible sets of segments.
+Finally, combining this number with the 5 possibilities from case 1, we have a total of $5+190=195$ possibilities, as desired.
+6. [6] Find the number of strictly increasing sequences of nonnegative integers with the following properties:
+
+- The first term is 0 and the last term is 12 . In particular, the sequence has at least two terms.
+- Among any two consecutive terms, exactly one of them is even.
+
+Answer: 144 For a natural number $n$, let $A_{n}$ be a set containing all sequences which satisfy the problem conditions but which 12 is replaced by $n$. Also, let $a_{n}$ be the size of $A_{n}$.
+
+We first consider $a_{1}$ and $a_{2}$. We get $a_{1}=1$, as the only sequence satisfying the problem conditions is 0,1 . We also get $a_{2}=1$, as the only possible sequence is $0,1,2$.
+Next, we show that $a_{n+2}=a_{n+1}+a_{n}$ for all natural number $n$. We consider the second-to-last terms of each sequence in $A_{n+2}$.
+Case 1. The second-to-last term is $n+1$. When we leave out the last term, the remaining sequence will still satisfy the problem conditions, and hence is in $A_{n+1}$. Conversely, for a sequence in $A_{n+1}$, we could add $n+2$ at the end of that sequence, and since $n+1$ and $n+2$ have different parities, the resulting sequence will be in $A_{n+2}$. Therefore, there is a one-to-one correspondence between the sequences in this case and the sequences in $A_{n+1}$. So the number of sequences in this case is $a_{n+1}$.
+Case 2. The second-to-last term is less than or equal $n$. But $n$ and $n+2$ have the same parity, so the second-to-last term cannot exceed $n-1$. When we substitute the last term $(n+2)$ with $n$, the resulting sequence will satisfy the problem conditions and will be in $A_{n}$. Conversely, for a sequence in $A_{n}$, we could substitute its last term $n$, with $n+2$. As $n$ and $n+2$ have the same parity, the resulting sequence will be in $A_{n}$. Hence, in this case, the number of sequences is $a_{n}$.
+
+Now, since $a_{n+2}=a_{n+1}+a_{n}$ for all natural numbers $n$, we can recursively compute that the number of all possible sequences having their last terms as 12 is $a_{12}=144$. Note that the resulting sequence $\left(a_{n}\right)$ is none other than the Fibonacci numbers.
+7. [7] Sammy has a wooden board, shaped as a rectangle with length $2^{2014}$ and height $3^{2014}$. The board is divided into a grid of unit squares. A termite starts at either the left or bottom edge of the rectangle, and walks along the gridlines by moving either to the right or upwards, until it reaches an edge opposite the one from which the termite started. Depicted below are two possible paths of the termite.
+
+
+The termite's path dissects the board into two parts. Sammy is surprised to find that he can still arrange the pieces to form a new rectangle not congruent to the original rectangle. This rectangle has perimeter $P$. How many possible values of $P$ are there?
+Answer: 4 Let $R$ be the original rectangle and $R^{\prime}$ the new rectangle which is different from $R$. We see that the perimeter of $R^{\prime}$ depends on the possibilities for the side lengths of $R^{\prime}$.
+We will prove that the dividing line must have the following characterization: starting from the lower left corner of $R$, walk to the right by distance $a$, then walk up by distance $b$, for some positive number $a$ and $b$, and repeat the two steps until one reaches the upper right corner of $R$, with the condition that the last step is a walk to the right. (The directions stated here depends on the orientation of $R$, but we can always orient $R$ so as to fit the description.) Let there be $n+1$ walks to the right and $n$ walks to the top, then we have that this division would rearrange a rectangle of dimension $(n+1) a \times n b$ into a rectangle of dimension $n a \times(n+1) b$.
+Let us first assume the above. Now, according to the problem, it suffices to find $n, a, b$ such that $(n+1) a=2^{2014}, n b=3^{2014}$ or $(n+1) a=3^{2014}, n b=2^{2014}$. This means that $n+1$ and $n$ are a power of 3 and a power of 2 , whose exponents do not exceed 2014. This corresponds to finding nonnegative integers $k, l \leq 2014$ such that $\left|2^{k}-3^{l}\right|=1$. The only possible pairs of $\left(2^{k}, 3^{l}\right)$ are $(2,1),(2,3),(3,4)$ and $(8,9)$. So there are 4 possible configurations of $R^{\prime}$.
+Now, we prove our claim. For completeness, we will actually prove the claim more generally for any cut, not just ones that move right and up (hence the length of the solution which follows, but only the above two paragraphs are relevant for the purposes of finding the answer).
+
+First we show that the dividing boundary between the two pieces must meet the boundary of $R$ at two points, each being on opposite sides of $R$ as the other. To see why, consider that otherwise, there would be two consecutive sides of $R$ which belong to the same piece. Then, the smallest rectangle containing such a configuration must have each side being as large as each of the two sides, and thus it is $R$. Since this piece is also part of $R^{\prime}, R^{\prime}$ must contain $R$, but their areas are equal, so $R^{\prime}=R$, a contradiction.
+
+Now, let the dividing boundary go from the top side to the bottom side of $R$, and call the right piece "piece 1 " and the left piece "piece 2." We orient $R^{\prime}$ in such a way that piece 1 is fixed and piece 2 is moved from the original position in some way to create $R^{\prime}$. We will show that piece 2 must be moved by translation by some vector $v, t_{v}$. Otherwise, piece 2 is affected by $t_{v}$ as a well as a rotation by $90^{\circ}$ or $180^{\circ}$. We show that these cases are impossible.
+First, consider the case where there is a $90^{\circ}$ rotation. Let the distance from the top side to the bottom side of $R$ be $x$. Then, the two pieces are contained between a pair of horizontal lines which are of distance $x$ apart from one another. If piece 2 is rotated by $90^{\circ}$, then these horizontal lines become a pair of vertical lines which are of distance $x$ apart from one another. So $R^{\prime}$ is contained within a union of regions between a pair of horizontal lines and a pair of vertical lines.
+Now, we show that $R^{\prime}$ must be contained within only one of these regions. Consider if there exists points $\left(x_{1}, y_{1}\right)$ and $\left(x_{2}, y_{2}\right)$ in $R^{\prime}$ such that $\left(x_{1}, y_{1}\right)$ is not in the horizontal region (so that $y_{1}$ is out of range) and ( $x_{2}, y_{2}$ ) is not in the vertical region (so that $x_{2}$ is out of range). Then, it follows that $\left(x_{2}, y_{1}\right)$ is also in the rectangle $R^{\prime}$. But $\left(x_{2}, y_{1}\right)$ cannot be contained in either region, since both of its $x$ and $y$ coordinates are out of range, a contradiction.
+So let us assume, without loss of generality, that $R^{\prime}$ is contained in the vertical region (the one which contains piece 2). Then, the horizontal side of $R^{\prime}$ cannot have length greater than $x$, the width of the region. However, piece 2 is contained in the region, and its width is exactly $x$. Therefore, the width of $R^{\prime}$ must be exactly $x$, rendering it to be the same shape as $R$, a contradiction.
+
+Next, we show that the case with a $180^{\circ}$ rotation is also impossible. We modify our considerations from the previous case by considering a half-region of the region between a pair of horizontal lines (which are still are of distance $x$ apart), which we define as a part of the region on the right or on the left of a certain vertical line. Then, piece 2 is contained within a certain half-region going to the right and piece 1 is contained within a certain half-region going to the left. Now, in $R^{\prime}$, since piece 2 is rotated by $180^{\circ}$, we would have both half-regions going to the left, and $R^{\prime}$ is contained within a union of them.
+
+Now, consider the "end" of each half-region (the part of the boundary that is vertical). The ends of both half-regions must be contained in $R^{\prime}$, since they are part of piece 1 and piece 2 . Consider a vector that maps the end of one half-region to the other. If the vector is horizontal, then the union of the regions have vertical distance $x$. Similarly to the previous case, we deduce that the vertical side of $R$ must be of length no more than $x$, and so must be exactly $x$, but then $R^{\prime}=R$, a contradiction.
+Now, if the vector has both nonzero horizontal and vertical components, then the parallelogram generated by the locus of the end of a half-region being translated by the vector to the end of the other half-region must be contained within $R^{\prime}$ (since $R^{\prime}$ is convex). However, the parallelogram is not contained within the union of the two half-regions, a contradiction.
+Finally, if the vector is vertical, then the two half-regions must be on top of one another, and so will have no region in common. Then, since $R^{\prime}$ is a rectangle, the intersection of $R^{\prime}$ with each half-region will also be a rectangle. So pieces 1 and 2 must be rectangles. But then a rotation of $180^{\circ}$ would map piece 2 to itself. So this reduces to a case of pure translation.
+
+We now consider the translation $t_{v}$ by a vector $v$ on piece 2 . Since $R^{\prime}$ must contain the ends of the half-regions (which retain their original orientations), the vertical side of $R^{\prime}$ must be at least of length $x$. But $R^{\prime} \neq R$, so the vertical side of $R^{\prime}$ has length strictly greater than $x$. This implies that the horizontal side of $R^{\prime}$ must be strictly shorter than that of $R$, since they have equal area. However, the horizontal side of $R^{\prime}$ is at least as long as the horizontal distance between the ends of the two half-regions, so the ends of the two half-regions must have moved closer to one another horizontally.
+
+This implies that the vector $v$ has a positive $x$ component. Also, $v$ cannot be entirely horizontal, because there is no more space for piece 2 to move into. So $v$ has a nonzero $y$ component. Without loss of generality, let us assume that $v$ has a positive $y$ component.
+Before we continue further, let us label the vertices of $R$ as $A, B, C, D$, going in counter-clockwise direction, with the left side of $R$ being $A B$ and the right side of $R$ being $C D$. So $A B$ is in piece 2 and $C D$ is in piece 1. Call the translated piece 2 that is part of the rectangle $R^{\prime}$ piece $2^{\prime}$, with the corresponding points $A^{\prime}$ and $B^{\prime}$.
+Now, consider the half-regions of piece 1 and piece 2. They are half-regions with the end $A B$ going to the right and the one with the end $C D$ going to the left. So, in $R^{\prime}$, the half-regions are with end $A^{\prime} B^{\prime}$ going to the right and with end $C D$ going to the left, and $R^{\prime}$ is contained within the union of these two. Now, there cannot be a point in $R^{\prime}$ that is to the left of $A^{\prime} B^{\prime}$, since the smallest rectangle containing that point and $A^{\prime}$ would not be contained in the union of the two half-regions. Similarly, there cannot be a point in $R^{\prime}$ that is to the right of $C D$ for the same reason. These restrictions imply that $R^{\prime}$ must be contained within the union of the two half-regions that lie horizontally between $A^{\prime} B^{\prime}$ and $C D$. However, since the smallest rectangle containing $A^{\prime}$ and $C$ is precisely this region, $R^{\prime}$ must be this region. Let $A^{\prime} B^{\prime}$ intersect $B C$ at $L$ and let $C D$ intersect the line passing through $A^{\prime}$ which is parallel to $A D$ at $M$. We have $R^{\prime}=A^{\prime} L C M$.
+Now, consider the segments $B L$ and $L B^{\prime}$. We know that $B L$ is a boundary of piece 2 . Also, since $L B^{\prime}$ is a boundary of $R^{\prime}$ and it is below piece $2^{\prime}$, it cannot be a boundary of piece $2^{\prime}$. Therefore, it must be a boundary of piece 1 . Since $L B^{\prime}$ is not a boundary of $R$ but is a boundary of piece 1 , it must be part of the dividing boundary between piece 1 and 2 , and so must also be a boundary of piece 2 .
+We now prove that: from a sequence of $B, B^{\prime}, B^{\prime \prime}, \ldots$, each being translated from the preceding one by $v$, one of them must eventually lie on $A D$. Also, if $L, L^{\prime}, L^{\prime \prime}, \ldots$ is also a sequence of $L$ being successively translated by $v$, then, using $B_{i}$ and $L_{i}$ to designate the $i$ th term of each sequence: $B_{i} L_{i}$ and $L_{i} B_{i+1}$ must be part of the boundary of piece 2 for all $i \leq N-1$, where $B_{N}$ is the last point, the one that lies on $A D$.
+We have already proved the assertion for $i=1$. We now set out to prove, by induction, that $B_{i} L_{i}$ and $L_{i} B_{i+1}$ must be part of the boundary of piece 2 for all $i$ such that $B_{i+1}$ is still within $R$ or on the edge of $R$.
+Consider, by induction hypothesis, that $B_{i-1} L_{i-1}$ and $L_{i-1} B_{i}$ are parts of the boundary of piece 2 . Then, by mapping, $B_{i} L_{i}$ and $L_{i} B_{i+1}$ must be parts of the boundary of piece $2^{\prime}$. Since the dividing boundary of $R$ go from top to bottom, $L_{i} B_{i+1}$ cannot be on the rightmost edge of $R$, which is also the rightmost edge of $R^{\prime}$. This means that $L_{i} B_{i+1}$ is not a boundary of $R^{\prime}$. So we have that $B_{i} L_{i}$ and $L_{i} B_{i+1}$ are not boundaries of $R^{\prime}$ but are boundaries of piece $2^{\prime}$, so they must be boundaries of piece 1 . Now, since they are not boundaries of $R$ either but are boundaries of piece 1 , they must be boundaries of piece 2, as desired.
+Now we are left to show that one of $B_{i}$ must lie exactly on $A D$. Let $B_{i}$ be the last term of the sequence that is contained within $R$ or its boundary. Then, by the previous result, $B_{i-1} L_{i-1}$ and $L_{i-1} B_{i}$ are boundaries of piece 2. Then, by mapping, $B_{i} L_{i}$ is a boundary of piece $2^{\prime}$. Since $B_{i} L_{i}$ is on or below $A D$, it cannot be on the boundary of $R^{\prime}$, but since it is a boundary of piece $2^{\prime}$, it must also a boundary of piece 1 . Now, if $B_{i}$ is not on $A D$, then $B_{i} L_{i}$ will not be a boundary of $R$, but since it is a boundary of piece 1, it must also be a boundary of piece 2. By mapping, this implies that $B_{i+1} L_{i+1}$ must be a boundary of piece $2^{\prime}$. However, $B_{i+1} L_{i+1}$ is not contained within $R$ or its boundary, and so cannot be on piece 1's boundary. Therefore, since $B_{i+1} L_{i+1}$ is a boundary of piece $2^{\prime}$ but not of piece 1 , it must be a boundary of $R^{\prime}$. This means that $B_{i+1} L_{i+1}$ is on the upper edge of $R^{\prime}$. Mapping back, we get that $B_{i} L_{i}$ must be on the upper edge of $R$, a contradiction to the assumption that $B_{i}$ is not on $A D$ (the upper edge of $R$ ). So $B_{i}$ is on $A D$, as desired.
+Let $B_{N}$ be the term of the sequence that is on $A D$. We have now shown that
+
+$$
+L_{1} B_{2}, B_{2} L_{2}, \ldots, B_{N-1} L_{N-1}, L_{N-1} B_{N}
+$$
+
+completely defines the dividing line between piece 1 and piece 2 . Moreover, $B_{1}=B$, defining the starting point of the dividing line. We now add the final description: $L_{N}=D$. To see why, note that
+$L_{N}$ must be on the upper edge of $R$, as it is in the same horizontal level as $B_{N}$. However, since $L_{N-1}$ is one of furthest points to the right of piece 2 , by mapping, $L_{N}$ must be one of the furthest points to the right of piece $2^{\prime}$, and so must be on the rightmost edge of piece $2^{\prime}$, which is the rightmost edge of $R^{\prime}$ and of $R$. Therefore, $L_{N}$ is on the upper edge and the rightmost edge of $R$, and so it must be $D$, as desired.
+8. [3] Let $\mathcal{H}$ be a regular hexagon with side length one. Peter picks a point $P$ uniformly and at random within $\mathcal{H}$, then draws the largest circle with center $P$ that is contained in $\mathcal{H}$. What is this probability that the radius of this circle is less than $\frac{1}{2}$ ?
+Answer: $\frac{2 \sqrt{3}-1}{3}$ We first cut the regular hexagon $\mathcal{H}$ by segments connecting its center to each vertex into six different equilateral triangles with side lengths 1 . Therefore, each point inside $\mathcal{H}$ is contained in some equilateral triangle. We first see that for each point inside an equilateral triangle, the radius of the largest circle with center $P$ which is contained in $\mathcal{H}$ equals the shortest distance from $P$ to the nearest side of the hexagon, which is also a side of the triangle in which it is contained.
+Consider that the height of each triangle is $\frac{\sqrt{3}}{2}$. Therefore, the region inside the triangle containing all points with distance more than $\frac{1}{2}$ to the side of the hexagon is an equilateral triangle with a height of $\frac{\sqrt{3}-1}{2}$. Consequently, the area inside the triangle containing all points with distance less than $\frac{1}{2}$ to the side of the hexagon has area $\frac{\sqrt{3}}{4}\left(1-\left(\frac{\sqrt{3}-1}{\sqrt{3}}\right)^{2}\right)=\frac{\sqrt{3}}{4} \cdot\left(\frac{2 \sqrt{3}-1}{3}\right)$. This is of the ratio $\frac{2 \sqrt{3}-1}{3}$ to the area of the triangle, which is $\frac{\sqrt{3}}{4}$. Since all triangles are identical and the point $P$ is picked uniformly within $\mathcal{H}$, the probability that the radius of the largest circle with center $P$ which is contained in $\mathcal{H}$ is less than $\frac{1}{2}$ is $\frac{2 \sqrt{3}-1}{3}$, as desired.
+9. [5] How many lines pass through exactly two points in the following hexagonal grid?
+
+
+Answer: 60 First solution. From a total of 19 points, there are $\binom{19}{2}=171$ ways to choose two points. We consider lines that pass through more than 2 points.
+
+- There are $6+6+3=15$ lines that pass through exactly three points. These are: the six sides of the largest hexagon, three lines through the center (perpendicular to the sides of the largest hexagon), and the other six lines perpendiculars to the sides of the largest hexagon.
+- There are 6 lines that pass through exactly four points. (They are parallel to the sides of the largest hexagon.)
+- There are 3 lines that pass through exactly five points. (They all pass through the center.)
+
+For each $n=3,4,5$, a line that passes through $n$ points will be counted $\binom{n}{2}$ times, and so the corresponding amount will have to be subtracted. Hence the answer is
+
+$$
+171-\binom{3}{2} \cdot 15-\binom{4}{2} \cdot 6-\binom{5}{2} \cdot 3=171-45-36-30=60
+$$
+
+Second solution. We divide the points into 4 groups as follows.
+
+- Group 1 consists of the center point.
+- Group 2 consists of the 6 points surrounding the center.
+- Group 3 consists of the 6 vertices of the largest hexagon.
+- Group 4 consists of the 6 midpoints of the sides of the largest hexagon.
+
+We wish to count the number of lines that pass through exactly 2 points. Consider: all lines connecting points in group 1 and 2,1 and 3 , and 1 and 4 pass through more than 2 points. So it is sufficient to restrict our attention to group 2,3 and 4 .
+
+- For lines connecting group 2 and 2 , the only possibilities are those that the two endpoints are 120 degrees apart with respect to the center, so 6 possibilities.
+- For lines connecting group 3 and 3 , it is impossible.
+- For lines connecting group 4 and 4 , the two endpoints must be 60 degrees apart with respect to the center, so 6 possibilities.
+- For lines connecting group 3 and 2 . For each point in group 3 , the only possible points in group 2 are those that are 120 degrees apart from the point in group 3. So $2 \cdot 6=12$ possibilities.
+- For lines connecting group 4 and 2 , the endpoints must be 150 degrees apart with respect to the center, so $2 \cdot 6=12$ possibilities.
+- For lines connecting group 4 and 3 . For each point in group 4 , any point in group 3 works except those that are on the side on the largest hexagon of which the point in group 4 is the midpoint. Hence $4 \cdot 6=24$ possibilities.
+
+Therefore, the number of lines passing through 2 points is $6+6+12+12+24=60$, as desired.
+10. [8] Let $A B C D E F$ be a convex hexagon with the following properties.
+(a) $\overline{A C}$ and $\overline{A E}$ trisect $\angle B A F$.
+(b) $\overline{B E} \| \overline{C D}$ and $\overline{C F} \| \overline{D E}$.
+(c) $A B=2 A C=4 A E=8 A F$.
+
+Suppose that quadrilaterals $A C D E$ and $A D E F$ have area 2014 and 1400, respectively. Find the area of quadrilateral $A B C D$.
+Answer: 7295 From conditions (a) and (c), we know that triangles $A F E, A E C$ and $A C B$ are similar to one another, each being twice as large as the preceding one in each dimension. Let $\overline{A E} \cap \overline{F C}=P$ and $\overline{A C} \cap \overline{E B}=Q$. Then, since the quadrilaterals $A F E C$ and $A E C B$ are similar to one another, we have $A P: P E=A Q: Q C$. Therefore, $\overline{P Q} \| \overline{E C}$.
+Let $\overline{P C} \cap \overline{Q E}=T$. We know by condition (b) that $\overline{B E} \| \overline{C D}$ and $\overline{C F} \| \overline{D E}$. Therefore, triangles $P Q T$ and $E C D$ have their three sides parallel to one another, and so must be similar. From this we deduce that the three lines joining the corresponding vertices of the two triangles must meet at a point, i.e., that $P E, T D, Q C$ are concurrent. Since $P E$ and $Q C$ intersect at $A$, the points $A, T, D$ are collinear. Now, because $T C D E$ is a parallelogram, $\overline{T D}$ bisects $\overline{E C}$. Therefore, since $A, T, D$ are collinear, $\overline{A D}$ also bisects $\overline{E C}$. So the triangles $A D E$ and $A C D$ have equal area.
+Now, since the area of quadrilateral $A C D E$ is 2014, the area of triangle $A D E$ is $2014 / 2=1007$. And since the area of quadrilateral $A D E F$ is 1400 , the area of triangle $A F E$ is $1400-1007=393$. Therefore, the area of quadrilateral $A B C D$ is $16 \cdot 393+1007=7295$, as desired.
+
diff --git a/HarvardMIT/md/en-181-2014-nov-thm-solutions.md b/HarvardMIT/md/en-181-2014-nov-thm-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..6a5bbf5c9d96f1baa22e6fb9751fdc310fe0bcd6
--- /dev/null
+++ b/HarvardMIT/md/en-181-2014-nov-thm-solutions.md
@@ -0,0 +1,100 @@
+# HMMT November 2014
Saturday 15 November 2014
Theme Round
+
+1. Find the probability that the townspeople win if there are initially two townspeople and one goon.
+
+Answer: $\quad \frac{1}{3}$ The goon is chosen on the first turn with probability $\frac{1}{3}$, and this is necessary and sufficient for the townspeople to win.
+2. Find the smallest positive integer $n$ such that, if there are initially $2 n$ townspeople and 1 goon, then the probability the townspeople win is greater than $50 \%$.
+Answer: 3 We instead consider the probability the goon wins. The game clearly must last $n$ days. The probability the goon is not sent to jail on any of these $n$ days is then
+
+$$
+\frac{2 n}{2 n+1} \cdot \frac{2 n-2}{2 n-1} \cdots \cdots \frac{2}{3}
+$$
+
+If $n=2$ then the probability the goon wins is $\frac{4}{5} \cdot \frac{2}{3}=\frac{8}{15}>\frac{1}{2}$, but when $n=3$ we have $\frac{6}{7} \cdot \frac{8}{15}=\frac{16}{35}<\frac{1}{2}$, so the answer is $n=3$.
+Alternatively, the let $p_{n}$ be the probability that $2 n$ townspeople triumph against 1 goon. There is a $\frac{1}{2 n+1}$ chance that the goon is jailed during the first morning and the townspeople win. Otherwise, the goon eliminates one townperson during the night. We thus have $2 n-2$ townspeople and 1 goon left, so the probability that the town wins is $p_{n-1}$. We obtain the recursion
+
+$$
+p_{n}=\frac{1}{2 n+1}+\frac{2 n}{2 n+1} p_{n-1} .
+$$
+
+By the previous question, we have the initial condition $p_{1}=\frac{1}{3}$. We find that $p_{2}=\frac{7}{15}<\frac{1}{2}$ and $p_{3}=\frac{19}{35}>\frac{1}{2}$, yielding $n=3$ as above.
+3. Find the smallest positive integer $n$ such that, if there are initially $n+1$ townspeople and $n$ goons, then the probability the townspeople win is less than $1 \%$.
+Answer: 6 By a similar inductive argument, the probability for a given $n$ is
+
+$$
+p_{n}=\frac{n!}{(2 n+1)!!} .
+$$
+
+Clearly this is decreasing in $n$. It is easy to see that
+
+$$
+p_{5}=\frac{1 \cdot 2 \cdot 3 \cdot 4 \cdot 5}{3 \cdot 5 \cdot 7 \cdot 9 \cdot 11}=\frac{8}{693}>0.01
+$$
+
+and
+
+$$
+p_{6}=\frac{6}{13} p_{5}=\frac{48}{693 \cdot 13}<0.01
+$$
+
+Hence the answer is $n=6$. Heuristically, $p_{n+1} \approx \frac{1}{2} p_{n}$ for each $n$, so arriving at these estimates for the correct answer of $n$ is not difficult.
+4. Suppose there are initially 1001 townspeople and two goons. What is the probability that, when the game ends, there are exactly 1000 people in jail?
+Answer: $\frac{3}{1003}$ By considering the parity of the number of people in jail, we see that this situation arises if and only if the goons win after the 500 th night. That means that at this point we must have exactly one townsperson and two goons remaining. In other words, this situation arises if and only if no goon is ever sent to jail. The probability that this occurs is
+
+$$
+\frac{1001}{1003} \cdot \frac{999}{1001} \cdot \frac{997}{999} \cdot \ldots \frac{3}{5}=\frac{3}{1003}
+$$
+
+5. Suppose that there are initially eight townspeople and one goon. One of the eight townspeople is named Jester. If Jester is sent to jail during some morning, then the game ends immediately in his sole victory. (However, the Jester does not win if he is sent to jail during some night.)
+Find the probability that only the Jester wins.
+Answer: $\frac{1}{3}$ Let $a_{n}$ denote the answer when there are $2 n-1$ regular townies, one Jester, and one goon. It is not hard to see that $a_{1}=\frac{1}{3}$. Moreover, we have a recursion
+
+$$
+a_{n}=\frac{1}{2 n+1} \cdot 1+\frac{1}{2 n+1} \cdot 0+\frac{2 n-1}{2 n+1}\left(\frac{1}{2 n-1} \cdot 0+\frac{2 n-2}{2 n-1} \cdot a_{n-1}\right)
+$$
+
+The recursion follows from the following consideration: during the day, there is a $\frac{1}{2 n+1}$ chance the Jester is sent to jail and a $\frac{1}{2 n+1}$ chance the goon is sent to jail, at which point the game ends. Otherwise, there is a $\frac{1}{2 n-1}$ chance that the Jester is selected to be jailed from among the townies during the evening. If none of these events occur, then we arrive at the situation of $a_{n-1}$.
+Since $a_{1}=\frac{1}{3}$, we find that $a_{n}=\frac{1}{3}$ for all values of $n$. This gives the answer.
+6. Let $\mathcal{P}_{1}, \mathcal{P}_{2}, \mathcal{P}_{3}$ be pairwise distinct parabolas in the plane. Find the maximum possible number of intersections between two or more of the $\mathcal{P}_{i}$. In other words, find the maximum number of points that can lie on two or more of the parabolas $\mathcal{P}_{1}, \mathcal{P}_{2}, \mathcal{P}_{3}$.
+Answer: 12 Note that two distinct parabolas intersect in at most 4 points, which is not difficult to see by drawing examples 1 Given three parabolas, each pair intersects in at most 4 points, for at most $4 \cdot 3=12$ points of intersection in total. It is easy to draw an example achieving this maximum, for example, by slanting the parabolas at different angles.
+7. Let $\mathcal{P}$ be a parabola with focus $F$ and directrix $\ell$. A line through $F$ intersects $\mathcal{P}$ at two points $A$ and $B$. Let $D$ and $C$ be the feet of the altitudes from $A$ and $B$ onto $\ell$, respectively. Given that $A B=20$ and $C D=14$, compute the area of $A B C D$.
+Answer: 140 Observe that $A D+B C=A F+F B=20$, and that $A B C D$ is a trapezoid with height $B C=14$. Hence the answer is $\frac{1}{2}(A D+B C)(14)=140$.
+8. Consider the parabola consisting of the points $(x, y)$ in the real plane satisfying
+
+$$
+(y+x)=(y-x)^{2}+3(y-x)+3 .
+$$
+
+Find the minimum possible value of $y$.
+Answer: $\quad-\frac{1}{2}$ Let $w=y-x$. Adding $w$ to both sides and dividing by two gives
+
+$$
+y=\frac{w^{2}+4 w+3}{2}=\frac{(w+2)^{2}-1}{2}
+$$
+
+which is minimized when $w=-2$. This yields $y=-\frac{1}{2}$.
+9. In equilateral triangle $A B C$ with side length 2 , let the parabola with focus $A$ and directrix $B C$ intersect sides $A B$ and $A C$ at $A_{1}$ and $A_{2}$, respectively. Similarly, let the parabola with focus $B$ and directrix $C A$ intersect sides $B C$ and $B A$ at $B_{1}$ and $B_{2}$, respectively. Finally, let the parabola with focus $C$ and directrix $A B$ intersect sides $C A$ and $C B$ at $C_{1}$ and $C_{2}$, respectively.
+Find the perimeter of the triangle formed by lines $A_{1} A_{2}, B_{1} B_{2}, C_{1} C_{2}$.
+Answer: $\quad 66-36 \sqrt{3}$ Since everything is equilateral it's easy to find the side length of the wanted triangle. By symmetry, it's just $A A_{1}+2 A_{1} B_{2}=3 A A_{1}-A B$. Using the definition of a parabola, $A A_{1}=\frac{\sqrt{3}}{2} A_{1} B$ so some calculation gives a side length of $2(11-6 \sqrt{3})$, thus the perimeter claimed.
+
+10. Let $z$ be a complex number and $k$ a positive integer such that $z^{k}$ is a positive real number other than 1. Let $f(n)$ denote the real part of the complex number $z^{n}$. Assume the parabola $p(n)=a n^{2}+b n+c$ intersects $f(n)$ four times, at $n=0,1,2,3$. Assuming the smallest possible value of $k$, find the largest possible value of $a$.
+Answer: $\boxed{\frac{1}{3}}$ Let $r=|z|$, $\theta = \arg z$, and $C = \frac{\Re z}{|z|} = \cos \theta = \cos \frac{2\pi j}{k}$ for some $j$ with $\gcd(j, k) = 1$. The condition of the four consecutive points lying on a parabola is equivalent to having the finite difference
+$$
+f(3)-3 f(2)+3 f(1)-f(0)=0
+$$
+
+This implies
+
+$$
+\begin{aligned}
+f(3)-f(0) & =3[f(2)-f(1)] \\
+\Longleftrightarrow r^{3} \cos (3 \theta)-1 & =3\left(r^{2} \cos (2 \theta)-r \cos (\theta)\right) \\
+\Longleftrightarrow r^{3}\left(4 C^{3}-3 C\right)-1 & =3\left(r^{2}\left(2 C^{2}-1\right)-r C\right)
+\end{aligned}
+$$
+
+Now we simply test the first few possible values of $k$.
+$k=1$ implies $C=1$, which gives $r^{3}-1=3\left(r^{2}-r\right) \Longrightarrow(r-1)^{3}=0 \Longrightarrow r=1$. This is not allowed since $r=1$ implies a periodic function.
+$k=2$ implies $C=-1$, which gives $-r^{3}-1=3 r^{2}+r \Longrightarrow(r+1)^{3}=0$, again not allowed since $r>0$. $k=3$ implies $C=-\frac{1}{2}$. This gives $r^{3}-1=\frac{-3}{2}\left(r^{2}-r\right) \Longrightarrow(r-1)\left(r+\frac{1}{2}\right)(r+2)=0$. These roots are either negative or 1 , again not allowed.
+$k=4$ implies $C=0$. This gives $-1=-3 r^{2} \Longrightarrow r= \pm \frac{1}{\sqrt{3}} \cdot r=\frac{1}{\sqrt{3}}$ is allowed, so this will generate our answer.
+Again by finite differences (or by any other method of interpolating with a quadratic), we get $2 a=$ $f(0)+f(2)-2 f(1)=\frac{2}{3}$, so $a=\frac{1}{3}$.
diff --git a/HarvardMIT/md/en-182-2015-feb-alg-solutions.md b/HarvardMIT/md/en-182-2015-feb-alg-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..9def41be7a6d449789915459d6fb8df66f0cdee6
--- /dev/null
+++ b/HarvardMIT/md/en-182-2015-feb-alg-solutions.md
@@ -0,0 +1,240 @@
+# HMMT February 2015
+
+## Saturday 21 February 2015
+
+## Algebra
+
+1. Let $Q$ be a polynomial
+
+$$
+Q(x)=a_{0}+a_{1} x+\cdots+a_{n} x^{n}
+$$
+
+where $a_{0}, \ldots, a_{n}$ are nonnegative integers. Given that $Q(1)=4$ and $Q(5)=152$, find $Q(6)$.
+Answer: 254 Since each $a_{i}$ is a nonnegative integer, $152=Q(5) \equiv a_{0}(\bmod 5)$ and $Q(1)=4 \Longrightarrow$ $a_{i} \leq 4$ for each $i$. Thus, $a_{0}=2$. Also, since $5^{4}>152=Q(5), a_{4}, a_{5}, \ldots, a_{n}=0$.
+Now we simply need to solve the system of equations
+
+$$
+\begin{aligned}
+5 a_{1}+5^{2} a_{2}^{2}+5^{3} a_{3}^{3} & =150 \\
+a_{1}+a_{2}+a_{3} & =2
+\end{aligned}
+$$
+
+to get
+
+$$
+a_{2}+6 a_{3}=7
+$$
+
+Since $a_{2}$ and $a_{3}$ are nonnegative integers, $a_{2}=1, a_{3}=1$, and $a_{1}=0$. Therefore, $Q(6)=6^{3}+6^{2}+2=$ 254.
+2. The fraction $\frac{1}{2015}$ has a unique "(restricted) partial fraction decomposition" of the form
+
+$$
+\frac{1}{2015}=\frac{a}{5}+\frac{b}{13}+\frac{c}{31}
+$$
+
+where $a, b, c$ are integers with $0 \leq a<5$ and $0 \leq b<13$. Find $a+b$.
+Answer: 14 This is equivalent to $1=13 \cdot 31 a+5 \cdot 31 b+5 \cdot 13 c 1$ Taking modulo 5 gives $1 \equiv 3 \cdot 1 a$ $(\bmod 5)$, so $a \equiv 2(\bmod 5)$. Taking modulo 13 gives $1 \equiv 5 \cdot 5 b=25 b \equiv-b(\bmod 13)$, so $b \equiv 12$ (mod 13). The size constraints on $a, b$ give $a=2, b=12$, so $a+b=14$.
+Remark. This problem illustrates the analogy between polynomials and integers, with prime powers (here $5^{1}, 13^{1}, 31^{1}$ ) taking the role of powers of irreducible polynomials (such as $(x-1)^{1}$ or $\left(x^{2}+1\right)^{3}$, when working with polynomials over the real numbers).
+Remark. The "partial fraction decomposition" needs to be restricted since it's only unique "modulo $1 "$. Abstractly, the abelian group (or $\mathbb{Z}$-module) $\mathbb{Q} / \mathbb{Z}$ has a "prime power direct sum decomposition" (more or less equivalent to Bezout's identity, or the Chinese remainder theorem), but $\mathbb{Q}$ itself (as an abelian group under addition) does not.
+
+You may wonder whether there's a similar "prime power decomposition" of $\mathbb{Q}$ that accounts not just for addition, but also for multiplication (i.e. the full ring structure of the rationals). In some sense, the ' $a$ adeles/ideles' 'serve this purpose, but it's not as clean as the partial fraction decomposition (for additive structure alone) - in fact, the subtlety of adeles/ideles reflects much of the difficulty in number theory!
+3. Let $p$ be a real number and $c \neq 0$ an integer such that
+
+$$
+c-0.1
\section*{Saturday 21 February 2015}
+
+## Geometry
+
+1. Let $R$ be the rectangle in the Cartesian plane with vertices at $(0,0),(2,0),(2,1)$, and $(0,1)$. $R$ can be divided into two unit squares, as shown.
+
+
+Pro selects a point $P$ uniformly at random in the interior of $R$. Find the probability that the line through $P$ with slope $\frac{1}{2}$ will pass through both unit squares.
+Answer: $\frac{3}{4}$
+
+
+Precisely the middle two (of four) regions satisfiy the problem conditions, and it's easy to compute the (fraction of) areas as $\frac{3}{4}$.
+2. Let $A B C$ be a triangle with orthocenter $H$; suppose that $A B=13, B C=14, C A=15$. Let $G_{A}$ be the centroid of triangle $H B C$, and define $G_{B}, G_{C}$ similarly. Determine the area of triangle $G_{A} G_{B} G_{C}$.
+Answer: $\quad 28 / 3$ Let $D, E, F$ be the midpoints of $B C, C A$, and $A B$, respectively. Then $G_{A} G_{B} G_{C}$ is the $D E F$ about $H$ with a ratio of $\frac{2}{3}$, and $D E F$ is the dilation of $A B C$ about $H$ with a ratio of $-\frac{1}{2}$, so $G_{A} G_{B} G_{C}$ is the dilation of $A B C$ about $H$ with ratio $-\frac{1}{3}$. Thus $\left[G_{A} G_{B} G_{C}\right]=\frac{[A B C]}{9}$. By Heron's formula, the area of $A B C$ is $\sqrt{21 \cdot 8 \cdot 7 \cdot 6}=84$, so the area of $G_{A} G_{B} G_{C}$ is $[A B C] / 9=84 / 9=28 / 3$.
+3. Let $A B C D$ be a quadrilateral with $\angle B A D=\angle A B C=90^{\circ}$, and suppose $A B=B C=1, A D=2$. The circumcircle of $A B C$ meets $\overline{A D}$ and $\overline{B D}$ at points $E$ and $F$, respectively. If lines $A F$ and $C D$ meet at $K$, compute $E K$.
+Answer: $\frac{\sqrt{2}}{2}$ Assign coordinates such that $B$ is the origin, $A$ is $(0,1)$, and $C$ is $(1,0)$. Clearly, $E$ is the point $(1,1)$. Since the circumcenter of ABC is $\left(\frac{1}{2}, \frac{1}{2}\right)$, the equation of the circumcircle of $A B C$ is $\left(x-\frac{1}{2}\right)^{2}+\left(y-\frac{1}{2}\right)^{2}=\frac{1}{2}$. Since line $B D$ is given by $x=2 y$, we find that $F$ is at $\left(\frac{6}{5}, \frac{3}{5}\right)$. The intersection of $A F$ with $C D$ is therefore at $\left(\frac{3}{2}, \frac{1}{2}\right)$, so $K$ is the midpoint of $C D$. As a result, $E K=\frac{\sqrt{2}}{2}$.
+This is in fact a special case of APMO 2013, Problem 5 , when the quadrilateral is a square.
+4. Let $A B C D$ be a cyclic quadrilateral with $A B=3, B C=2, C D=2, D A=4$. Let lines perpendicular to $\overline{B C}$ from $B$ and $C$ meet $\overline{A D}$ at $B^{\prime}$ and $C^{\prime}$, respectively. Let lines perpendicular to $\overline{A D}$ from $A$ and $D$ meet $\overline{B C}$ at $A^{\prime}$ and $D^{\prime}$, respectively. Compute the ratio $\frac{\left[B C C^{\prime} B^{\prime}\right]}{\left[D A A^{\prime} D^{\prime}\right]}$, where $[\varpi]$ denotes the area of figure $\varpi$.
+
+Answer: $\quad$| $\frac{37}{76}$ |
+| :---: |
+| To get a handle on the heights $C B^{\prime}$, etc. perpendicular to $B C$ and $A D$, let | $X=B C \cap A D$, which lies on ray $\overrightarrow{B C}$ and $\overrightarrow{A D}$ since $\widehat{A B}>\widehat{C D}$ (as chords $A B>C D$ ).
+
+By similar triangles we have equality of ratios $X C: X D: 2=(X D+4):(X C+2): 3$, so we have a system of linear equations: $3 X C=2 X D+8$ and $3 X D=2 X C+4$, so $9 X C=6 X D+24=4 X C+32$ gives $X C=\frac{32}{5}$ and $X D=\frac{84 / 5}{3}=\frac{28}{5}$.
+It's easy to compute the trapezoid area ratio $\frac{\left[B C^{\prime} B^{\prime} C\right]}{\left[A A^{\prime} D^{\prime} D\right]}=\frac{B C\left(C B^{\prime}+B C^{\prime}\right)}{A D\left(A D^{\prime}+D A^{\prime}\right)}=\frac{B C}{A D} \frac{X C+X B}{X A+X D}$ (where we have similar right triangles due to the common angle at $X$ ). This is just $\frac{B C}{A D} \frac{X C+B C / 2}{X D+A D / 2}=\frac{2}{4} \frac{32 / 5+1}{28 / 5+2}=\frac{37}{76}$.
+5. Let $I$ be the set of points $(x, y)$ in the Cartesian plane such that
+
+$$
+x>\left(\frac{y^{4}}{9}+2015\right)^{1 / 4}
+$$
+
+Let $f(r)$ denote the area of the intersection of $I$ and the disk $x^{2}+y^{2} \leq r^{2}$ of radius $r>0$ centered at the origin $(0,0)$. Determine the minimum possible real number $L$ such that $f(r)
Team
+
+1. [5] The complex numbers $x, y, z$ satisfy
+
+$$
+\begin{aligned}
+x y z & =-4 \\
+(x+1)(y+1)(z+1) & =7 \\
+(x+2)(y+2)(z+2) & =-3
+\end{aligned}
+$$
+
+Find, with proof, the value of $(x+3)(y+3)(z+3)$.
+Answer: -28 Solution 1. Consider the cubic polynomial $f(t)=(x+t)(y+t)(z+t)$. By the theory of finite differences, $f(3)-3 f(2)+3 f(1)-f(0)=3!=6$, since $f$ is monic. Thus $f(3)=$ $6+3 f(2)-3 f(1)+f(0)=6+3(-3)-3(7)+(-4)=-28$.
+Solution 2. Alternatively, note that the system of equations is a (triangular) linear system in $w:=x y z$, $v:=x y+y z+z x$, and $u:=x+y+z$. The unique solution $(u, v, w)$ to this system is $\left(-\frac{27}{2}, \frac{47}{2},-4\right)$. Plugging in yields
+
+$$
+\begin{aligned}
+(x+3)(y+3)(z+3) & =w+3 v+9 u+27 \\
+& =-4+3 \cdot \frac{47}{2}+9 \cdot\left(-\frac{27}{2}\right)+27 \\
+& =-28
+\end{aligned}
+$$
+
+Remark. Since $f(0)<0, f(1)>0, f(2)<0, f(+\infty)>0$, the intermediate value theorem tells us the roots $-x,-y,-z$ of $f$ are real numbers in $(0,1),(1,2)$, and $(2,+\infty)$, in some order. With a little more calculation, one finds that $x, y, z$ are the three distinct zeroes of the polynomial $X^{3}+\frac{27}{2} X^{2}+\frac{47}{2} X+4$. The three zeroes are approximately $-11.484,-1.825$, and -0.191 .
+2. [10] Let $P$ be a (non-self-intersecting) polygon in the plane. Let $C_{1}, \ldots, C_{n}$ be circles in the plane whose interiors cover the interior of $P$. For $1 \leq i \leq n$, let $r_{i}$ be the radius of $C_{i}$. Prove that there is a single circle of radius $r_{1}+\cdots+r_{n}$ whose interior covers the interior of $P$.
+Answer: N/A If $n=1$, we are done. Suppose $n>1$. Since $P$ is connected, there must be a point $x$ on the plane which lies in the interiors of two circles, say $C_{i}, C_{j}$. Let $O_{i}, O_{j}$, respectively, be the centers of $C_{i}, C_{j}$. Since $O_{i} O_{j}
February 20, 2016
Algebra
+
+1. Let $z$ be a complex number such that $|z|=1$ and $|z-1.45|=1.05$. Compute the real part of $z$.
+
+Proposed by: Evan Chen
+Answer: $\quad \frac{20}{29}$
+From the problem, let $A$ denote the point $z$ on the unit circle, $B$ denote the point 1.45 on the real axis, and $O$ the origin. Let $A H$ be the height of the triangle $O A H$ and $H$ lies on the segment $O B$. The real part of $z$ is $O H$. Now we have $O A=1, O B=1.45$, and $A B=1.05$. Thus
+
+$$
+O H=O A \cos \angle A O B=\cos \angle A O B=\frac{1^{2}+1.45^{2}-1.05^{2}}{2 \cdot 1 \cdot 1.45}=\frac{20}{29}
+$$
+
+2. For which integers $n \in\{1,2, \ldots, 15\}$ is $n^{n}+1$ a prime number?
+
+Proposed by: Evan Chen
+Answer: $1,2,4$
+$n=1$ works. If $n$ has an odd prime factor, you can factor, and this is simulated also by $n=8$ :
+
+$$
+a^{2 k+1}+1=(a+1)\left(\sum_{i=0}^{2 k}(-a)^{i}\right)
+$$
+
+with both parts larger than one when $a>1$ and $k>0$. So it remains to check 2 and 4 , which work. Thus the answers are 1,2,4.
+3. Let $A$ denote the set of all integers $n$ such that $1 \leq n \leq 10000$, and moreover the sum of the decimal digits of $n$ is 2. Find the sum of the squares of the elements of $A$.
+Proposed by: Evan Chen
+Answer: 7294927
+From the given conditions, we want to calculate
+
+$$
+\sum_{i=0}^{3} \sum_{j=i}^{3}\left(10^{i}+10^{j}\right)^{2}
+$$
+
+By observing the formula, we notice that each term is an exponent of $10.10^{6}$ shows up 7 times, $10^{5}$ shows up 2 times, $10^{4}$ shows up 9 times, $10^{3}$ shows up 4 times, $10^{2}$ shows up 9 times, 10 shows 2 times, 1 shows up 7 times. Thus the answer is 7294927 .
+4. Determine the remainder when
+
+$$
+\sum_{i=0}^{2015}\left\lfloor\frac{2^{i}}{25}\right\rfloor
+$$
+
+is divided by 100 , where $\lfloor x\rfloor$ denotes the largest integer not greater than $x$.
+Proposed by: Alexander Katz
+Answer: 14
+Let $r_{i}$ denote the remainder when $2^{i}$ is divided by 25 . Note that because $2^{\phi(25)} \equiv 2^{20} \equiv 1(\bmod 25)$, $r$ is periodic with length 20 . In addition, we find that 20 is the order of $2 \bmod 25$. Since $2^{i}$ is never a multiple of 5 , all possible integers from 1 to 24 are represented by $r_{1}, r_{2}, \ldots, r_{20}$ with the exceptions of $5,10,15$, and 20 . Hence, $\sum_{i=1}^{20} r_{i}=\sum_{i=1}^{24} i-(5+10+15+20)=250$.
+
+We also have
+
+$$
+\begin{aligned}
+\sum_{i=0}^{2015}\left\lfloor\frac{2^{i}}{25}\right\rfloor & =\sum_{i=0}^{2015} \frac{2^{i}-r_{i}}{25} \\
+& =\sum_{i=0}^{2015} \frac{2^{i}}{25}-\sum_{i=0}^{2015} \frac{r_{i}}{25} \\
+& =\frac{2^{2016}-1}{25}-\sum_{i=0}^{1999} \frac{r_{i}}{25}-\sum_{i=0}^{15} \frac{r_{i}}{25} \\
+& =\frac{2^{2016}-1}{25}-100\left(\frac{250}{25}\right)-\sum_{i=0}^{15} \frac{r_{i}}{25} \\
+& \equiv \frac{2^{2016}-1}{25}-\sum_{i=0}^{15} \frac{r_{i}}{25}(\bmod 100)
+\end{aligned}
+$$
+
+We can calculate $\sum_{i=0}^{15} r_{i}=185$, so
+
+$$
+\sum_{i=0}^{2015}\left\lfloor\frac{2^{i}}{25}\right\rfloor \equiv \frac{2^{2016}-186}{25} \quad(\bmod 100)
+$$
+
+Now $2^{\phi(625)} \equiv 2^{500} \equiv 1(\bmod 625)$, so $2^{2016} \equiv 2^{16} \equiv 536(\bmod 625)$. Hence $2^{2016}-186 \equiv 350$ $(\bmod 625)$, and $2^{2016}-186 \equiv 2(\bmod 4)$. This implies that $2^{2016}-186 \equiv 350(\bmod 2500)$, and so $\frac{2^{2016}-186}{25} \equiv 14(\bmod 100)$.
+5. An infinite sequence of real numbers $a_{1}, a_{2}, \ldots$ satisfies the recurrence
+
+$$
+a_{n+3}=a_{n+2}-2 a_{n+1}+a_{n}
+$$
+
+for every positive integer $n$. Given that $a_{1}=a_{3}=1$ and $a_{98}=a_{99}$, compute $a_{1}+a_{2}+\cdots+a_{100}$. Proposed by: Evan Chen
+Answer: 3
+A quick telescope gives that $a_{1}+\cdots+a_{n}=2 a_{1}+a_{3}+a_{n-1}-a_{n-2}$ for all $n \geq 3$ :
+
+$$
+\begin{aligned}
+\sum_{k=1}^{n} a_{k} & =a_{1}+a_{2}+a_{3}+\sum_{k=1}^{n-3}\left(a_{k}-2 a_{k+1}+2 a_{k+2}\right) \\
+& =a_{1}+a_{2}+a_{3}+\sum_{k=1}^{n-3} a_{k}-2 \sum_{k=2}^{n-2} a_{k}+\sum_{k=3}^{n-1} a_{k} \\
+& =2 a_{1}+a_{3}-a_{n-2}+a_{n-1}
+\end{aligned}
+$$
+
+Putting $n=100$ gives the answer.
+One actual value of $a_{2}$ which yields the sequence is $a_{2}=\frac{742745601954}{597303450449}$.
+6. Call a positive integer $N \geq 2$ "special" if for every $k$ such that $2 \leq k \leq N, N$ can be expressed as a sum of $k$ positive integers that are relatively prime to $N$ (although not necessarily relatively prime to each other). How many special integers are there less than $100 ?$
+
+Proposed by: Casey Fu
+Answer: 50
+We claim that all odd numbers are special, and the only special even number is 2 . For any even $N>2$, the numbers relatively prime to $N$ must be odd. When we consider $k=3$, we see that $N$ can't be expressed as a sum of 3 odd numbers.
+
+Now suppose that $N$ is odd, and we look at the binary decomposition of $N$, so write $N=2^{a_{1}}+2^{a_{2}}+$ $\ldots+2^{a_{j}}$ as a sum of distinct powers of 2 . Note that all these numbers only have factors of 2 and are therefore relatively prime to $N$. We see that $j<\log _{2} N+1$.
+We claim that for any $k \geq j$, we can write $N$ as a sum of $k$ powers of 2 . Suppose that we have $N$ written as $N=2^{a_{1}}+2^{a_{2}}+\ldots+2^{a_{k}}$. Suppose we have at least one of these powers of 2 even, say $2^{a_{1}}$. We can then write $N=2^{a_{1}-1}+2^{a_{1}-1}+2^{a_{2}}+\ldots+2^{a_{k}}$, which is $k+1$ powers of 2 . The only way this process cannot be carried out is if we write $N$ as a sum of ones, which corresponds to $k=N$. Therefore, this gives us all $k>\log _{2} N$.
+Now we consider the case $k=2$. Let $2^{a}$ be the largest power of 2 such that $2^{a}
Guts
+
+1. [5] Let $x$ and $y$ be complex numbers such that $x+y=\sqrt{20}$ and $x^{2}+y^{2}=15$. Compute $|x-y|$.
+
+Proposed by: Evan Chen
+Answer: $\sqrt{\sqrt{10}}$
+We have $(x-y)^{2}+(x+y)^{2}=2\left(x^{2}+y^{2}\right)$, so $(x-y)^{2}=10$, hence $|x-y|=\sqrt{10}$.
+2. [5] Sherry is waiting for a train. Every minute, there is a $75 \%$ chance that a train will arrive. However, she is engrossed in her game of sudoku, so even if a train arrives she has a $75 \%$ chance of not noticing it (and hence missing the train). What is the probability that Sherry catches the train in the next five minutes?
+
+Proposed by:
+Answer: $1-\left(\frac{13}{16}\right)^{5}$
+During any given minute, the probability that Sherry doesn't catch the train is $\frac{1}{4}+\left(\frac{3}{4}\right)^{2}=\frac{13}{16}$. The desired probability is thus one minus the probability that she doesn't catch the train for the next five minutes: $1-\left(\frac{13}{16}\right)^{5}$.
+3. [5] Let $P R O B L E M Z$ be a regular octagon inscribed in a circle of unit radius. Diagonals $M R, O Z$ meet at $I$. Compute $L I$.
+Proposed by: Evan Chen
+Answer: $\sqrt{2}$
+If $W$ is the center of the circle then $I$ is the incenter of $\triangle R W Z$. Moreover, $P R I Z$ is a rhombus. It follows that $P I$ is twice the inradius of a $1-1-\sqrt{2}$ triangle, hence the answer of $2-\sqrt{2}$. So $L I=\sqrt{2}$.
+Alternatively, one can show (note, really) that the triangle OIL is isosceles.
+4. [5] Consider a three-person game involving the following three types of fair six-sided dice.
+
+- Dice of type $A$ have faces labelled $2,2,4,4,9,9$.
+- Dice of type $B$ have faces labelled $1,1,6,6,8,8$.
+- Dice of type $C$ have faces labelled $3,3,5,5,7,7$.
+
+All three players simultaneously choose a die (more than one person can choose the same type of die, and the players don't know one another's choices) and roll it. Then the score of a player $P$ is the number of players whose roll is less than $P$ 's roll (and hence is either 0,1 , or 2 ). Assuming all three players play optimally, what is the expected score of a particular player?
+Proposed by:
+Answer: $\frac{8}{9}$
+Short version: third player doesn't matter; against 1 opponent, by symmetry, you'd both play the same strategy. Type A beats B, B beats C, and C beats A all with probability $5 / 9$. It can be determined that choosing each die with probability $1 / 3$ is the best strategy. Then, whatever you pick, there is a $1 / 3$ of dominating, a $1 / 3$ chance of getting dominated, and a $1 / 3$ chance of picking the same die (which gives a $1 / 3 \cdot 2 / 3+1 / 3 \cdot 1 / 3=1 / 3$ chance of rolling a higher number). Fix your selection; then the expected payout is then $1 / 3 \cdot 5 / 9+1 / 3 \cdot 4 / 9+1 / 3 \cdot 1 / 3=1 / 3+1 / 9=4 / 9$. Against 2 players, your EV is just $E(p 1)+E(p 2)=2 E(p 1)=8 / 9$
+5. [6] Patrick and Anderson are having a snowball fight. Patrick throws a snowball at Anderson which is shaped like a sphere with a radius of 10 centimeters. Anderson catches the snowball and uses the snow from the snowball to construct snowballs with radii of 4 centimeters. Given that the total volume of the snowballs that Anderson constructs cannot exceed the volume of the snowball that Patrick threw, how many snowballs can Anderson construct?
+Proposed by:
+Answer: 15
+
+$$
+\left\lfloor\left(\frac{10}{4}\right)^{3}\right\rfloor=\left\lfloor\frac{125}{8}\right\rfloor=15 .
+$$
+
+6. [6] Consider a $2 \times n$ grid of points and a path consisting of $2 n-1$ straight line segments connecting all these $2 n$ points, starting from the bottom left corner and ending at the upper right corner. Such a path is called efficient if each point is only passed through once and no two line segments intersect. How many efficient paths are there when $n=2016$ ?
+Proposed by: Casey Fu
+Answer: $\binom{4030}{2015}$
+The general answer is $\binom{2(n-1)}{n-1}$ : Simply note that the points in each column must be taken in order, and anything satisfying this avoids intersections, so just choose the steps during which to be in the first column.
+7. [6] A contest has six problems worth seven points each. On any given problem, a contestant can score either 0,1 , or 7 points. How many possible total scores can a contestant achieve over all six problems?
+Proposed by: Evan Chen
+Answer: 28
+For $0 \leq k \leq 6$, to obtain a score that is $k(\bmod 6)$ exactly $k$ problems must get a score of 1 . The remaining $6-k$ problems can generate any multiple of 7 from 0 to $7(6-k)$, of which there are $7-k$. So the total number of possible scores is $\sum_{k=0}^{6}(7-k)=28$.
+8. [6] For each positive integer $n$ and non-negative integer $k$, define $W(n, k)$ recursively by
+
+$$
+W(n, k)= \begin{cases}n^{n} & k=0 \\ W(W(n, k-1), k-1) & k>0\end{cases}
+$$
+
+Find the last three digits in the decimal representation of $W(555,2)$.
+Proposed by:
+Answer: 875
+For any $n$, we have
+
+$$
+W(n, 1)=W(W(n, 0), 0)=\left(n^{n}\right)^{n^{n}}=n^{n^{n+1}}
+$$
+
+Thus,
+
+$$
+W(555,1)=555^{555^{556}}
+$$
+
+Let $N=W(555,1)$ for brevity, and note that $N \equiv 0(\bmod 125)$, and $N \equiv 3(\bmod 8)$. Then,
+
+$$
+W(555,2)=W(N, 1)=N^{N^{N+1}}
+$$
+
+is $0(\bmod 125)$ and $3(\bmod 8)$.
+From this we can conclude (by the Chinese Remainder Theorem) that the answer is 875 .
+9. [7] Victor has a drawer with two red socks, two green socks, two blue socks, two magenta socks, two lavender socks, two neon socks, two mauve socks, two wisteria socks, and 2000 copper socks, for a total of 2016 socks. He repeatedly draws two socks at a time from the drawer at random, and stops if the socks are of the same color. However, Victor is red-green colorblind, so he also stops if he sees a red and green sock.
+What is the probability that Victor stops with two socks of the same color? Assume Victor returns both socks to the drawer at each step.
+Proposed by: Evan Chen
+Answer: $\frac{1999008}{1999012}$
+There are $\binom{2000}{2}+8\binom{2}{2}=1999008$ ways to get socks which are matching colors, and four extra ways to get a red-green pair, hence the answer.
+10. [7] Let $A B C$ be a triangle with $A B=13, B C=14, C A=15$. Let $O$ be the circumcenter of $A B C$. Find the distance between the circumcenters of triangles $A O B$ and $A O C$.
+
+Proposed by: Evan Chen
+Answer: $\frac{91}{6}$
+Let $S, T$ be the intersections of the tangents to the circumcircle of $A B C$ at $A, C$ and at $A, B$ respectively. Note that $A S C O$ is cyclic with diameter $S O$, so the circumcenter of $A O C$ is the midpoint of $O S$, and similarly for the other side. So the length we want is $\frac{1}{2} S T$. The circumradius $R$ of $A B C$ can be computed by Heron's formula and $K=\frac{a b c}{4 R}$, giving $R=\frac{65}{8}$. A few applications of the Pythagorean theorem and similar triangles gives $A T=\frac{65}{6}, A S=\frac{39}{2}$, so the answer is $\frac{91}{6}$.
+11. [7] Define $\phi^{!}(n)$ as the product of all positive integers less than or equal to $n$ and relatively prime to $n$. Compute the remainder when
+
+$$
+\sum_{\substack{2 \leq n \leq 50 \\ \operatorname{gcd}(n, 50)=1}} \phi^{!}(n)
+$$
+
+is divided by 50 .
+Proposed by: Evan Chen
+Answer: 12
+First, $\phi^{!}(n)$ is even for all odd $n$, so it vanishes modulo 2 .
+To compute the remainder modulo 25 , we first evaluate $\phi^{!}(3)+\phi^{!}(7)+\phi^{!}(9) \equiv 2+5 \cdot 4+5 \cdot 3 \equiv 12$ $(\bmod 25)$. Now, for $n \geq 11$ the contribution modulo 25 vanishes as long as $5 \nmid n$.
+We conclude the answer is 12 .
+12. [7] Let $R$ be the rectangle in the Cartesian plane with vertices at $(0,0),(2,0),(2,1)$, and $(0,1)$. $R$ can be divided into two unit squares, as shown; the resulting figure has seven edges.
+
+
+Compute the number of ways to choose one or more of the seven edges such that the resulting figure is traceable without lifting a pencil. (Rotations and reflections are considered distinct.)
+Proposed by: Joy Zheng
+Answer: 61
+
+We have two cases, depending on whether we choose the middle edge. If so, then either all the remaining edges are either to the left of or to the right of this edge, or there are edges on both sides, or neither; in the first two cases there are 6 ways each, in the third there are $16+1=17$ ways, and in the last there is 1 way. Meanwhile, if we do not choose the middle edge, then we have to choose a beginning and endpoint, plus the case where we have a loop, for a total of $6 \cdot 5+1=31$ cases. This gives a total of $6+6+17+1+31=61$ possible cases.
+13. [9] A right triangle has side lengths $a, b$, and $\sqrt{2016}$ in some order, where $a$ and $b$ are positive integers. Determine the smallest possible perimeter of the triangle.
+Proposed by: Evan Chen
+Answer: $48+\sqrt{2016}$
+There are no integer solutions to $a^{2}+b^{2}=2016$ due to the presence of the prime 7 on the right-hand side (by Fermat's Christmas Theorem). Assuming $a1$.
+
+Find the smallest positive integer $n$ for which there exists a positive integer $a$ such that $a \uparrow \uparrow 6 \not \equiv a \uparrow \uparrow 7$ $\bmod n$.
+Proposed by: Sammy Luo
+Answer: 283
+We see that the smallest such $n$ must be a prime power, because if two numbers are distinct mod $n$, they must be distinct mod at least one of the prime powers that divide $n$. For $k \geq 2$, if $a \uparrow \uparrow k$ and $a \uparrow \uparrow(k+1)$ are distinct $\bmod p^{r}$, then $a \uparrow \uparrow(k-1)$ and $a \uparrow \uparrow k$ must be distinct $\bmod \phi\left(p^{r}\right)$. In fact they need to be distinct $\bmod \frac{\phi\left(p^{r}\right)}{2}$ if $p=2$ and $r \geq 3$ because then there are no primitive roots mod $p^{r}$.
+Using this, for $1 \leq k \leq 5$ we find the smallest prime $p$ such that there exists $a$ such that $a \uparrow \uparrow k$ and $a \uparrow \uparrow(k+1)$ are distinct $\bmod p$. The list is: $3,5,11,23,47$. We can easily check that the next largest prime for $k=5$ is 139 , and also any prime power other than 121 for which $a \uparrow \uparrow 5$ and $a \uparrow \uparrow 6$ are distinct is also larger than 139.
+Now if $a \uparrow \uparrow 6$ and $a \uparrow \uparrow 7$ are distinct $\bmod p$, then $p-1$ must be a multiple of 47 or something that is either 121 or at least 139. It is easy to see that 283 is the smallest prime that satisfies this.
+If $n$ is a prime power less than 283 such that $a \uparrow \uparrow 6$ and $a \uparrow \uparrow 7$ are distinct $\bmod n$, then the prime can be at most 13 and clearly this doesn't work because $\phi\left(p^{r}\right)=p^{r-1}(p-1)$.
+To show that 283 works, choose $a$ so that $a$ is a primitive root $\bmod 283,47,23,11,5$ and 3 . This is possible by the Chinese Remainder theorem, and it is easy to see that this $a$ works by induction.
+27. [14] Find the smallest possible area of an ellipse passing through $(2,0),(0,3),(0,7)$, and $(6,0)$.
+
+Proposed by: Calvin Deng
+Answer: $\frac{56 \pi \sqrt{3}}{9}$
+Let $\Gamma$ be an ellipse passing through $A=(2,0), B=(0,3), C=(0,7), D=(6,0)$, and let $P=(0,0)$ be the intersection of $A D$ and $B C$. $\frac{\text { Area of } \Gamma}{\text { Area of } A B C D}$ is unchanged under an affine transformation, so we just have to minimize this quantity over situations where $\Gamma$ is a circle and $\frac{P A}{P D}=\frac{1}{3}$ and $\frac{P B}{B C}=\frac{3}{7}$. In fact, we may assume that $P A=\sqrt{7}, P B=3, P C=7, P D=3 \sqrt{7}$. If $\angle P=\theta$, then we can compute lengths to get
+
+$$
+r=\frac{\text { Area of } \Gamma}{\text { Area of } A B C D}=\pi \frac{32-20 \sqrt{7} \cos \theta+21 \cos ^{2} \theta}{9 \sqrt{7} \cdot \sin ^{3} \theta}
+$$
+
+Let $x=\cos \theta$. Then if we treat $r$ as a function of $x$,
+
+$$
+0=\frac{r^{\prime}}{r}=\frac{3 x}{1-x^{2}}+\frac{42 x-20 \sqrt{7}}{32-20 x \sqrt{7}+21 x^{2}}
+$$
+
+which means that $21 x^{3}-40 x \sqrt{7}+138 x-20 \sqrt{7}=0$. Letting $y=x \sqrt{7}$ gives
+
+$$
+0=3 y^{3}-40 y^{2}+138 y-140=(y-2)\left(3 y^{2}-34 y+70\right)
+$$
+
+The other quadratic has roots that are greater than $\sqrt{7}$, which means that the minimum ratio is attained when $\cos \theta=x=\frac{y}{\sqrt{7}}=\frac{2}{\sqrt{7}}$. Plugging that back in gives that the optimum $\frac{\text { Area of } \Gamma}{\text { Area of } A B C D}$ is
+$\frac{28 \pi \sqrt{3}}{81}$, so putting this back into the original configuration gives Area of $\Gamma \geq \frac{56 \pi \sqrt{3}}{9}$. If you want to check on Geogebra, this minimum occurs when the center of $\Gamma$ is $\left(\frac{8}{3}, \frac{7}{3}\right)$.
+28. [14] Among citizens of Cambridge there exist 8 different types of blood antigens. In a crowded lecture hall are 256 students, each of whom has a blood type corresponding to a distinct subset of the antigens; the remaining of the antigens are foreign to them.
+Quito the Mosquito flies around the lecture hall, picks a subset of the students uniformly at random, and bites the chosen students in a random order. After biting a student, Quito stores a bit of any antigens that student had. A student bitten while Quito had $k$ blood antigen foreign to him/her will suffer for $k$ hours. What is the expected total suffering of all 256 students, in hours?
+Proposed by: Sammy Luo
+Answer: $\frac{2^{135}-2^{128}+1}{2^{119} \cdot 129}$
+Let $n=8$.
+First, consider any given student $S$ and an antigen $a$ foreign to him/her. Assuming $S$ has been bitten, we claim the probability $S$ will suffer due to $a$ is
+
+$$
+1-\frac{2^{2^{n-1}+1}-1}{2^{2^{n-1}}\left(2^{n-1}+1\right)}
+$$
+
+Indeed, let $N=2^{n-1}$ denote the number of students with $a$. So considering just these students and summing over the number bitten, we obtain a probability
+
+$$
+\frac{1}{2^{N}} \sum_{t=0}^{N}\binom{N}{t}\binom{N}{t} \frac{t}{t+1}=\frac{1}{2^{N}} \frac{2^{N} N-2^{N}+1}{N+1}
+$$
+
+We now use linearity over all pairs $(S, a)$ of students $S$ and antigens $a$ foreign to them. Noting that each student is bitten with probability $\frac{1}{2}$, and retaining the notation $N=2^{n-1}$, we get
+
+$$
+\frac{1}{2} \sum_{k=0}^{n}\left[\binom{n}{k} \cdot k\left(\frac{2^{N} N-2^{N}+1}{2^{N}(N+1)}\right)\right]=\frac{n N\left(2^{N} N-2^{N}+1\right)}{2^{N+1}(N+1)} .
+$$
+
+Finally, setting $n=8=2^{3}$ and $N=2^{n-1}=2^{7}=128$, we get the claimed answer.
+29. [16] Katherine has a piece of string that is 2016 millimeters long. She cuts the string at a location chosen uniformly at random, and takes the left half. She continues this process until the remaining string is less than one millimeter long. What is the expected number of cuts that she makes?
+Proposed by:
+Answer: $1+\log (2016)$
+Letting $f(x)$ be the expected number of cuts if the initial length of the string is $x$, we get the integral equation $f(x)=1+\frac{1}{x} \int_{1}^{x} f(y) d y$. Letting $g(x)=\int_{1}^{x} f(y) d y$, we get $d g / d x=1+\frac{1}{x} g(x)$. Using integrating factors, we see that this has as its solution $g(x)=x \log (x)$, and thus $f(x)=1+\log (x)$.
+30. [16] Determine the number of triples $0 \leq k, m, n \leq 100$ of integers such that
+
+$$
+2^{m} n-2^{n} m=2^{k}
+$$
+
+Proposed by: Casey Fu
+Answer: 22
+First consider when $n \geq m$, so let $n=m+d$ where $d \geq 0$. Then we have $2^{m}\left(m+d-2^{d} m\right)=$ $2^{m}\left(m\left(1-2^{d}\right)+d\right)$, which is non-positive unless $m=0$. So our first set of solutions is $m=0, n=2^{j}$.
+
+Now, we can assume that $m>n$, so let $m=n+d$ where $d>0$. Rewrite $2^{m} n-2^{n} m=2^{n+d} n-$ $2^{n}(n+d)=2^{n}\left(\left(2^{d}-1\right) n-d\right)$. In order for this to be a power of $2,\left(2^{d}-1\right) n-d$ must be a power of 2. This implies that for some $j, 2^{j} \equiv-d\left(\bmod 2^{d}-1\right)$. But notice that the powers of $2\left(\bmod 2^{d}-1\right)$ are $1,2,4, \ldots, 2^{d-1}\left(2^{d} \equiv 1\right.$ so the cycle repeats $)$.
+In order for the residues to match, we need $2^{j}+d=c\left(2^{d}-1\right)$, where $0 \leq j \leq d-1$ and $c \geq 1$. In order for this to be true, we must have $2^{d-1}+d \geq 2^{d}-1 \Longleftrightarrow d+1 \geq 2^{d-1}$. This inequality is only true for $d=1,2,3$. We plug each of these into the original expression $\left(2^{d}-1\right) n-d$.
+For $d=1$ : $n-1$ is a power of 2 . This yields the set of solutions $\left(2^{j}+2,2^{j}+1\right)$ for $j \geq 0$.
+For $d=2: 3 n-2$ is a power of 2 . Note that powers of 2 are $-2(\bmod 3)$ if and only if it is an even power, so $n=\frac{2^{2 j}+2}{3}$. This yields the solution set $\left(\frac{2^{2 j}+8}{3}, \frac{2^{2 j}+2}{3}\right), j \geq 0$.
+For $d=3: 7 n-3$ is a power of 2 . Powers of 2 have a period of 3 when taken $(\bmod 7)$, so inspection tells us $7 n-3=2^{3 j+2}$, yielding the solution set $\left(\frac{2^{3 j+2}+24}{7}, \frac{2^{3 j+2}+3}{7}\right), j \geq 0$.
+Therefore, all the solutions are of the form
+
+$$
+\begin{gathered}
+(m, n)=\left(0,2^{j}\right),\left(2^{j}+2,2^{j}+1\right) \\
+\left(\frac{2^{2 j}+8}{3}, \frac{2^{2 j}+2}{3}\right),\left(\frac{2^{3 j+2}+24}{7}, \frac{2^{3 j+2}+3}{7}\right)
+\end{gathered}
+$$
+
+for $j \geq 0$.
+Restricting this family to $m, n \leq 100$ gives $7+7+5+3=22$.
+31. [16] For a positive integer $n$, denote by $\tau(n)$ the number of positive integer divisors of $n$, and denote by $\phi(n)$ the number of positive integers that are less than or equal to $n$ and relatively prime to $n$. Call a positive integer $n$ good if $\varphi(n)+4 \tau(n)=n$. For example, the number 44 is good because $\varphi(44)+4 \tau(44)=44$.
+Find the sum of all good positive integers $n$.
+Proposed by: Lawrence Sun
+Answer: 172
+We claim that $44,56,72$ are the only good numbers. It is easy to check that these numbers work.
+Now we prove none others work. First, remark that as $n=1,2$ fail so we have $\varphi(n)$ is even, thus $n$ is even. This gives us $\varphi(n) \leq n / 2$. Now remark that $\tau(n)<2 \sqrt{n}$, so it follows we need $n / 2+8 \sqrt{n}>$ $n \Longrightarrow n \leq 256$. This gives us a preliminary bound. Note that in addition we have $8 \tau(n)>n$.
+Now, it is easy to see that powers of 2 fail. Thus let $n=2^{a} p_{1}^{b}$ where $p_{1}$ is an odd prime. From $8 \tau(n)>n$ we get $8(a+1)(b+1)>2^{a} p_{1}^{b} \geq 2^{a} 3^{b}$ from which we get that $(a, b)$ is one of
+
+$$
+(1,1),(1,2),(1,3),(2,1),(2,2),(3,1),(3,2),(4,1)
+$$
+
+Remark that $p_{1} \leq \sqrt[b]{\frac{8(a+1)(b+1)}{2^{a}}}$. From this we can perform some casework:
+
+- If $a=1, b=1$ then $p_{1}-1+16=2 p_{1}$ but then $p=15$, absurd.
+- If $a=1, b=2$ then we have $p_{1} \leq 5$ which is obviously impossible.
+- If $a=1, b=3$ then $p_{1} \leq 4$ which is impossible.
+- If $a=2, b=1$ then $p_{1} \leq 12$ and it is easy to check that $p_{1}=11$ and thus $n=44$ is the only solution.
+- If $a=2, b=2$ then $p_{1} \leq 4$ which is impossible.
+- If $a=3, b=1$ then $p_{1} \leq 8$ and only $p_{1}=7$ or $n=56$ works.
+- If $a=3, b=2$ then $p_{1} \leq 3$ and $p_{1}=3, n=72$ works.
+- If $a=4, b=1$ then $p_{1} \leq 1$ which is absurd.
+
+Now suppose $n$ is the product of 3 distinct primes, so $n=2^{a} p_{1}^{b} p_{2}^{c}$ so we have $8(a+1)(b+1)(c+1)>$ $2^{a} 3^{b} 5^{c}$ then we must have $(a, b, c)$ equal to one of
+
+$$
+(1,1,1),(1,2,1),(2,1,1),(3,1,1)
+$$
+
+Again, we can do some casework:
+
+- If $a=b=c=1$ then $8 \tau(n)=64>2 p_{1} p_{2}$ but then $p_{1}=3, p_{2}=5$ or $p_{1}=3, p_{2}=7$ is forced neither of which work.
+- If $a=1, b=2, c=1$ then $8 \tau(n)=96>2 p_{1}^{2} p_{2}$ but then $p_{1}=3, p_{2}=5$ is forced which does not work.
+- If $a=2, b=1, c=1$ then $8 \tau(n)=96>4 p_{1} p_{2}$ forces $p_{1}=3, p_{2}=5$ or $p_{1}=3, p_{2}=7$ neither of which work.
+- If $a=3, b=1, c=1$ then $8 \tau(n)=108>8 p_{1} p_{2}$ which has no solutions for $p_{1}, p_{2}$.
+
+Finally, take the case where $n$ is the product of at least 4 distinct primes. But then $n \geq 2 \cdot 3 \cdot 5 \cdot 7=210$ and as $2 \cdot 3 \cdot 5 \cdot 11>256$, it suffices to check only the case of 210 . But 210 clearly fails, so it follows that $44,56,72$ are the only good numbers so we are done.
+32. [16] How many equilateral hexagons of side length $\sqrt{13}$ have one vertex at $(0,0)$ and the other five vertices at lattice points?
+(A lattice point is a point whose Cartesian coordinates are both integers. A hexagon may be concave but not self-intersecting.)
+Proposed by: Casey Fu
+Answer: 216
+We perform casework on the point three vertices away from $(0,0)$. By inspection, that point can be $( \pm 8, \pm 3),( \pm 7, \pm 2),( \pm 4, \pm 3),( \pm 3, \pm 2),( \pm 2, \pm 1)$ or their reflections across the line $y=x$. The cases are as follows:
+If the third vertex is at any of $( \pm 8, \pm 3)$ or $( \pm 3, \pm 8)$, then there are 7 possible hexagons. There are 8 points of this form, contributing 56 hexagons.
+If the third vertex is at any of $( \pm 7, \pm 2)$ or $( \pm 2, \pm 7)$, there are 6 possible hexagons, contributing 48 hexagons.
+If the third vertex is at any of $( \pm 4, \pm 3)$ or $( \pm 3, \pm 4)$, there are again 6 possible hexagons, contributing 48 more hexagons.
+If the third vertex is at any of $( \pm 3, \pm 2)$ or $( \pm 2, \pm 3)$, then there are again 6 possible hexagons, contributing 48 more hexagons.
+Finally, if the third vertex is at any of $( \pm 2, \pm 1)$, then there are 2 possible hexagons only, contributing 16 hexagons.
+Adding up, we get our answer of 216 .
+33. [20] (Lucas Numbers) The Lucas numbers are defined by $L_{0}=2, L_{1}=1$, and $L_{n+2}=L_{n+1}+L_{n}$ for every $n \geq 0$. There are $N$ integers $1 \leq n \leq 2016$ such that $L_{n}$ contains the digit 1 . Estimate $N$.
+An estimate of $E$ earns $\lfloor 20-2|N-E|\rfloor$ or 0 points, whichever is greater.
+Proposed by: Evan Chen
+Answer: 1984
+lucas_ones $n=$ length . filter (elem '1') \$ take ( $\mathrm{n}+1$ ) lucas_strs
+where
+lucas $=2$ : 1 : zipWith (+) lucas (tail lucas)
+lucas_strs = map show lucas
+main $=$ putStrLn . show \$ lucas_ones 2016
+34. [20] (Caos) A cao [sic] has 6 legs, 3 on each side. A walking pattern for the cao is defined as an ordered sequence of raising and lowering each of the legs exactly once (altogether 12 actions), starting and ending with all legs on the ground. The pattern is safe if at any point, he has at least 3 legs on the ground and not all three legs are on the same side. Estimate $N$, the number of safe patterns.
+An estimate of $E>0$ earns $\left\lfloor 20 \min (N / E, E / N)^{4}\right\rfloor$ points.
+Proposed by:
+Answer: 1416528
+
+```
+# 1 = on ground, 0 = raised, 2 = back on ground
+cache = {}
+def pangzi(legs):
+ if legs == (2,2,2,2,2,2): return 1
+ elif legs.count(0) > 3: return 0
+ elif legs[0] + legs[1] + legs[2] == 0: return 0
+ elif legs[3] + legs[4] + legs[5] == 0: return 0
+ elif cache.has_key(legs): return cache[legs]
+ cache[legs] = 0
+ for i in xrange(6): # raise a leg
+ if legs[i] == 1:
+ new = list(legs)
+ new[i] = 0
+ cache[legs] += pangzi(tuple(new))
+ elif legs[i] == 0: # lower a leg
+ new = list(legs)
+ new[i] = 2
+ cache[legs] += pangzi(tuple(new))
+ return cache[legs]
+print pangzi((1,1,1,1,1,1))
+```
+
+35. [20] (Maximal Determinant) In a $17 \times 17$ matrix $M$, all entries are $\pm 1$. The maximum possible value of $|\operatorname{det} M|$ is $N$. Estimate $N$.
+An estimate of $E>0$ earns $\left\lfloor 20 \min (N / E, E / N)^{2}\right\rfloor$ points.
+Proposed by: Evan Chen
+Answer: $327680 \cdot 2^{16}$
+This is Hadamard's maximal determinant problem. There's an upper bound of $n^{\frac{1}{2} n}$ which empirically seems to give reasonably good estimates, but in fact this is open for general $n$.
+36. [20] (Self-Isogonal Cubics) Let $A B C$ be a triangle with $A B=2, A C=3, B C=4$. The isogonal conjugate of a point $P$, denoted $P^{*}$, is the point obtained by intersecting the reflection of lines $P A$, $P B, P C$ across the angle bisectors of $\angle A, \angle B$, and $\angle C$, respectively.
+Given a point $Q$, let $\mathfrak{K}(Q)$ denote the unique cubic plane curve which passes through all points $P$ such that line $P P^{*}$ contains $Q$. Consider:
+(a) the M'Cay cubic $\mathfrak{K}(O)$, where $O$ is the circumcenter of $\triangle A B C$,
+(b) the Thomson cubic $\mathfrak{K}(G)$, where $G$ is the centroid of $\triangle A B C$,
+(c) the Napoleon-Feurerbach cubic $\mathfrak{K}(N)$, where $N$ is the nine-point center of $\triangle A B C$,
+(d) the Darboux cubic $\mathfrak{K}(L)$, where $L$ is the de Longchamps point (the reflection of the orthocenter across point $O$ ),
+(e) the Neuberg cubic $\mathfrak{K}\left(X_{30}\right)$, where $X_{30}$ is the point at infinity along line $O G$,
+(f) the nine-point circle of $\triangle A B C$,
+(g) the incircle of $\triangle A B C$, and
+(h) the circumcircle of $\triangle A B C$.
+
+Estimate $N$, the number of points lying on at least two of these eight curves. An estimate of $E$ earns $\left\lfloor 20 \cdot 2^{-|N-E| / 6}\right\rfloor$ points.
+
+## Proposed by: Evan Chen
+
+Answer: 49
+The first main insight is that all the cubics pass through the points $A, B, C, H$ (orthocenter), $O$, and the incenter and three excenters. Since two cubics intersect in at most nine points, this is all the intersections of a cubic with a cubic.
+On the other hand, it is easy to see that among intersections of circles with circles, there are exactly 3 points; the incircle is tangent to the nine-point circle at the Feurerbach point while being contained completely in the circumcircle; on the other hand for this obtuse triangle the nine-point circle and the circumcircle intersect exactly twice.
+All computations up until now are exact, so it remains to estimate:
+
+- Intersection of the circumcircle with cubics. Each cubic intersects the circumcircle at an even number of points, and moreover we already know that $A, B, C$ are among these, so the number of additional intersections contributed is either 1 or 3 ; it is the former only for the Neuberg cubic which has a "loop". Hence the actual answer in this case is $1+3+3+3+3=13$ (but an estimate of $3 \cdot 5=15$ is very reasonable).
+- Intersection of the incircle with cubics. Since $\angle A$ is large the incircle is small, but on the other hand we know $I$ lies on each cubic. Hence it's very likely that each cubic intersects the incircle twice (once "coming in" and once "coming out"). This is the case, giving $2 \cdot 5=10$ new points.
+- Intersection of the nine-point with cubics. We guess this is close to the 10 points of the incircle, as we know the nine-point circle and the incircle are tangent to each other. In fact, the exact count is 14 points; just two additional branches appear.
+
+In total, $N=9+3+13+10+14=49$.
+
+
diff --git a/HarvardMIT/md/en-192-2016-feb-team-solutions.md b/HarvardMIT/md/en-192-2016-feb-team-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..3af19f808660ebd6207df2c96344fa3cc56e4520
--- /dev/null
+++ b/HarvardMIT/md/en-192-2016-feb-team-solutions.md
@@ -0,0 +1,301 @@
+## HMMT February 2016
February 20, 2016
Team
+
+1. [25] Let $a$ and $b$ be integers (not necessarily positive). Prove that $a^{3}+5 b^{3} \neq 2016$.
+
+Proposed by: Evan Chen
+Since cubes are 0 or $\pm 1$ modulo 9 , by inspection we see that we must have $a^{3} \equiv b^{3} \equiv 0(\bmod 3)$ for this to be possible. Thus $a, b$ are divisible by 3 . But then we get $3^{3} \mid 2016$, which is a contradiction.
+One can also solve the problem in the same manner by taking modulo 7 exist, since all cubes are 0 or $\pm 1$ modulo 7 . The proof can be copied literally, noting that $7 \mid 2016$ but $7^{3} \nmid 2016$.
+2. [25] For positive integers $n$, let $c_{n}$ be the smallest positive integer for which $n^{c_{n}}-1$ is divisible by 210, if such a positive integer exists, and $c_{n}=0$ otherwise. What is $c_{1}+c_{2}+\cdots+c_{210}$ ?
+Proposed by: Joy Zheng
+Answer: 329
+In order for $c_{n} \neq 0$, we must have $\operatorname{gcd}(n, 210)=1$, so we need only consider such $n$. The number $n^{c_{n}}-1$ is divisible by 210 iff it is divisible by each of $2,3,5$, and 7 , and we can consider the order of $n$ modulo each modulus separately; $c_{n}$ will simply be the LCM of these orders. We can ignore the modulus 2 because order is always 1 . For the other moduli, the sets of orders are
+
+$$
+\begin{array}{rr}
+a \in\{1,2\} & \bmod 3 \\
+b \in\{1,2,4,4\} & \bmod 5 \\
+c \in\{1,2,3,3,6,6\} & \bmod 7
+\end{array}
+$$
+
+By the Chinese Remainder Theorem, each triplet of choices from these three multisets occurs for exactly one $n$ in the range $\{1,2, \ldots, 210\}$, so the answer we seek is the sum of $\operatorname{lcm}(a, b, c)$ over $a, b, c$ in the Cartesian product of these multisets. For $a=1$ this table of LCMs is as follows:
+
+| | 1 | 2 | 3 | 3 | 6 | 6 |
+| :---: | :---: | :---: | :---: | :---: | :---: | :---: |
+| 1 | 1 | 2 | 3 | 3 | 6 | 6 |
+| 2 | 2 | 2 | 6 | 6 | 6 | 6 |
+| 4 | 4 | 4 | 12 | 12 | 12 | 12 |
+| 4 | 4 | 4 | 12 | 12 | 12 | 12 |
+
+which has a sum of $21+56+28+56=161$. The table for $a=2$ is identical except for the top row, where $1,3,3$ are replaced by $2,6,6$, and thus has a total sum of 7 more, or 168 . So our answer is $161+168=\mathbf{3 2 9}$.
+This can also be computed by counting how many times each LCM occurs:
+
+- 12 appears 16 times when $b=4$ and $c \in\{3,6\}$, for a contribution of $12 \times 16=192$;
+- 6 appears 14 times, 8 times when $c=6$ and $b \leq 2$ and 6 times when $c=3$ and $(a, b) \in$ $\{(1,2),(2,1),(2,2)\}$, for a contribution of $6 \times 14=84$;
+- 4 appears 8 times when $b=4$ and $a, c \in\{1,2\}$, for a contribution of $4 \times 8=32$;
+- 3 appears 2 times when $c=3$ and $a=b=1$, for a contribution of $3 \times 2=6$;
+- 2 appears 7 times when $a, b, c \in\{1,2\}$ and $(a, b, c) \neq(1,1,1)$, for a contribution of $2 \times 7=14$;
+- 1 appears 1 time when $a=b=c=1$, for a contribution of $1 \times 1=1$.
+
+The result is again $192+84+32+6+14+1=329$.
+3. [30] Let $A B C$ be an acute triangle with incenter $I$ and circumcenter $O$. Assume that $\angle O I A=90^{\circ}$. Given that $A I=97$ and $B C=144$, compute the area of $\triangle A B C$.
+
+Proposed by: Evan Chen
+Answer: 14040
+We present five different solutions and outline a sixth and seventh one. In what follows, let $a=B C$, $b=C A, c=A B$ as usual, and denote by $r$ and $R$ the inradius and circumradius. Let $s=\frac{1}{2}(a+b+c)$. In the first five solutions we will only prove that
+
+$$
+\angle A I O=90^{\circ} \Longrightarrow b+c=2 a
+$$
+
+Let us see how this solves the problem. This lemma implies that $s=216$. If we let $E$ be the foot of $I$ on $A B$, then $A E=s-B C=72$, consequently the inradius is $r=\sqrt{97^{2}-72^{2}}=65$. Finally, the area is $s r=216 \cdot 65=14040$.
+
+First Solution. Since $O I \perp D A, A I=D I$. Now, it is a well-known fact that $D I=D B=D C$ (this is occasionally called "Fact 5"). Then by Ptolemy's Theorem,
+
+$$
+D B \cdot A C+D C \cdot A B=D A \cdot B C \Longrightarrow A C+A B=2 B C
+$$
+
+Second Solution. As before note that $I$ is the midpoint of $A D$. Let $M$ and $N$ be the midpoints of $A B$ and $A C$, and let the reflection of $M$ across $B I$ be $P$; thus $B M=B P$. Also, $M I=P I$, but we know $M I=N I$ as $I$ lies on the circumcircle of triangle $A M N$. Consequently, we get $P I=N I$; moreover by angle chasing we have
+
+$$
+\angle I N C=\angle A M I=180^{\circ}-\angle B P I=\angle I P C
+$$
+
+Thus triangles $I N C$ and $P I C$ are congruent ( $C I$ is a bisector) so we deduce $P C=N C$. Thus,
+
+$$
+B C=B P+P C=B M+C N=\frac{1}{2}(A B+A C)
+$$
+
+Third Solution. We appeal to Euler's Theorem, which states that $I O^{2}=R(R-2 r)$.
+Thus by the Pythagorean Theorem on $\triangle A I O$ (or by Power of a Point) we may write
+
+$$
+(s-a)^{2}+r^{2}=A I^{2}=R^{2}-I O^{2}=2 R r=\frac{a b c}{2 s}
+$$
+
+with the same notations as before. Thus, we derive that
+
+$$
+\begin{aligned}
+a b c & =2 s\left((s-a)^{2}+r^{2}\right) \\
+& =2(s-a)(s(s-a)+(s-b)(s-c)) \\
+& =\frac{1}{2}(s-a)\left((b+c)^{2}-a^{2}+a^{2}-(b-c)^{2}\right) \\
+& =2 b c(s-a)
+\end{aligned}
+$$
+
+From this we deduce that $2 a=b+c$, and we can proceed as in the previous solution.
+Fourth Solution. From Fact 5 again $(D B=D I=D C)$, drop perpendicular from $I$ to $A B$ at $E$; call $M$ the midpoint of $B C$. Then, by $A A S$ congruency on $A I E$ and $C D M$, we immediately get that $C M=A E$. As $A E=\frac{1}{2}(A B+A C-B C)$, this gives the desired conclusion.
+
+Fifth Solution. This solution avoids angle-chasing and using the fact that $B I$ and $C I$ are anglebisectors. Recall the perpendicularity lemma, where
+
+$$
+W X \perp Y Z \Longleftrightarrow W Y^{2}-W Z^{2}=X Y^{2}-X Z^{2}
+$$
+
+Let $B^{\prime}$ be on the extension of ray $C A$ such that $A B^{\prime}=A B$. Of course, as in the proof of the angle bisector theorem, $B B^{\prime} \| A I$, meaning that $B B^{\prime} \perp I O$. Let $I^{\prime}$ be the reflection of $I$ across $A$; of course, $I^{\prime}$ is then the incenter of triangle $A B^{\prime} C^{\prime}$. Now, we have $B^{\prime} I^{2}-B I^{2}=B^{\prime} O^{2}-B O^{2}$ by the perpendicularity and by power of a point $B^{\prime} O^{2}-B O^{2}=B^{\prime} A \cdot B^{\prime} C$. Moreover $B I^{2}+B^{\prime} I^{2}=B I^{2}+B I^{\prime 2}=2 B A^{2}+2 A I^{2}$ by the median formula. Subtracting, we get $B I^{2}=A I^{2}+\frac{1}{2}(A B)(A B-A C)$. We have a similar expression for $C I$, and subtracting the two results in $B I^{2}-C I^{2}=\frac{1}{2}\left(A B^{2}-A C^{2}\right)$. Finally,
+
+$$
+B I^{2}-C I^{2}=\frac{1}{4}\left[(B C+A B-A C)^{2}-(B C-A B+A C)^{2}\right]
+$$
+
+from which again, the result $2 B C=A B+A C$ follows.
+Sixth Solution, outline. Use complex numbers, setting $I=a b+b c+c a, A=-a^{2}$, etc. on the unit circle (scale the picture to fit in a unit circle; we calculate scaling factor later). Set $a=1$, and let $u=b+c$ and $v=b c$. Write every condition in terms of $u$ and $v$, and the area in terms of $u$ and $v$ too. There should be two equations relating $u$ and $v: 2 u+v+1=0$ and $u^{2}=\frac{130}{97}^{2} v$ from the right angle and the 144 to 97 ratio, respectively. The square area can be computed in terms of $u$ and $v$, because the area itself is antisymmetric so squaring it suffices. Use the first condition to homogenize (not coincidentally the factor $\left(1-b^{2}\right)\left(1-c^{2}\right)=(1+b c)^{2}-(b+c)^{2}=(1+v)^{2}-u^{2}$ from the area homogenizes perfectly... because $A B \cdot A C=A I \cdot A I_{A}$, where $I_{A}$ is the $A$-excenter, and of course the way the problem is set up $A I_{A}=3 A I$. .), and then we find the area of the scaled down version. To find the scaling factor simply determine $|b-c|$ by squaring it, writing in terms again of $u$ and $v$, and comparing this to the value of 144.
+
+Seventh Solution, outline. Trigonometric solutions are also possible. One can you write everything in terms of the angles and solve the equations; for instance, the $\angle A I O=90^{\circ}$ condition can be rewritten as $\frac{1}{2} \cos \frac{B-C}{2}=2 \sin \frac{B}{2} \sin \frac{C}{2}$ and the 97 to 144 ratio condition can be rewritten as $\frac{2 \sin \frac{B}{2} 2 \sin \frac{C}{2}}{\sin A}=\frac{97}{144}$. The first equation implies $\sin \frac{A}{2}=2 \sin \frac{B}{2} \sin \frac{C}{2}$, which we can plug into the second equation to get $\cos \frac{A}{2}$.
+4. [30] Let $n>1$ be an odd integer. On an $n \times n$ chessboard the center square and four corners are deleted. We wish to group the remaining $n^{2}-5$ squares into $\frac{1}{2}\left(n^{2}-5\right)$ pairs, such that the two squares in each pair intersect at exactly one point (i.e. they are diagonally adjacent, sharing a single corner).
+For which odd integers $n>1$ is this possible?
+Proposed by: Evan Chen
+Answer: 3,5
+Constructions for $n=3$ and $n=5$ are easy. For $n>5$, color the odd rows black and the even rows white. If the squares can be paired in the way desired, each pair we choose must have one black cell and one white cell, so the numbers of black cells and white cells are the same. The number of black cells is $\frac{n+1}{2} n-4$ or $\frac{n+1}{2} n-5$ depending on whether the removed center cell is in an odd row. The number of white cells is $\frac{n-1}{2} n$ or $\frac{n-1}{2} n-1$. But
+
+$$
+\left(\frac{n+1}{2} n-5\right)-\frac{n-1}{2} n=n-5
+$$
+
+so for $n>5$ this pairing is impossible. Thus the answer is $n=3$ and $n=5$.
+5. [35] Find all prime numbers $p$ such that $y^{2}=x^{3}+4 x$ has exactly $p$ solutions in integers modulo $p$.
+
+In other words, determine all prime numbers $p$ with the following property: there exist exactly $p$ ordered pairs of integers $(x, y)$ such that $x, y \in\{0,1, \ldots, p-1\}$ and
+
+$$
+p \text { divides } y^{2}-x^{3}-4 x
+$$
+
+Proposed by: Evan Chen
+Answer: $p=2$ and $p \equiv 3(\bmod 4)$
+Clearly $p=2$ works with solutions $(0,0)$ and $(1,1)$ and not $(0,1)$ or $(1,0)$.
+If $p \equiv 3(\bmod 4)$ then -1 is not a quadratic residue, so for $x^{3}+4 x \neq 0$, exactly one of $x^{3}+4 x$ and $-x^{3}-4 x$ is a square and gives two solutions (for positive and negative $y$ ), so there's exactly two solutions for each such pair $\{x,-x\}$. If $x$ is such that $x^{3}+4 x=0$, there's exactly one solution.
+If $p \equiv 1(\bmod 4)$, let $i$ be a square root of $-1(\bmod p)$. The right hand side factors as $x(x+2 i)(x-2 i)$. For $x=0,2 i,-2 i$ this is zero, there is one choice of $y$, namely zero. Otherwise, the right hand side is nonzero. For any fixed $x$, there are either 0 or 2 choices for $y$. Replacing $x$ by $-x$ negates the right hand side, again producing two choices for $y$ since -1 is a quadratic residue. So the total number of solutions $(x, y)$ is $3(\bmod 4)$, and thus there cannot be exactly $p$ solutions.
+Remark: This is a conductor 36 elliptic curve with complex multiplication, and the exact formula for the number of solutions is given in http://www.mathcs.emory.edu/~ono/publications-cv/pdfs/ 026.pdf
+6. [35] A nonempty set $S$ is called well-filled if for every $m \in S$, there are fewer than $\frac{1}{2} m$ elements of $S$ which are less than $m$. Determine the number of well-filled subsets of $\{1,2, \ldots, 42\}$.
+Proposed by: Casey Fu
+Answer: $\binom{43}{21}-1$
+Let $a_{n}$ be the number of well-filled subsets whose maximum element is $n$ (setting $a_{0}=1$ ). Then it's easy to see that
+
+$$
+\begin{aligned}
+& a_{2 k+1}=a_{2 k}+a_{2 k-1}+\cdots+a_{0} \\
+& a_{2 k+2}=\left(a_{2 k+1}-C_{k}\right)+a_{2 k}+\cdots+a_{0}
+\end{aligned}
+$$
+
+where $C_{k}$ is the number of well-filled subsets of size $k+1$ with maximal element $2 k+1$.
+We proceed to compute $C_{k}$. One can think of such a subset as a sequence of numbers $1 \leq s_{1}<\cdots<$ $s_{k+1} \leq 2 k+1$ such that $s_{i} \geq 2 i-1$ for every $1 \leq i \leq k+1$. Equivalently, letting $s_{i}=i+1+t_{i}$ it's the number of sequences $0 \leq t_{1} \leq \cdots \leq t_{k+1} \leq k+1$ such that $t_{i} \geq i$ for every $i$. This gives the list of $x$-coordinates of steps up in a Catalan path from $(0,0)$ to $(k+1, k+1)$, so
+
+$$
+C_{k}=\frac{1}{k+2}\binom{2(k+1)}{(k+1)}
+$$
+
+is equal to the $(k+1)$ th Catalan number.
+From this we can solve the above recursion to derive that
+
+$$
+a_{n}=\binom{n}{\lfloor(n-1) / 2\rfloor}
+$$
+
+Consequently, for even $n$,
+
+$$
+a_{0}+\cdots+a_{n}=a_{n+1}=\binom{n+1}{\lfloor n / 2\rfloor}
+$$
+
+Putting $n=42$ gives the answer, after subtracting off the empty set (counted in $a_{0}$ ).
+7. [40] Let $q(x)=q^{1}(x)=2 x^{2}+2 x-1$, and let $q^{n}(x)=q\left(q^{n-1}(x)\right)$ for $n>1$. How many negative real roots does $q^{2016}(x)$ have?
+Proposed by: Ernest Chiu
+Answer: $\frac{2^{2017}+1}{3}$
+Define $g(x)=2 x^{2}-1$, so that $q(x)=-\frac{1}{2}+g\left(x+\frac{1}{2}\right)$. Thus
+
+$$
+q^{N}(x)=0 \Longleftrightarrow \frac{1}{2}=g^{N}\left(x+\frac{1}{2}\right)
+$$
+
+where $N=2016$.
+But, viewed as function $g:[-1,1] \rightarrow[-1,1]$ we have that $g(x)=\cos (2 \arccos (x))$. Thus, the equation $q^{N}(x)=0$ is equivalent to
+
+$$
+\cos \left(2^{2016} \arccos \left(x+\frac{1}{2}\right)\right)=\frac{1}{2}
+$$
+
+Thus, the solutions for $x$ are
+
+$$
+x=-\frac{1}{2}+\cos \left(\frac{\pi / 3+2 \pi n}{2^{2016}}\right) \quad n=0,1, \ldots, 2^{2016}-1
+$$
+
+So, the roots are negative for the values of $n$ such that
+
+$$
+\frac{1}{3} \pi<\frac{\pi / 3+2 \pi n}{2^{2016}}<\frac{5}{3} \pi
+$$
+
+which is to say
+
+$$
+\frac{1}{6}\left(2^{2016}-1\right)0$ (otherwise replace $P(t)$ with $P(-t)$ ).
+Equivalently, there exist infinitely many $(t, k)$ with $t \geq M$ and $k \geq 0$ such that
+
+$$
+0=Q(t+k)-Q(-t)=a_{n}\left[(t+k)^{n+1}-(-t)^{n+1}\right]+\cdots+a_{0}\left[(t+k)^{1}-(-t)^{1}\right] .
+$$
+
+If $k \neq 0$, then $Q(x+k)-Q(-x)$ has constant term $Q(k)-Q(0)=k P(k) \neq 0$, and if $k=0$, then $Q(x+k)-Q(-x)=2\left(a_{0} x^{1}+a_{2} x^{3}+\cdots+a_{n-1} x^{n}\right)$ has $x^{1}$ coefficient nonzero (otherwise $\left.P(0)=0\right)$, so no fixed $k$ yields infinitely many solutions.
+
+Hence for any $N \geq 0$, there exist $k=k_{N} \geq N$ and $t=t_{N} \geq M$ such that $0=Q(t+k)-Q(-t)$. But then the triangle inequality yields
+
+$$
+\underbrace{a_{n}\left[(t+k)^{n+1}-(-t)^{n+1}\right]}_{=\sum_{i=0}^{n-1}-a_{i}\left[(t+k)^{i+1}-(-t)^{i}\right]} \leq 2(t+k)^{n}\left(\left|a_{n-1}\right|+\cdots+\left|a_{0}\right|\right) .
+$$
+
+But $(t+k)^{n+1}-t^{n+1} \geq(t+k)^{n+1}-t \cdot(t+k)^{n}=k \cdot(t+k)^{n} 1$ so $a_{n} k_{N} \leq 2\left(\left|a_{n-1}\right|+\cdots+\left|a_{0}\right|\right)$ for all $N$. Since $k_{N} \geq N$, this gives a contradiction for sufficiently large $N$.
+
+[^0]Remark 2. Another way to finish after the triangle inequality estimate (1) is to observe that $(t+$ $k)^{n+1}-(-t)^{n+1}=(t+k)^{n+1}-t^{n+1} \geq t^{n} \cdot k+k^{n+1}$ (by binomial expansion), so $\frac{k_{N}\left(t_{N}^{n}+k_{N}^{n}\right)}{\left(t_{N}+k_{N}\right)^{n}}$ (which by Holder's inequality is at least $\frac{k_{N}}{2^{n-1}} \geq \frac{N}{2^{n-1}}$ ) is bounded above (independently of $N$ ), contradiction. (Here we use Holder's inequality to deduce $(1+1)^{n-1}\left(a^{n}+b^{n}\right) \geq(a+b)^{n}$ for positive reals $a, b$.)
+Remark 3. The statement is vacuous for even-degree polynomials. The case of degree 3 polynomials was given as ISL 2002 A3.
+5. [12] Let $S=\left\{a_{1}, \ldots, a_{n}\right\}$ be a finite set of positive integers of size $n \geq 1$, and let $T$ be the set of all positive integers that can be expressed as sums of perfect powers (including 1) of distinct numbers in $S$, meaning
+
+$$
+T=\left\{\sum_{i=1}^{n} a_{i}^{e_{i}} \mid e_{1}, e_{2}, \ldots, e_{n} \geq 0\right\}
+$$
+
+Show that there is a positive integer $N$ (only depending on $n$ ) such that $T$ contains no arithmetic progression of length $N$.
+Proposed by: Yang Liu
+Answer: N/A
+In general we can assume that each $a_{i}>1$, since replacing $a_{i}=1$ by some large integer $a$ creates a set $T$ containing the original $T$ as a subset (by setting $e_{i}=0$ ).
+We proceed by induction on $n$. For the base case $n=1$, an arithmetic progression of length at least 3 would give $a_{1}^{e_{1}}+a_{1}^{e_{3}}=2 a_{1}^{e_{2}}$ where $e_{3}>e_{2}>e_{1}$. But $a_{1}^{e_{3}} \geq 2 a_{1}^{e_{2}}$, so this is impossible. Thus our result holds for $n=1$.
+
+Assume the result is true for some $n-1$, and let $A_{n-1}$ be a number such that the longest progression when $|S|=n-1$ has length less than $A_{n-1}$. Let $M$ be a large integer that we will choose later. Take an arithmetic progression of length $2 M+1$, calling the terms $b_{1}, b_{2}, \ldots, b_{2 M+1}$. Note that $b_{2 M+1} \leq$ $2 b_{M+1}$, since $b$ is a sequence of positive integers. For each term from $b_{M+1}$ to $b_{2 M+1}$ assign to it the maximum power that is part of the sum. Call this value $c\left(b_{i}\right)$. More explicitly, if $b_{i}=\sum_{j=1}^{n} a_{j}^{e_{j}}$, then $c\left(b_{i}\right)=\max \left(a_{1}^{e_{1}}, a_{2}^{e_{2}}, \ldots, a_{n}^{e_{n}}\right)$.
+Since $\frac{b_{M+1}}{n} \leq c\left(b_{i}\right) \leq b_{2 M+1} \leq 2 b_{M+1}$ for $M+1 \leq i \leq 2 M+1$, there are at most $\sum_{j=1}^{n}\left(\log _{a_{i}} 2 n+1\right) \leq$ $n\left(\log _{2} 2 n+1\right)$ different values of $c\left(b_{i}\right)$. By Van der Waerden's Theorem, there exists a value of $M$ such that coloring an arithmetic progression of length $M$ with $n\left(\log _{2} 2 n+1\right)$ colors yields a monochromatic arithmetic progression of length $A_{n-1}$. In particular, we can take $M=W\left(A_{n-1}, n\left(\log _{2} 2 n+1\right)\right)$, where $W(n, k)$ denotes the Van der Waerden number. So, we color $b_{M+1}, \ldots, b_{2 M+1}$ by their $c\left(b_{i}\right)$. Subtracting the common perfect power from each term of the monochromatic arithmetic progression obtained gives an arithmetic progression of $A_{n-1}$ integers expressible as the sum of perfect powers of distinct numbers in $S \backslash a_{j}$. By the inductive hypothesis, this is a contradiction. So no arithmetic progression of length $2 M+1$ can be contained in $T$, and we can take $A_{n}=2 M+1$.
+By induction, we thus have such an $A_{n}$ for all $n$.
+
+
+[^0]: ${ }^{1}$ However, the mean value theorem estimate $(t+k)^{n+1}-t^{n+1} \geq k \cdot(n+1) t^{n}$ will not suffice a priori, if $k$ happens to be much larger than $t$. Of course, it is easy to prove that $k$ cannot be too much larger than $t$ (even before finishing the problem); the execution would just take slightly longer.
+
diff --git a/HarvardMIT/md/en-201-2016-nov-gen-solutions.md b/HarvardMIT/md/en-201-2016-nov-gen-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..e252220cab96f3577fbd1db1db5efe50d3221ea3
--- /dev/null
+++ b/HarvardMIT/md/en-201-2016-nov-gen-solutions.md
@@ -0,0 +1,109 @@
+## HMMT November 2016
+
+## November 12, 2016
+
+## General
+
+1. If $a$ and $b$ satisfy the equations $a+\frac{1}{b}=4$ and $\frac{1}{a}+b=\frac{16}{15}$, determine the product of all possible values of $a b$.
+
+## Proposed by: Eshaan Nichani
+
+Answer: 1
+We multiply $a+\frac{1}{b}=4$ and $\frac{1}{a}+b=\frac{16}{15}$ to get $2+a b+\frac{1}{a b}=\frac{64}{15} \Longleftrightarrow(a b)^{2}-\frac{34}{15}(a b)+1=0$. Since $\left(\frac{34}{14}\right)^{2}-4 \cdot 1 \cdot 1>0$, there are two roots $a b$, so the product of both possible values of $a b$ is 1 by Vieta's.
+2. I have five different pairs of socks. Every day for five days, I pick two socks at random without replacement to wear for the day. Find the probability that I wear matching socks on both the third day and the fifth day.
+Proposed by: Kevin Yang
+Answer: $\frac{1}{63}$
+I get a matching pair on the third day with probability $\frac{1}{9}$ because there is a $\frac{1}{9}$ probability of the second sock matching the first. Given that I already removed a matching pair of the third day, I get a matching pair on the fifth day with probability $\frac{1}{7}$. We multiply these probabilities to get $\frac{1}{63}$.
+3. Let $V$ be a rectangular prism with integer side lengths. The largest face has area 240 and the smallest face has area 48. A third face has area $x$, where $x$ is not equal to 48 or 240 . What is the sum of all possible values of $x$ ?
+
+## Proposed by: Eshaan Nichani
+
+Answer: 260
+Let the length, width, and height of the prism be $s_{1}, s_{2}, s_{3}$. WIthout loss of generality, assume that $s_{1} \leq s_{2} \leq s_{3}$. Then, we have that $s_{1} s_{2}=48$ and $s_{2} s_{3}=240$. Noting that $s_{1} \leq s_{2}$, we must have $\left(s_{1}, s_{2}\right)=(1,48),(2,24),(3,16),(4,12),(6,8)$. We must also have $s_{2} s_{3}=240$ and $s_{2} \leq s_{3}$, and the only possibilities for $\left(s_{1}, s_{2}\right)$ that yield integral $s_{3}$ that satisfy these conditions are $(4,12)$, which gives $s_{3}=20$, and $(6,8)$, which gives $s_{3}=30$. Thus, the only valid $\left(s_{1}, s_{2}, s_{3}\right)$ are $(4,12,20)$ and $(6,8,30)$. It follows that the only possible areas of the third face are $4(20)=80$ and $6(30)=180$, so the desired answer is $80+180=260$.
+4. A rectangular pool table has vertices at $(0,0)(12,0)(0,10)$, and $(12,10)$. There are pockets only in the four corners. A ball is hit from $(0,0)$ along the line $y=x$ and bounces off several walls before eventually entering a pocket. Find the number of walls that the ball bounces off of before entering a pocket.
+Proposed by: Allen Liu
+Answer: 9
+Consider the tiling of the plane with the $12 \times 10$ rectangle to form a grid. Then the reflection of the ball off a wall is equivalent to traveling along the straight line $y=x$ into another $12 \times 10$ rectangle. Hence we want to find the number of walls of the grid that the line $y=x$ hits before it reaches the first corner it hits, $(60,60)$.
+The line $y=x$ hits each of the horizontal lines $y=10,20,30,40,50$ and each of the vertical lines $x=12,24,36,48$. This gives a total of 9 walls hit before entering a pocket.
+5. Let the sequence $\left\{a_{i}\right\}_{i=0}^{\infty}$ be defined by $a_{0}=\frac{1}{2}$ and $a_{n}=1+\left(a_{n-1}-1\right)^{2}$. Find the product
+
+$$
+\prod_{i=0}^{\infty} a_{i}=a_{0} a_{1} a_{2} \ldots
+$$
+
+Proposed by: Henrik Boecken
+
+## Answer: $\frac{2}{3}$
+
+Let $\left\{b_{i}\right\}_{i=0}^{\infty}$ be defined by $b_{n}=a_{n}-1$ and note that $b_{n}=b_{n-1}^{2}$. The infinite product is then
+
+$$
+\left(1+b_{0}\right)\left(1+b_{0}^{2}\right)\left(1+b_{0}^{4}\right) \ldots\left(1+b_{0}^{2^{k}}\right) \ldots
+$$
+
+By the polynomial identity
+
+$$
+(1+x)\left(1+x^{2}\right)\left(1+x^{4}\right) \ldots\left(1+x^{2^{k}}\right) \cdots=1+x+x^{2}+x^{3}+\cdots=\frac{1}{1-x}
+$$
+
+Our desired product is then simply
+
+$$
+\frac{1}{1-\left(a_{0}-1\right)}=\frac{2}{3}
+$$
+
+6. The numbers $1,2 \cdots 11$ are arranged in a line from left to right in a random order. It is observed that the middle number is larger than exactly one number to its left. Find the probability that it is larger than exactly one number to its right.
+Proposed by: Allen Liu
+Answer: $\frac{10}{33}$
+Suppose the middle number is $k$. Then there are $k-1$ ways to pick the number smaller than $k$ to its left and $\binom{11-k}{4}$ ways to pick the 4 numbers larger than $k$ to its right. Hence there is a total of $\sum_{k=2}^{7}(k-1) \cdot\binom{11-k}{4}$ ways for there to be exactly one number smaller than $k$ to its left. We calculate this total:
+
+$$
+\begin{aligned}
+\sum_{k=2}^{7}(k-1) \cdot\binom{11-k}{4} & =\sum_{j=4}^{9} \sum_{i=4}^{j}\binom{i}{4} \\
+& =\sum_{j=4}^{9}\binom{j+1}{5} \\
+& =\binom{11}{6}
+\end{aligned}
+$$
+
+The only way $k$ can be larger than exactly one number to its right is if $k=3$. Then the probability of this happening is $\frac{2 \cdot\binom{8}{4}}{\binom{11}{6}}=\frac{10}{33}$.
+7. Let $A B C$ be a triangle with $A B=13, B C=14, C A=15$. The altitude from $A$ intersects $B C$ at $D$. Let $\omega_{1}$ and $\omega_{2}$ be the incircles of $A B D$ and $A C D$, and let the common external tangent of $\omega_{1}$ and $\omega_{2}$ (other than $B C$ ) intersect $A D$ at $E$. Compute the length of $A E$.
+Proposed by: Eshaan Nichani
+Answer: $\quad 7$
+
+## Solution 1:
+
+Let $I_{1}, I_{2}$ be the centers of $\omega_{1}, \omega_{2}$, respectively, $X_{1}, X_{2}$ be the tangency points of $\omega_{1}, \omega_{2}$ with $B C$, respectively, and $Y_{1}, Y_{2}$ be the tangency points of $\omega_{1}, \omega_{2}$ with $A D$, respectively. Let the two common external tangents of $\omega_{1}, \omega_{2}$ meet at $P$. Note that line $I_{1} I_{2}$ also passes through $P$.
+By Heron's formula, the area of triangle $A B C$ is 84 . Thus, $\frac{1}{2} A D \cdot B C=84$, and so $A D=12$. By the Pythagorean Theorem on right triangles $A B D$ and $A C D, B D=5$ and $C D=9$.
+The inradius of $A B D, r_{A B D}$, is $\frac{[A B D]}{s_{A B D}}$, where $[A B D]$ is the area of $A B D$ and $s_{A B D}$ is its semiperimeter. $A B D$ is a $5-12-13$ right triangle, so $[A B D]=30$ and $s_{A B D}=15$. Thus, $r_{A B D}=2$. Similarly, we get
+that $A C D$ 's inradius is $r_{A C D}=3 . I_{1} Y_{1} D X_{1}$ is a square, so $X_{1} D=I_{1} X_{1}=r_{A B D}=2$, and similarly $X_{2} D=3 . X_{1}$ and $X_{2}$ are on opposite sides of $D$, so $X_{1} X_{2}=X_{1} D+X_{2} D=5$.
+Since $P$ lies on lines $I_{1} I_{2}, X_{1} X_{2}$, and $I_{1} X_{1}, I_{2} X_{2}$ are parallel, triangles $P X_{1} I_{1}$ and $P X_{2} I_{2}$ are similar. Thus, $\frac{X_{1} I_{1}}{X_{2} I_{2}}=\frac{2}{3}=\frac{P X_{1}}{P X_{2}}=\frac{P X_{1}}{P X_{1}+X_{1} X_{2}}=\frac{P X_{1}}{P X_{1}+5}$. Solving gives $P X_{1}=10$. Letting $\angle I_{1} P X_{1}=\theta$, since $I_{1} X_{1} P$ is a right angle, we have $\tan \theta=\frac{X_{1} I_{1}}{X_{1} P_{1}}=\frac{1}{5}$. $D$ and $E$ lie on different common external tangents, so $P I_{1}$ bisects $\angle E P D$, and thus $\angle E P D=2 \theta$. Thus, $\tan \angle E P D=\tan 2 \theta=\frac{2 \tan \theta}{1-\tan ^{2} \theta}=\frac{5}{12}$.
+$E D$ is perpendicular to $B C$, so triangle $E D P$ is a right triangle with right angle at $D$. Thus, $\frac{5}{12}=$ $\tan \angle E P D=\frac{E D}{P D} . P D=P X_{1}+X_{1} D=12$, so $E D=5 . A D=12$, so it follows that $A E=7$.
+
+## Solution 2:
+
+Lemma: Let $\Omega_{1}, \Omega_{2}$ be two non-intersecting circles. Let $\ell_{A}, \ell_{B}$ be their common external tangents, and $\ell_{C}$ be one of their common internal tangents. $\Omega_{1}$ intersects $\ell_{A}, \ell_{B}$ at points $A_{1}, B_{1}$, respectively, and $\Omega_{2}$ intersects $\ell_{A}, \ell_{B}$ at points $A_{2}, B_{2}$. If $\ell_{C}$ intersects $\ell_{A}$ at $X$, and $\ell_{B}$ at $Y$, then $X Y=A_{1} A_{2}=B_{1} B_{2}$.
+Proof: Let $\ell_{C}$ intersect $\Omega_{1}, \Omega_{2}$ at $C_{1}, C_{2}$, respectively. Then, examining the tangents to $\Omega_{1}, \Omega_{2}$ from $X, Y$, we have $A_{1} X=C_{1} X, A_{2} X=C_{2} X, B_{1} Y=C_{1} Y, B_{2} Y=C_{2} Y$. Thus, $2 A_{1} A_{2}=2 B_{1} B_{2}=$ $A_{1} A_{2}+B_{1} B_{2}=A_{1} X+A_{2} X+B_{1} Y+B_{2} Y=C_{1} X+C_{2} X+C_{1} Y+C_{2} Y=2 X Y$, and the conclusion follows.
+Using the notation from above, we apply the lemma to circles $\omega_{1}, \omega_{2}$, and conclude that $E D=X_{1} X_{2}$. Then, we proceed as above to compute $X_{1} X_{2}=5=E D$. Thus, $A D=7$.
+8. Let $S=\{1,2, \ldots 2016\}$, and let $f$ be a randomly chosen bijection from $S$ to itself. Let $n$ be the smallest positive integer such that $f^{(n)}(1)=1$, where $f^{(i)}(x)=f\left(f^{(i-1)}(x)\right)$. What is the expected value of $n$ ?
+Proposed by: Eshaan Nichani
+Answer: $\frac{2017}{2}$
+Say that $n=k$. Then $1, f(1), f^{2}(1), \ldots, f^{(k-1)}(1)$ are all distinct, which means there are 2015 . $2014 \cdots(2016-k+1)$ ways to assign these values. There is 1 possible value of $f^{k}(1)$, and $(2016-k)$ ! ways to assign the image of the $2016-k$ remaining values. Thus the probability that $n=k$ is $\frac{1}{2016}$. Therefore the expected value of $n$ is $\frac{1}{2016}(1+2+\cdots+2016)=\frac{2017}{2}$
+9. Let the sequence $a_{i}$ be defined as $a_{i+1}=2^{a_{i}}$. Find the number of integers $1 \leq n \leq 1000$ such that if $a_{0}=n$, then 100 divides $a_{1000}-a_{1}$.
+Proposed by: Allen Liu
+
+## Answer: 50
+
+We claim that $a_{1000}$ is constant mod 100 .
+$a_{997}$ is divisible by 2 . This means that $a_{998}$ is divisible by 4 . Thus $a_{999}$ is constant mod 5 . Since it is also divisible by 4 , it is constant $\bmod 20$. Thus $a_{1000}$ is constant $\bmod 25$, since $\phi(25)=20$. Since $a_{1000}$ is also divisible by 4 , it is constant mod 100 .
+We know that $a_{1000}$ is divisible by 4 , and let it be congruent to $k \bmod 25$.
+Then $2^{n}$ is divisible by $4(n \geq 2)$ and $2^{n} \equiv k \bmod 25$ We can also show that 2 is a primitive root mod 25 , so there is one unique value of $n \bmod 20$. It suffices to show this value isn't 1 . But $2^{2^{0 \bmod 4}} \equiv 2^{16 \bmod 20}$ $\bmod 25$, so $n \equiv 16 \bmod 20$. Thus there are $1000 / 20=50$ values of $n$.
+10. Quadrilateral $A B C D$ satisfies $A B=8, B C=5, C D=17, D A=10$. Let $E$ be the intersection of $A C$ and $B D$. Suppose $B E: E D=1: 2$. Find the area of $A B C D$.
+Proposed by: Brice Huang
+Answer: 60
+Since $B E: E D=1: 2$, we have $[A B C]:[A C D]=1: 2$.
+Suppose we cut off triangle $A C D$, reflect it across the perpendicular bisector of $A C$, and re-attach it as triangle $A^{\prime} C^{\prime} D^{\prime}\left(\right.$ so $\left.A^{\prime}=C, C^{\prime}=A\right)$.
+
+Triangles $A B C$ and $C^{\prime} A^{\prime} D^{\prime}$ have vertex $A=C^{\prime}$ and bases $B C$ and $A^{\prime} D^{\prime}$. Their areas and bases are both in the ratio $1: 2$. Thus in fact $B C$ and $A^{\prime} D^{\prime}$ are collinear.
+Hence the union of $A B C$ and $C^{\prime} A^{\prime} D^{\prime}$ is the $8-15-17$ triangle $A B D^{\prime}$, which has area $\frac{1}{2} \cdot 8 \cdot 15=60$.
+
diff --git a/HarvardMIT/md/en-201-2016-nov-guts-solutions.md b/HarvardMIT/md/en-201-2016-nov-guts-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..2131ef1cf8259e4cca6be5ed28a38ad1cd9553fb
--- /dev/null
+++ b/HarvardMIT/md/en-201-2016-nov-guts-solutions.md
@@ -0,0 +1,367 @@
+# HMMT November 2016
+
+## November 12, 2016
+
+Guts
+
+1. [5] If five fair coins are flipped simultaneously, what is the probability that at least three of them show heads?
+Proposed by: Allen Liu
+
+
+The coin either lands heads-up at least three times or lands heads-down at least three times. These scenarios are symmetric so the probably is just $\frac{1}{2}$.
+Alternatively, we can explicitly compute the probability, which is just $\frac{\binom{5}{3}+\binom{5}{4}+\binom{5}{5}}{2^{5}}=\frac{16}{32}=\frac{1}{2}$
+2. [5] How many perfect squares divide $10^{10}$ ?
+
+Proposed by: Evan Chen
+Answer: 36
+A perfect square $s$ divides $10^{10}$ if and only if $s=2^{a} \cdot 5^{b}$ where $a, b \in\{0,2,4,6,8,10\}$. There are 36 choices, giving 36 different $s$ 's.
+3. [5] Evaluate $\frac{2016!^{2}}{2015!2017!}$. Here $n$ ! denotes $1 \times 2 \times \cdots \times n$.
+
+Proposed by: Evan Chen
+Answer: $\square$
+$\frac{2016!^{2}}{2015!2017!}=\frac{2016!}{2015!} \frac{2016!}{2017!}=\frac{2016}{1} \frac{1}{2017}=\frac{2016}{2017}$
+4. [6] A square can be divided into four congruent figures as shown:
+
+
+For how many $n$ with $1 \leq n \leq 100$ can a unit square be divided into $n$ congruent figures?
+Proposed by: Kevin Sun
+Answer: 100
+We can divide the square into congruent rectangles for all $n$, so the answer is 100 .
+5. [6] If $x+2 y-3 z=7$ and $2 x-y+2 z=6$, determine $8 x+y$.
+
+Proposed by: Eshaan Nichani
+Answer: 32
+$8 x+y=2(x+2 y-3 z)+3(2 x-y+2 x)=2(7)+3(6)=32$
+6. [6] Let $A B C D$ be a rectangle, and let $E$ and $F$ be points on segment $A B$ such that $A E=E F=F B$. If $C E$ intersects the line $A D$ at $P$, and $P F$ intersects $B C$ at $Q$, determine the ratio of $B Q$ to $C Q$.
+Proposed by: Eshaan Nichani
+Answer: $1 / 3$
+Because $\triangle P A E \sim \triangle P D C$ and $A E: D C=1: 3$, we have that $P A: P D=1: 3 \Longrightarrow P A: A B=P A$ : $B C=1: 2$. Also, by similar triangles $\triangle P A F \sim \triangle Q B F$, since $A F: B F=2: 1, P A: B Q=2: 1$. Then $B Q=\frac{1}{2} P A=\frac{1}{2} \cdot \frac{1}{2} B C=\frac{1}{4} B C$. Then $B Q: C Q=\frac{1}{3}$.
+7. [7] What is the minimum value of the product
+
+$$
+\prod_{i=1}^{6} \frac{a_{i}-a_{i+1}}{a_{i+2}-a_{i+3}}
+$$
+
+given that $\left(a_{1}, a_{2}, a_{3}, a_{4}, a_{5}, a_{6}\right)$ is a permutation of $(1,2,3,4,5,6)$ ? (note $\left.a_{7}=a_{1}, a_{8}=a_{2} \cdots\right)$
+Proposed by: Kevin Sun
+Answer: 1
+The product always evaluates to 1 .
+8. [7] Danielle picks a positive integer $1 \leq n \leq 2016$ uniformly at random. What is the probability that $\operatorname{gcd}(n, 2015)=1$ ?
+Proposed by: Evan Chen
+Answer:
+
+
+We split the interval $[1,2016]$ into $[1,2015]$ and 2016. The number of integers in $[1,2015]$ that are relatively prime to 2015 is $\phi(2015)=\frac{4}{5} \cdot \frac{12}{13} \cdot \frac{30}{31} \cdot 2015=1440$. Also, 2016 is relatively prime to 2015 , so there are a total of 1441 numbers in $[1,2016]$ that are relatively prime to 2015 . Then the probability of picking a number relatively prime to 2015 is $\frac{1441}{2016}$
+9. [7] How many 3 -element subsets of the set $\{1,2,3, \ldots, 19\}$ have sum of elements divisible by 4?
+
+Proposed by: Sam Korsky
+Answer: 244
+Consider the elements of the sets mod 4. Then we would need to have sets of the form $\{0,0,0\}$, $\{0,2,2\},\{0,1,3\},\{1,1,2\}$, or $\{2,3,3\}$. In the set $\{1,2, \ldots, 19\}$ there four elements divisible by 4 and 5 elements congruent to each of $1,2,3 \bmod 4$. Hence the desired number is given by
+
+$$
+\binom{4}{3}+\binom{4}{1}\binom{5}{2}+\binom{4}{1}\binom{5}{1}\binom{5}{1}+\binom{5}{2}\binom{5}{1}+\binom{5}{1}\binom{5}{2}=244
+$$
+
+10. [8] Michael is playing basketball. He makes $10 \%$ of his shots, and gets the ball back after $90 \%$ of his missed shots. If he does not get the ball back he stops playing. What is the probability that Michael eventually makes a shot?
+Proposed by: Eshaan Nichani
+Answer: $10 / 19$
+We find the probability Michael never makes a shot. We do casework on the number of shots Michael takes. He takes only one shot with probability $\frac{9}{10} \cdot \frac{1}{10}$ (he misses with probability $\frac{9}{10}$ and does not get the ball back with probability $\frac{1}{10}$ ). Similarly, he takes two shots with probability $\frac{9}{10} \cdot \frac{9}{10} \cdot \frac{9}{10} \cdot \frac{1}{10}$, three shots with probability $\left(\frac{9}{10}\right)^{5} \frac{1}{10}$, and so on. So we want to sum $\sum_{i=1}^{\infty}\left(\frac{9}{10}\right)^{2 i-1} \cdot \frac{1}{10}=\frac{\frac{1}{10} \cdot \frac{9}{10}}{1-\frac{81}{100}}=\frac{9}{19}$. Then the probability Michael makes a shot is $1-\frac{9}{19}=\frac{10}{19}$.
+11. [8] How many subsets $S$ of the set $\{1,2, \ldots, 10\}$ satisfy the property that, for all $i \in[1,9]$, either $i$ or $i+1$ (or both) is in $S$ ?
+Proposed by: Eshaan Nichani
+Answer: 144
+We do casework on the number of $i$ 's not in $S$. Notice that these $i$ 's that are not in $S$ cannot be consecutive, otherwise there exists an index $i$ such that both $i$ and $i+1$ are both not in $S$. Hence if
+there are $k i$ 's not in $S$, we want to arrange $k$ black balls and $10-k$ white balls such that no two black balls are consecutive. Take out $k-1$ white balls to insert back between black balls later, then we want to arrange $k$ black balls and $11-2 k$ white balls arbitrarily, which can be done in $\binom{11-k}{k}$ ways. Hence we want to find the sum $\binom{11}{0}+\binom{10}{1}+\binom{9}{2}+\binom{8}{3}+\binom{7}{4}+\binom{6}{5}$, which is equal to 144 ways.
+12. [8] A positive integer $\overline{A B C}$, where $A, B, C$ are digits, satisfies
+
+$$
+\overline{A B C}=B^{C}-A
+$$
+
+Find $\overline{A B C}$.
+
+## Proposed by: Henrik Boecken
+
+The equation is equivalent to $100 A+10 B+C=B^{C}-A$. Suppose $A=0$, so that we get $10 B+C=B^{C}$. Reducing mod $B$, we find that $C$ must be divisible by $B . C \neq 0$, since otherwise $10 B=1$, contradiction, so $C \geq B$. Thus $10 B+C \geq B^{B}$ for digits $B, C$. For $B \geq 4$, we have $100>10 B+C \geq B^{B}>100$, a contradiction, so $B=1,2,3$. We can easily test that these do not yield solutions, so there are no solutions when $A=0$.
+Thus $A \geq 1$, and so $100 \leq 100 A+10 B+C \leq 1000$, and thus $100 \leq B^{C}-A \leq 1000.1 \leq A \leq 10$, so we have $101 \leq B^{C} \leq 1010$. We can test that the only pairs $(B, C)$ that satisfy this condition are $(2,7),(2,8),(2,9),(3,5),(3,6),(4,4),(5,3),(6,3),(7,3),(8,3),(9,3)$. Of these pairs, only $(2,7)$ yields a solution to the original equation, namely $A=1, B=2, C=7$. Thus $\overline{A B C}=127$.
+13. [9] How many functions $f:\{0,1\}^{3} \rightarrow\{0,1\}$ satisfy the property that, for all ordered triples $\left(a_{1}, a_{2}, a_{3}\right)$ and $\left(b_{1}, b_{2}, b_{3}\right)$ such that $a_{i} \geq b_{i}$ for all $i, f\left(a_{1}, a_{2}, a_{3}\right) \geq f\left(b_{1}, b_{2}, b_{3}\right)$ ?
+Proposed by: Eshaan Nichani
+
+## Answer: 20
+
+Consider the unit cube with vertices $\{0,1\}^{3}$. Let $O=(0,0,0), A=(1,0,0), B=(0,1,0), C=(0,0,1)$, $D=(0,1,1), E=(1,0,1), F=(1,1,0)$, and $P=(1,1,1)$. We want to find a function $f$ on these vertices such that $f(1, y, z) \geq f(0, y, z)$ (and symmetric representations). For instance, if $f(A)=1$, then $f(E)=f(F)=f(P)=1$ as well, and if $f(D)=1$, then $f(P)=1$ as well.
+We group the vertices into four levels: $L_{0}=\{O\}, L_{1}=\{A, B, C\}, L_{2}=\{D, E, F\}$, and $L_{3}=\{P\}$. We do casework on the lowest level of a 1 in a function.
+
+- If the 1 is in $L_{0}$, then $f$ maps everything to 1 , for a total of 1 way.
+- If the 1 is in $L_{1}$, then $f(O)=0$. If there are 31 's in $L_{1}$, then everything but $O$ must be mapped to 1 , for 1 way. If there are 21 's in $L_{1}$, then $f\left(L_{2}\right)=f\left(L_{3}\right)=1$, and there are 3 ways to choose the 21 's in $L_{1}$, for a total of 3 ways. If there is one 1 , then WLOG $f(A)=1$. Then $f(E)=f(F)=f(P)=1$, and $f(D)$ equals either 0 or 1 . There are $3 \cdot 2=6$ ways to do this. In total, there are $1+3+6=10$ ways for the lowest 1 to be in $L_{1}$.
+- If the lowest 1 is in $L_{2}$, then $f(O)=f\left(L_{1}\right)=0$. If there are 31 's in $L_{2}$, there is one way to make $f$. If there are 21 's, then we can pick the 21 's in 3 ways. Finally, if there is one 1 , then we pick this 1 in 3 ways. There are $1+3+3=7$ ways.
+- The lowest 1 is in $L_{3}$. There is 1 way.
+- There are no 1 's. Then $f$ sends everything to 0 . There is 1 way.
+
+In total, there are $1+10+7+1+1=20$ total $f^{\prime}$ 's.
+14. [9] The very hungry caterpillar lives on the number line. For each non-zero integer $i$, a fruit sits on the point with coordinate $i$. The caterpillar moves back and forth; whenever he reaches a point with food, he eats the food, increasing his weight by one pound, and turns around. The caterpillar moves at a speed of $2^{-w}$ units per day, where $w$ is his weight. If the caterpillar starts off at the origin, weighing zero pounds, and initially moves in the positive $x$ direction, after how many days will he weigh 10 pounds?
+
+Proposed by: Eshaan Nichani
+Answer: 9217
+On the $n$th straight path, the caterpillar travels $n$ units before hitting food and his weight is $n-1$. Then his speed is $2^{1-n}$. Then right before he turns around for the $n$th time, he has traveled a total time of $\sum_{i=1}^{n} \frac{i}{2^{1-i}}=\frac{1}{2} \sum_{i=1}^{n} i \cdot 2^{i}$. We want to know how many days the catepillar moves before his weight is 10 , so we want to take $n=10$ so that his last straight path was taken at weight 9 . Hence we want to evaluate $S=\frac{1}{2} \sum_{i=1}^{10} i \cdot 2^{i}$. Note that $2 S=\frac{1}{2} \sum_{i=2}^{11}(i-1) \cdot 2^{i}$, so $S=2 S-S=\frac{1}{2}\left(11 \cdot 2^{11}-\sum_{i=1}^{10} 2^{i}\right)=$ $\frac{1}{2}\left(10 \cdot 2^{11}-2^{11}+2\right)=9217$.
+15. [9] Let $A B C D$ be an isosceles trapezoid with parallel bases $A B=1$ and $C D=2$ and height 1. Find the area of the region containing all points inside $A B C D$ whose projections onto the four sides of the trapezoid lie on the segments formed by $A B, B C, C D$ and $D A$.
+Proposed by: Allen Liu
+Answer: $\frac{5}{8}$
+Let $E, F$, be the projections of $A, B$ on $C D$. A point whose projections lie on the sides must be contained in the square $A B F E$. Furthermore, the point must lie under the perpendicular to $A D$ at $A$ and the perpendicular to $B C$ at $B$, which have slopes $\frac{1}{2}$ and $-\frac{1}{2}$. The area of the desired pentagon is $1-\frac{1}{4}-\frac{1}{8}=\frac{5}{8}$.
+16. [10] Create a cube $C_{1}$ with edge length 1 . Take the centers of the faces and connect them to form an octahedron $O_{1}$. Take the centers of the octahedron's faces and connect them to form a new cube $C_{2}$. Continue this process infinitely. Find the sum of all the surface areas of the cubes and octahedrons.
+Proposed by: Shyam Narayanan
+Answer: $\frac{54+9 \sqrt{3}}{8}$
+The lengths of the second cube are one-third of the lengths of the first cube, so the surface area decreases by a factor of one-ninth. Since the first cube has surface area 6 and the first octahedron has surface area $\sqrt{3}$, the total area is $(6+\sqrt{3}) \cdot\left(1+\frac{1}{9}+\frac{1}{9^{2}}+\cdots\right)=\frac{54+9 \sqrt{3}}{8}$
+17. [10] Let $p(x)=x^{2}-x+1$. Let $\alpha$ be a root of $p(p(p(p(x)))$. Find the value of
+
+$$
+(p(\alpha)-1) p(\alpha) p(p(\alpha)) p(p(p(\alpha))
+$$
+
+Proposed by: Henrik Boecken
+Answer: -1
+Since $(x-1) x=p(x)-1$, we can set
+
+$$
+\begin{aligned}
+(p(\alpha)-1) p(\alpha) p(p(\alpha)) p(p(p(\alpha)) & =(p(p(\alpha))-1) p(p(\alpha)) p(p(p(\alpha)) \\
+& =(p(p(p(\alpha)))-1) p(p(p(\alpha)) \\
+& =p(p(p(p(\alpha))))-1 \\
+& =-1
+\end{aligned}
+$$
+
+18. [10] An 8 by 8 grid of numbers obeys the following pattern:
+1) The first row and first column consist of all 1 s .
+2) The entry in the $i$ th row and $j$ th column equals the sum of the numbers in the $(i-1)$ by $(j-1)$ sub-grid with row less than $i$ and column less than $j$.
+What is the number in the 8 th row and 8 th column?
+
+Proposed by: Eshaan Nichani
+Answer: 2508
+Let $x_{i, j}$ be the number in the $i$ th row and the $j$ th column. Then if $i, j \geq 2, x_{i+1, j+1}-x_{i+1, j}-x_{i, j+1}+x_{i, j}$ only counts the term $x_{i, j}$ since every other term is added and subtracted the same number of times. Thus $x_{i+1, j+1}=x_{i+1, j}+x_{i, j+1}$ when $i, j \geq 2$. Also, $x_{2, i}=x_{i, 2}=i$ so $x_{i+1, j+1}=x_{i+1, j}+x_{i, j+1}$ holds for all $i, j \geq 1$ except for $(i, j)=(1,1)$ where $x_{2,2}$ is one less than expected. This means that $x_{i, j}$ is the number ways of travelling from $(1,1)$ to $(i, j)$, minus the number of ways of travelling from $(2,2)$ to $(i, j)$, which is $\binom{14}{7}-\binom{12}{6}=2508$.
+19. [11] Let $S$ be the set of all positive integers whose prime factorizations only contain powers of the primes 2 and 2017 (1, powers of 2, and powers of 2017 are thus contained in $S$ ). Compute $\sum_{s \in S} \frac{1}{s}$.
+Proposed by: Daniel Qu
+Answer: $\square$
+Since every $s$ can be written as $2^{i} \cdot 2017^{j}$ for non-negative integers $i$ and $j$, the given sum can be written as $\left(\sum_{i=0}^{\infty} \frac{1}{2^{i}}\right)\left(\sum_{j=0}^{\infty} \frac{1}{2017^{j}}\right)$. We can easily find the sum of these geometric series since they both have common ratio of magnitude less than 1 , giving us $\left.\left(\frac{1}{1-\frac{1}{2}}\right) \cdot \frac{1}{1-\frac{1}{2017}}\right)=\frac{2}{1} \cdot \frac{2017}{2016}=\frac{2017}{1008}$.
+20. [11] Let $\mathcal{V}$ be the volume enclosed by the graph
+
+$$
+x^{2016}+y^{2016}+z^{2}=2016
+$$
+
+Find $\mathcal{V}$ rounded to the nearest multiple of ten.
+Proposed by: Henrik Boecken
+Answer: 360
+Let $R$ be the region in question. Then we have
+
+$$
+[-1,1]^{2} \times[-\sqrt{2014}, \sqrt{2014}] \subset R \subset[-\sqrt[2016]{2016}, \sqrt[2016]{2016}]^{2} \times[\sqrt{2016}, \sqrt{2016}]
+$$
+
+We find some bounds: we have
+
+$$
+\sqrt{2016}<\sqrt{2025}=45
+$$
+
+By concavity of $\sqrt{\cdot}$, we have the bound
+
+$$
+\sqrt{2014} \leq \frac{11}{89} \sqrt{1936}+\frac{78}{89} \sqrt{2025}=45-\frac{11}{89}
+$$
+
+Finally, if we let $\sqrt[2016]{2016}=1+\epsilon$, then $(1+\epsilon)^{2016}=2016$, so
+
+$$
+\binom{2016}{5} \epsilon^{5}<2016 \Rightarrow \epsilon<\sqrt[5]{\frac{120}{2015 \cdot 2014 \cdot 2013 \cdot 2012}}<\sqrt[5]{\frac{120}{2000^{4}}}=\sqrt[5]{\frac{7500}{10^{15}}}=\frac{\sqrt[5]{7500}}{1000}<\frac{6}{1000}
+$$
+
+Therefore, the volume of $R$ is lower-bounded by
+
+$$
+2^{2} \cdot 2\left(45-\frac{11}{89}\right)=360-\frac{88}{89}>355
+$$
+
+and upper-bounded by
+
+$$
+2^{2}\left(1+\frac{0.8}{100}\right)^{2} \cdot 2(45)=360\left(1+\frac{6}{1000}\right)^{2}<365
+$$
+
+Thus, $R$ rounded to the nearest ten is 360 .
+21. [11] Zlatan has 2017 socks of various colours. He wants to proudly display one sock of each of the colours, and he counts that there are $N$ ways to select socks from his collection for display. Given this information, what is the maximum value of $N$ ?
+Proposed by: Saranesh Prembabu
+Answer: $3^{671} \cdot 4$
+Say that there are $k$ sock types labeled $1,2, \ldots, k$, and $a_{i}$ socks of type $i$. The problem asks to maximize $\prod_{i=1}^{k} a_{i}$ subject to $\sum_{i=1}^{k} a_{i}=2017$, over all $k$ and all sequences of positive integers $a_{1}, \ldots, a_{k}$.
+
+The optimal $\left(a_{1}, \ldots, a_{k}\right)$ cannot have any $a_{i}=1$ for any $i$, because if there exists $a_{i}=1$ we can delete this $a_{i}$ and add 1 to any $a_{j}(j \neq i)$ to increase the product while keeping the sum constant.
+There exists an optimal $\left(a_{1}, \ldots, a_{k}\right)$ without any $a_{i} \geq 4$ because if there exists $a_{i} \geq 4$ we can replace this $a_{i}$ with $a_{i}-2$ and 2 , which nonstrictly increases the product while keeping the sum constant.
+Therefore, there exists an optimal $\left(a_{1}, \ldots, a_{k}\right)$ whose terms are all 2 or 3 . The optimal $\left(a_{1}, \ldots, a_{k}\right)$ cannot have more than two 2 s , because we can replace three 2 s with two 3 s , which increases the sum by a factor of $\frac{3^{2}}{2^{3}}=\frac{9}{8}$ while keeping the sum constant.
+It follows that we want to partition 2017 into 6713 s and two 2 s , for a product of $3^{671} \cdot 4$.
+22. [12] Let the function $f: \mathbb{Z} \rightarrow \mathbb{Z}$ take only integer inputs and have integer outputs. For any integers $x$ and $y, f$ satisfies
+
+$$
+f(x)+f(y)=f(x+1)+f(y-1)
+$$
+
+If $f(2016)=6102$ and $f(6102)=2016$, what is $f(1) ?$
+Proposed by: Henrik Boecken
+Answer: 8117
+We have
+
+$$
+f(x+1)=f(x)+f(y)-f(y-1)
+$$
+
+If $y$ is fixed, we have
+
+$$
+f(x+1)=f(x)+\text { constant }
+$$
+
+implying $f$ is linear. Using our two points, then, we get $f(x)=8118-x$, so $f(1)=8117$
+23. [12] Let $d$ be a randomly chosen divisor of 2016. Find the expected value of
+
+$$
+\frac{d^{2}}{d^{2}+2016}
+$$
+
+Proposed by: Henrik Boecken
+Answer: $\frac{1}{2}$
+Let $a b=2016$. Then
+
+$$
+\frac{a^{2}}{a^{2}+2016}+\frac{b^{2}}{b^{2}+2016}=\frac{a^{2}}{a^{2}+2016}+\frac{\left(\frac{2016}{a}\right)^{2}}{\left(\frac{2016}{a}\right)^{2}+2016}=\frac{a^{2}}{a^{2}+2016}+\frac{2016}{a^{2}+2016}=1
+$$
+
+Thus, every divisor $d$ pairs up with $\frac{2016}{d}$ to get 1 , so our desired expected value is $\frac{1}{2}$.
+24. [12] Consider an infinite grid of equilateral triangles. Each edge (that is, each side of a small triangle) is colored one of $N$ colors. The coloring is done in such a way that any path between any two nonadjecent vertices consists of edges with at least two different colors. What is the smallest possible value of $N$ ?
+
+Proposed by: Henrik Boecken
+Answer: 6
+
+Note that the condition is equivalent to having no edges of the same color sharing a vertex by just considering paths of length two. Consider a hexagon made out of six triangles. Six edges meet at the center, so $N \geq 6$. To prove $N=6$, simply use two colors for each of the three possible directions of an edge, and color edges of the same orientation alternatingly with different colors.
+25. [13] Chris and Paul each rent a different room of a hotel from rooms $1-60$. However, the hotel manager mistakes them for one person and gives "Chris Paul" a room with Chris's and Paul's room concatenated. For example, if Chris had 15 and Paul had 9, "Chris Paul" has 159. If there are 360 rooms in the hotel, what is the probability that "Chris Paul" has a valid room?
+Proposed by: Meghal Gupta
+Answer: $\frac{153}{1180}$
+There are $60 \cdot 59=3540$ total possible outcomes, and we need to count the number of these which concatenate into a number at most 60 . Of these, $9 \cdot 8$ result from both Chris and Paul getting one-digit room numbers. If Chris gets a two-digit number, then he must get a number at most 35 and Paul should get a one-digit room number, giving $(35-9) \cdot 9$ possibilties. If Chris gets a one-digit number, it must be 1,2 , or 3 . If Chris gets 1,2 or 3 , Paul can get any two-digit number from 10 to 60 to guarantee a valid room, giving $51 \cdot 3$ outcomes. The total number of correct outcomes is $72+51 * 3+26 * 9=459$, so the desired probability is $\frac{153}{1180}$.
+26. [13] Find the number of ways to choose two nonempty subsets $X$ and $Y$ of $\{1,2, \ldots, 2001\}$, such that $|Y|=1001$ and the smallest element of $Y$ is equal to the largest element of $X$.
+Proposed by: Allen Liu
+Answer: $2^{2000}$
+We claim that there is a bijection between pairs $(X, Y)$ and sets $S$ with at least 1001 elements. To get $S$ from $X$ and $Y$, take $S=X \cup Y$, which contains $Y$ and thus has at least 1001 elements. To form $(X, Y)$ from $S$, make $Y$ the largest 1001 elements of $S$, and make $X$ everything except the largest 1000 elements of $S$. Therefore we need to count the number of subsets of $\{1,2, \ldots, 2001\}$ with at least 1001 elements. For every subset of $\{1,2, \ldots, 2001\}$, either it or its complement has at least 1001 elements, so number of possible subsets is $\frac{1}{2} \cdot 2^{2001}=2^{2000}$.
+27. [13] Let $r_{1}, r_{2}, r_{3}, r_{4}$ be the four roots of the polynomial $x^{4}-4 x^{3}+8 x^{2}-7 x+3$. Find the value of
+
+$$
+\frac{r_{1}^{2}}{r_{2}^{2}+r_{3}^{2}+r_{4}^{2}}+\frac{r_{2}^{2}}{r_{1}^{2}+r_{3}^{2}+r_{4}^{2}}+\frac{r_{3}^{2}}{r_{1}^{2}+r_{2}^{2}+r_{4}^{2}}+\frac{r_{4}^{2}}{r_{1}^{2}+r_{2}^{2}+r_{3}^{2}}
+$$
+
+Proposed by: Henrik Boecken
+Answer: -4
+Add 1 to each fraction to get
+
+$$
+\frac{r_{1}^{2}+r_{2}^{2}+r_{3}^{2}+r_{4}^{2}}{r_{2}^{2}+r_{3}^{2}+r_{4}^{2}}+\frac{r_{1}^{2}+r_{2}^{2}+r_{3}^{2}+r_{4}^{2}}{r_{1}^{2}+r_{3}^{2}+r_{4}^{2}}+\frac{r_{1}^{2}+r_{2}^{2}+r_{3}^{2}+r_{4}^{2}}{r_{1}^{2}+r_{2}^{2}+r_{4}^{2}}+\frac{r_{1}^{2}+r_{2}^{2}+r_{3}^{2}+r_{4}^{2}}{r_{1}^{2}+r_{2}^{2}+r_{3}^{2}}
+$$
+
+This seems like a difficult problem until one realizes that
+
+$$
+r_{1}^{2}+r_{2}^{2}+r_{3}^{2}+r_{4}^{2}=\left(r_{1}+r_{2}+r_{3}+r_{4}\right)^{2}-2\left(r_{1} r_{2}+r_{1} r_{3}+r_{1} r_{4}+r_{2} r_{3}+r_{2} r_{4}+r_{3} r_{4}\right)=4^{2}-2 \cdot 8=0
+$$
+
+Thus, our current expression is 0 . Noting that we added 4 , the original value had to be -4 .
+28. [15] The numbers $1-10$ are written in a circle randomly. Find the expected number of numbers which are at least 2 larger than an adjacent number.
+Proposed by: Shyam Narayanan
+
+## Answer: $\frac{17}{3}$
+
+For $1 \leq i \leq 10$, let $X_{i}$ be the random variable that is 1 if the $i$ in the circle is at least 2 larger than one of its neighbors, and 0 otherwise. The random variable representing number of numbers that are at least 2 larger than one of their neighbors is then just $X_{1}+X_{2}+\cdots+X_{10}$. The expected value $\mathbb{E}\left[X_{1}+X_{2}+\cdots+X_{10}\right]$ is equal to $\mathbb{E}\left[X_{1}\right]+\mathbb{E}\left[X_{2}\right]+\cdots+\mathbb{E}\left[X_{10}\right]$ by the linearity of expectation, so it suffices to compute $\mathbb{E}\left[X_{i}\right]$ for all $1 \leq i \leq 10$.
+
+By the definition of expected value, $\mathbb{E}\left[X_{i}\right]=1 \cdot P$ (the $i$ is at least 2 larger than one of its neighbors $)+0$. $P($ it is not at least 2 larger than either of its neighbors $)=P($ the $i$ is at least 2 larger than one of its neighbors $)=$ $1-P$ (the $i$ is at most 1 larger than both of its neighbors). For the last probability, $i$ 's neighbors must be drawn from the set $\{\max (1, i-1), \max (1, i-1)+1, \ldots, 10\}$, excluding $i$ itself. This set has $10-\max (1, i-1)$ elements, so there are a total of $\binom{10-\max (1, i-1)}{2}$ sets of two neighbors for $i$ that satisfy the condition, out of a total of $\binom{9}{2}$ possible sets of two neighbors from all of the numbers that are not $i$. The last probability is then $\frac{\binom{10-\max (1, i-1)}{2}}{\binom{9}{2}}$, so $\mathbb{E}\left[X_{i}\right]=1-\frac{\binom{10-\max (1, i-1)}{2}}{\binom{9}{2}}$.
+The final sum we wish to calculate then becomes $\left(1-\frac{\binom{9}{2}}{\binom{9}{2}}\right)+\left(1-\frac{\binom{9}{2}}{\binom{9}{2}}\right)+\left(1-\frac{\binom{8}{2}}{\binom{9}{2}}\right)+\left(1-\frac{\binom{7}{2}}{\binom{9}{2}}\right)+\cdots+\left(1-\frac{\binom{1}{2}}{\binom{9}{2}}\right)=$ $0+0+\left(1-\frac{28}{36}\right)+\left(1-\frac{21}{36}\right)+\cdots+(1-0)=\frac{17}{3}$.
+29. [15] We want to design a new chess piece, the American, with the property that (i) the American can never attack itself, and (ii) if an American $A_{1}$ attacks another American $A_{2}$, then $A_{2}$ also attacks $A_{1}$. Let $m$ be the number of squares that an American attacks when placed in the top left corner of an 8 by 8 chessboard. Let $n$ be the maximal number of Americans that can be placed on the 8 by 8 chessboard such that no Americans attack each other, if one American must be in the top left corner. Find the largest possible value of $m n$.
+Proposed by: Kevin Yang
+Answer: 1024
+Since one of the Americans must be in the top left corner, that eliminates $m$ squares from consideration for placing additional Americans. So $m+n$ is at most 64, which implies $m n$ can be at most 1024. To achieve 1024, we can color a chessboard the normal way, and say that an American attacks all squares of the opposite color. Then the American in the top left corner attacks the 32 squares of the opposite color, and placing all Americans on the squares of the same color as the top-left corner guarantees no Americans attack each other.
+30. [15] On the blackboard, Amy writes 2017 in base- $a$ to get $133201_{a}$. Betsy notices she can erase a digit from Amy's number and change the base to base-b such that the value of the the number remains the same. Catherine then notices she can erase a digit from Betsy's number and change the base to base- $c$ such that the value still remains the same. Compute, in decimal, $a+b+c$.
+Proposed by: Daniel Qu
+Answer: 22
+$2017=133201_{4}=13201_{6}=1201_{12}$
+31. $[\mathbf{1 7}]$ Define a number to be an anti-palindrome if, when written in base 3 as $a_{n} a_{n-1} \ldots a_{0}$, then $a_{i}+a_{n-i}=$ 2 for any $0 \leq i \leq n$. Find the number of anti-palindromes less than $3^{12}$ such that no two consecutive digits in base 3 are equal.
+Proposed by: Shyam Narayanan
+Answer: 126
+Note once the middle digit/pair of digits is determined, it suffices to choose the digits in the left half of the number and ensure no pair of consecutive digits are equal. For a number with an even number of digits, the middle pair is 02 or 20 while for a number with an odd number of digits, the middle digit is 1 . We can now count recursively.
+
+Let $a_{n}$ be the number of ways to choose $n$ digits no two of which are consecutive and equal such that the leading digit is nonzero and the ending digit is 1 . Let $b_{n}$ be the number ways to do the same such that the ending digit is 0 or 2 .
+Note $a_{n}=b_{n-1}$. Also $b_{n}=b_{n-1}+2 a_{n-1}$.
+Solving for the terms of the sequence, they are $a_{1}=1, a_{2}=b_{1}=1, a_{3}=b_{2}=3, a_{4}=b_{3}=5, a_{5}=b_{4}=$ $11, a_{6}=b_{5}=21, b_{6}=43$. Therefore, there are 43 twelve-digit numbers satisfying the condition, 21 eleven-digit numbers, 21 ten-digit numbers.... and 1 one-digit number. The sum of these values gives us a final answer of 126
+32. [17] Let $C_{k, n}$ denote the number of paths on the Cartesian plane along which you can travel from $(0,0)$ to $(k, n)$, given the following rules: 1) You can only travel directly upward or directly rightward 2) You can only change direction at lattice points 3) Each horizontal segment in the path must be at most 99 units long.
+Find
+
+$$
+\sum_{j=0}^{\infty} C_{100 j+19,17}
+$$
+
+Proposed by: Saranesh Prembabu
+Answer: $100^{17}$
+If we are traveling from $(0,0)$ to $(n, 17)$, we first travel $x_{0}$ rightwards, then up one, then $x_{1}$ rightwards, then up one, $\ldots$, until we finally travel $x_{17}$ rightwards. $x_{0}, \ldots, x_{17}$ are all at most 99 by our constraint, but can equal 0 . Given that $x_{0}, \ldots, x_{16}$ are fixed, there is exactly one way to choose $x_{17}$ so that $x_{0}+\ldots+x_{17}$ is congruent to $19 \bmod 100$. Then, this means that the sum equals the total number of ways to choose $x_{0}, \ldots, x_{16}$, which equals $100^{17}=10^{34}$.
+33. [17] Camille the snail lives on the surface of a regular dodecahedron. Right now he is on vertex $P_{1}$ of the face with vertices $P_{1}, P_{2}, P_{3}, P_{4}, P_{5}$. This face has a perimeter of 5 . Camille wants to get to the point on the dodecahedron farthest away from $P_{1}$. To do so, he must travel along the surface a distance at least $L$. What is $L^{2}$ ?
+
+Proposed by: Saranesh Prembabu
+Answer: $\frac{17+7 \sqrt{5}}{2}$
+Consider the net of the dodecahedron. It suffices to look at three pentagons $A B C D E, E D F G H$, and $G F I J K$, where $A J=L$. This can be found by the law of cosines on triangle $A E J$. We have $A E=1$, $E J=\tan 72^{\circ}$, and $\angle A E J=162^{\circ}$. Thus $L^{2}=1+\tan ^{2} 72^{\circ}+2 \cdot \tan 72^{\circ} \cdot \cos 18^{\circ}=\frac{17+7 \sqrt{5}}{2}$
+34. [20] Find the sum of the ages of everyone who wrote a problem for this year's HMMT November contest. If your answer is $X$ and the actual value is $Y$, your score will be $\max (0,20-|X-Y|)$
+Proposed by: Allen Liu
+Answer: 258
+There was one problem for which I could not determine author information, so I set the author as one of the problem czars at random. Then, I ran the following command on a folder containing TeX solutions files to all four contests:
+
+```
+evan@ArchMega ~/Downloads/November
+$ grep --no-filename "Proposed by: " *.tex | sort | uniq -c
+ 15 {\em Proposed by: Allen Liu }
+ 1 {\em Proposed by: Brice Huang }
+ 2 {\em Proposed by: Christopher Shao }
+ 2 {\em Proposed by: Daniel Qu }
+ 21 {\em Proposed by: Eshaan Nichani }
+```
+
+```
+3 {\em Proposed by: Evan Chen }
+{\em Proposed by: Henrik Boecken }
+{\em Proposed by: Kevin Sun }
+{\em Proposed by: Kevin Yang }
+{\em Proposed by: Meghal Gupta }
+{\em Proposed by: Rachel Zhang }
+{\em Proposed by: Sam Korsky }
+{\em Proposed by: Saranesh Prembabu }
+{\em Proposed by: Shyam Narayanan }
+```
+
+This gave the counts of problem proposals; there were 14 distinct authors of problems for November 2016. Summing their ages (concealed for privacy) gives 258 .
+35. [20] Find the total number of occurrences of the digits $0,1 \ldots, 9$ in the entire guts round. If your answer is $X$ and the actual value is $Y$, your score will be $\max \left(0,20-\frac{|X-Y|}{2}\right)$
+Proposed by: Allen Liu
+Answer: 559
+To compute the answer, I extracted the flat text from the PDF file and ran word-count against the list of digit matches.
+
+```
+evan@ArchMega ~/Downloads/November
+$ pdftotext HMMTNovember2016GutsTest.pdf guts-test-text.txt
+evan@ArchMega ~/Downloads/November
+$ cat guts-test-text.txt | egrep "[0-9]" --only-matching | wc -l
+559
+```
+
+36. [20] Find the number of positive integers less than 1000000 which are less than or equal to the sum of their proper divisors. If your answer is $X$ and the actual value is $Y$, your score will be $\max \left(0,20-80\left|1-\frac{X}{Y}\right|\right)$ rounded to the nearest integer.
+Proposed by: Allen Liu
+Answer: 247548
+```
+N = 1000000
+s = [0] * N
+ans = 0
+for i in range(1, N):
+if i <= s[i]:
+ans += 1
+for j in range(i + i, N, i):
+s[j] += i
+print(ans)
+```
+
diff --git a/HarvardMIT/md/en-201-2016-nov-team-solutions.md b/HarvardMIT/md/en-201-2016-nov-team-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..067caf2b47000c384627cb4504909a6a0d55e365
--- /dev/null
+++ b/HarvardMIT/md/en-201-2016-nov-team-solutions.md
@@ -0,0 +1,113 @@
+# HMMT November 2016
+
+## November 12, 2016
+
+## Team
+
+1. [3] Two circles centered at $O_{1}$ and $O_{2}$ have radii 2 and 3 and are externally tangent at $P$. The common external tangent of the two circles intersects the line $O_{1} O_{2}$ at $Q$. What is the length of $P Q$ ?
+
+Proposed by: Eshaan Nichani
+Answer: 12
+Let the common external tangent intersect the circles centered at $O_{1}, O_{2}$ at $X, Y$ respectively. Then $\frac{O_{2} Q}{O_{1} Q}=\frac{O Y}{O X}=\frac{3}{2}$, so $\frac{O_{1} O_{2}}{O_{1} Q}=\frac{O_{2} Q-O_{1} Q}{O_{1} Q}=\frac{1}{2}$. Since $O_{1} O_{2}=2+3=5, O_{1} Q=10$ and hence $P Q=O_{1} Q+O_{1} P=12$.
+2. [3] What is the smallest possible perimeter of a triangle whose side lengths are all squares of distinct positive integers?
+Proposed by: Eshaan Nichani
+Answer: 77
+There exist a triangle with side lengths $4^{2}, 5^{2}, 6^{2}$, which has perimeter 77 . If the sides have lengths $a^{2}, b^{2}, c^{2}$ with $0c^{2}$ by the triangle inequality. Therefore $(b-1)^{2}+b^{2} \geq$ $a^{2}+b^{2}>c^{2} \geq(b+1)^{2}$. Solving this inequality gives $b>4$. If $b \geq 6$, then $a^{2}+b^{2}+c^{2} \geq 6^{2}+7^{2}>7 \overline{7}$. If $b=5$, then $c \geq 7$ is impossible, while $c=6$ forces $a=4$, which gives a perimeter of 77 .
+3. [3] Complex number $\omega$ satisfies $\omega^{5}=2$. Find the sum of all possible values of
+
+$$
+\omega^{4}+\omega^{3}+\omega^{2}+\omega+1
+$$
+
+Proposed by: Henrik Boecken
+
+## Answer: 5
+
+The value of $\omega^{4}+\omega^{3}+\omega^{2}+\omega+1=\frac{\omega^{5}-1}{\omega-1}=\frac{1}{\omega-1}$. The sum of these values is therefore the sum of $\frac{1}{\omega-1}$ over the five roots $\omega$. Substituting $z=\omega-1$, we have that $(z+1)^{5}=2$, so $z^{5}+5 z^{4}+10 z^{3}+$ $10 z^{2}+5 z-1=0$. The sum of the reciprocals of the roots of this equation is $-\frac{5}{-1}=5$ by Vieta's.
+4. [5] Meghal is playing a game with 2016 rounds $1,2, \cdots, 2016$. In round $n$, two rectangular double-sided mirrors are arranged such that they share a common edge and the angle between the faces is $\frac{2 \pi}{n+2}$. Meghal shoots a laser at these mirrors and her score for the round is the number of points on the two mirrors at which the laser beam touches a mirror. What is the maximum possible score Meghal could have after she finishes the game?
+Proposed by: Rachel Zhang
+Answer: 1019088
+Let points $O, A_{1}, A_{2}$ lie in a plane such that $\angle A_{1} O A_{2}=\frac{2 \pi}{n+2}$. We represent the mirrors as line segments extending between $O$ and $A_{1}$, and $O$ and $A_{2}$. Also let points $A_{3}, A_{4}, \cdots, A_{n+2}$ lie in the plane such that $A_{i+1}$ is the reflection of $A_{i-1}$ over $O A_{i}$.
+If Meghal shoots a laser along line $l$ such that the first point of contact with a mirror is along $O A_{2}$, the next point of contact, if it exists, is the point on $O A_{1}$ that is a reflection of the intersection of $l$ with $O A_{3}$. If we continue this logic, we find that the maximum score for round $n$ is equal to the maximum number of intersection points between $l$ and $O A_{i}$ for some $i$. We do casework on whether $n$ is even or odd. If $n$ is even, there are at most $\frac{n+2}{2}$ spokes such that $l$ can hit $O A_{i}$, and if $n$ is odd, there are at most $\frac{n+3}{2}$ such spokes. Then we must sum $2+2+3+3+\cdots+1009+1009=1009 \cdot 1010-1-1=1019088$.
+5. [5] Allen and Brian are playing a game in which they roll a 6 -sided die until one of them wins. Allen wins if two consecutive rolls are equal and at most 3 . Brian wins if two consecutive rolls add up to 7 and the latter is at most 3 . What is the probability that Allen wins?
+Proposed by: Eshaan Nichani
+Answer: $5 / 12$
+Note that at any point in the game after the first roll, the probability that Allen wins depends only on the most recent roll, and not on any rolls before that one. So we may define $p$ as the probability that Allen wins at any point in the game, given that the last roll was a 1,2 , or 3 , and $q$ as the probability that he wins given that the last roll was a 4,5 , or 6 .
+Suppose at some point, the last roll was $r_{1} \in\{1,2,3\}$, and the next roll is $r_{2} \in\{1,2,3,4,5,6\}$. By the definition of $p$, Allen wins with probability $p$. Furthermore, if $r_{2}=r_{1}$, which happens with probability $\frac{1}{6}$, Allen wins. If $r_{2} \in\{1,2,3\}$ but $r_{2} \neq r_{1}$, which happens with probability $\frac{2}{6}$, neither Allen nor Brian wins, so they continue playing the game, now where the last roll was $r_{2}$. In this case, Allen wins with probability $p$. If $r_{2} \in\{4,5,6\}$, which happens with probability $\frac{3}{6}$, neither Allen nor Brian wins, so they continue playing, now where the last roll was $r_{2}$. In this case, Allen wins with probability $q$. Hence, the probability that Allen wins in this case can be expressed as $\frac{1}{6}+\frac{2}{6} p+\frac{3}{6} q$, and thus
+
+$$
+p=\frac{1}{6}+\frac{2}{6} p+\frac{3}{6} q
+$$
+
+By a similar analysis for $q$, we find that
+
+$$
+q=\frac{1}{6} \cdot 0+\frac{2}{6} p+\frac{3}{6} q
+$$
+
+Solving, we get $p=\frac{1}{2}$ and $q=\frac{1}{3}$. Allen wins with probability $p=\frac{1}{2}$ if the first roll is 1,2 , or 3 , and he wins with probability $q=\frac{1}{3}$ if the first roll is 4,5 , or 6 . We conclude that the overall probability that he wins the game is $\frac{1}{2} p+\frac{1}{2} q=\frac{5}{12}$.
+6. [5] Let $A B C$ be a triangle with $A B=5, B C=6$, and $A C=7$. Let its orthocenter be $H$ and the feet of the altitudes from $A, B, C$ to the opposite sides be $D, E, F$ respectively. Let the line $D F$ intersect the circumcircle of $A H F$ again at $X$. Find the length of $E X$.
+
+Proposed by: Allen Liu
+
+## Answer: $\frac{190}{49}$
+
+Since $\angle A F H=\angle A E H=90^{\circ}, E$ is on the circumcircle of $A H F$. So $\angle X E H=\angle H F D=\angle H B D$, which implies that $X E \| B D$. Hence $\frac{E X}{B D}=\frac{E Y}{Y B}$. Let $D F$ and $B E$ intersect at $Y$. Note that $\angle E D Y=180^{\circ}-\angle B D F-\angle C D E=180^{\circ}-2 \angle A$, and $\angle B D Y=\angle A$. Applying the sine rule to $E Y D$ and $B Y D$, we get
+
+$$
+\frac{E Y}{Y B}=\frac{E D}{B D} \cdot \frac{\sin \angle E D Y}{\sin \angle B D Y}=\frac{E D}{B D} \cdot \frac{\sin 2 \angle A}{\sin \angle A}=\frac{E D}{B D} \cdot 2 \cos \angle A
+$$
+
+Next, letting $x=C D$ and $y=A E$, by Pythagoras we have
+
+$$
+\begin{aligned}
+& A B^{2}-(6-x)^{2}=A D^{2}=A C^{2}-x^{2} \\
+& B C^{2}-(7-y)^{2}=B E^{2}=B A^{2}-y^{2}
+\end{aligned}
+$$
+
+Solving, we get $x=5, y=\frac{19}{7}$. Drop the perpendicular from $E$ to $D C$ at $Z$. Then $E D \cos \angle A=$ $E D \cos \angle E D Z=D Z$. But $A D \| E Z$, so $D Z=\frac{A E}{A C} \cdot D C=\frac{95}{49}$. Therefore
+
+$$
+E X=\frac{E Y}{Y B} \cdot B D=2 E D \cos \angle A=2 D Z=\frac{190}{49}
+$$
+
+7. [6] Rachel has two indistinguishable tokens, and places them on the first and second square of a $1 \times 6$ grid of squares, She can move the pieces in two ways:
+
+- If a token has free square in front of it, then she can move this token one square to the right
+- If the square immediately to the right of a token is occupied by the other token, then she can "leapfrog" the first token; she moves the first token two squares to the right, over the other token, so that it is on the square immediately to the right of the other token.
+
+If a token reaches the 6th square, then it cannot move forward any more, and Rachel must move the other one until it reaches the 5th square. How many different sequences of moves for the tokens can Rachel make so that the two tokens end up on the 5 th square and the 6 th square?
+Proposed by: Christopher Shao
+Answer: 42
+We put a marker on $(i, j)$ when a token is on $i$ th and $j$ th square and $i>j$. When the token in front/behind moves one step forward to a blank square, move the marker rightward/upward one unit correspondingly. When a "leapfrog" happens, the marker moves from $(x-1, x)$ to $(x, x+1)$. We can translate this movement into: 1. move the marker upward to $(x, x) ; 2$. move the marker rightward to $(x, x+1)$. Thus, we set up a lattice path way from $(2,1)$ to $(6,5)$ staying under $y=x$. This is a bijection since every intersection of the path way and $y=x$ indicates a "leapfrog". According to the definition of Catalan Number, the answer is the number of such lattice path ways, which is $C_{5}=42$.
+8. [6] Alex has an $20 \times 16$ grid of lightbulbs, initially all off. He has 36 switches, one for each row and column. Flipping the switch for the $i$ th row will toggle the state of each lightbulb in the $i$ th row (so that if it were on before, it would be off, and vice versa). Similarly, the switch for the $j$ th column will toggle the state of each bulb in the $j$ th column. Alex makes some (possibly empty) sequence of switch flips, resulting in some configuration of the lightbulbs and their states. How many distinct possible configurations of lightbulbs can Alex achieve with such a sequence? Two configurations are distinct if there exists a lightbulb that is on in one configuration and off in another.
+Proposed by: Christopher Shao
+Answer: $2^{35}$
+The switch flip operations are commutative, so for any given sequence of switch flips $S$, we get the same configuration regardless of the order we do them in. We can arrange the switch flips so that all of the flips of the same switch happen consecutively. Furthermore, two consecutive flips of the same switch leave the configuration unchanged, so we can remove them, resulting in a sequence of switch flips $S^{\prime}$ that involves flipping a switch for a row or column at most once that achieves the same configuration as $S$. The order of the flips in $S^{\prime}$ also doesn't matter, so we can treat $S^{\prime}$ as a set of switches that are flipped to produce the same configuration as $S$.
+
+The desired number is then equal to the number of distinct configurations that can be obtained by flipping exactly the switches in some subset $S^{\prime}$ of the set of all of the switches. We claim that if $S_{1}$ and $S_{2}$ are distinct sets of switches that result in the same configuration of lights, then $S_{1}$ and $S_{2}$ are complements. Indeed, without loss of generality, suppose that the first row's switch is in $S_{1}$ and that it isn't in $S_{2}$. In order to have the same configuration of lights in the first row, we must have that every column switch is in $S_{1}$ if and only if it isn't in $S_{2}$. Applying the same argument to the first column yields that every row switch is in $S_{1}$ if and only if it isn't in $S_{2}$, and the claim follows. Thus, for every set of switches, there is exactly one other set that attains the same configuration as it, namely its complement. There are $2^{m+n}$ sets of switches possible, and so the total number of possible configurations is $2^{m+n} / 2=2^{m+n-1}$.
+9. [7] A cylinder with radius 15 and height 16 is inscribed in a sphere. Three congruent smaller spheres of radius $x$ are externally tangent to the base of the cylinder, externally tangent to each other, and internally tangent to the large sphere. What is the value of $x$ ?
+
+## Proposed by: Eshaan Nichani
+
+Answer: $\square$
+Let $O$ be the center of the large sphere, and let $O_{1}, O_{2}, O_{3}$ be the centers of the small spheres. Consider $G$, the center of equilateral $\triangle O_{1} O_{2} O_{3}$. Then if the radii of the small spheres are $r$, we have that $O G=8+r$ and $O_{1} O_{2}=O_{2} O_{3}=O_{3} O_{1}=2 r$, implying that $O_{1} G=\frac{2 r}{\sqrt{3}}$. Then $O O_{1}=\sqrt{O G^{2}+O O_{1}^{2}}=$ $\sqrt{(8+r)^{2}+\frac{4}{3} r^{2}}$. Now draw the array $O O_{1}$, and suppose it intersects the large sphere again at $P$. Then $P$ is the point of tangency between the large sphere and the small sphere with center $O_{1}$, so $O P=\sqrt{15^{2}+8^{2}}=17=O O_{1}+O_{1} P=\sqrt{(8+r)^{2}+\frac{4}{3} r^{2}}+r$. We rearrange this to be
+
+$$
+\begin{aligned}
+17-r & =\sqrt{(8+r)^{2}+\frac{4}{3} r^{2}} \\
+\Longleftrightarrow 289-34 r+r^{2} & =\frac{7}{3} r^{2}+16 r+64 \\
+\Longleftrightarrow \frac{4}{3} r^{2}+50 r-225 & =0 \\
+\Longrightarrow r & =\frac{-50 \pm \sqrt{50^{2}+4 \cdot \frac{4}{3} \cdot 225}}{2 \cdot \frac{4}{3}} \\
+& =\frac{15 \sqrt{37}-75}{4} .
+\end{aligned}
+$$
+
+10. [7] Determine the largest integer $n$ such that there exist monic quadratic polynomials $p_{1}(x), p_{2}(x)$, $p_{3}(x)$ with integer coefficients so that for all integers $i \in[1, n]$ there exists some $j \in[1,3]$ and $m \in \mathbb{Z}$ such that $p_{j}(m)=i$.
+Proposed by: Eshaan Nichani
+Answer: 9
+The construction for $n=9$ can be achieved with the polynomials $x^{2}+x+1, x^{2}+x+2$, and $x^{2}+5$.
+First we consider what kinds of polynomials we can have. Let $p(x)=(x+h)^{2}+k . h$ is either an integer or half an integer. Let $k=0$. If $h$ is an integer then $p(x)$ hits the perfect squares $0,1,4,9$, etc. If $h$ is half an integer, then let $k=1 / 4$. Then $p(x)$ hits the product of two consecutive integers, i.e. 0 , $2,6,12$, etc.
+Assume there is a construction for $n=10$. In both of the cases above, the most a polynomial can hit out of 10 is 4 , in the $0,1,4,9$ case. Thus $p_{1}$ must hit $1,2,5,10$, and $p_{2}$ and $p_{3}$ hit 3 integers each, out of $3,4,6,7,8,9$. The only ways we can hit 3 out of 7 consecutive integers is with the sequences $0,2,6$ or $0,1,4$. The only way a $0,2,6$ works is if it hits 3,5 , and 9 , which doesn't work since 5 was hit by $p_{2}$. Otherwise, $p_{2}$ is $0,1,4$, which doesn't work as $p_{2}$ hits 3,4 , and 7 , and $p_{3}$ must hit 6,8 , and 9 , which is impossible. Thus no construction for $n=10$ exists.
diff --git a/HarvardMIT/md/en-201-2016-nov-thm-solutions.md b/HarvardMIT/md/en-201-2016-nov-thm-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..82974283a5d6ecf1e0ce5430a54aaf432e1eedb3
--- /dev/null
+++ b/HarvardMIT/md/en-201-2016-nov-thm-solutions.md
@@ -0,0 +1,63 @@
+## HMMT November 2016
+
+## November 12, 2016
+
+## Theme Round
+
+1. DeAndre Jordan shoots free throws that are worth 1 point each. He makes $40 \%$ of his shots. If he takes two shots find the probability that he scores at least 1 point.
+Proposed by: Allen Liu
+Answer: $\frac{16}{25}$
+We want to find the probability of making at least one shot. The probability he makes no shots is $\left(\frac{3}{5}\right)^{2}$, so the probability of making at least one is $1-\left(\frac{3}{5}\right)^{2}=\frac{16}{25}$.
+2. Point $P_{1}$ is located 600 miles West of point $P_{2}$. At 7:00 AM a car departs from $P_{1}$ and drives East at a speed of 50 miles per hour. At 8:00 AM another car departs from $P_{2}$ and drives West at a constant speed of $x$ miles per hour. If the cars meet each other exactly halfway between $P_{1}$ and $P_{2}$, what is the value of $x$ ?
+Proposed by: Eshaan Nichani
+Answer: 60
+Each car meets having traveled 300 miles. Therefore the first car traveled for $300 / 50=6$ hours, and so the second car traveled for 5 hours. The second car must have traveled $300 / 5=60$ miles per hour.
+3. The three points $A, B, C$ form a triangle. $A B=4, B C=5 A C=6$. Let the angle bisector of $\angle A$ intersect side $B C$ at $D$. Let the foot of the perpendicular from $B$ to the angle bisector of $\angle A$ be $E$. Let the line through $E$ parallel to $A C$ meet $B C$ at $F$. Compute $D F$.
+Proposed by: Allen Liu
+Answer: $1 / 2$
+Since $A D$ bisects $\angle A$, by the angle bisector theorem $\frac{A B}{B D}=\frac{A C}{C D}$, so $B D=2$ and $C D=3$. Extend $B E$ to hit $A C$ at $X$. Since $A E$ is the perpendicular bisector of $B X, A X=4$. Since $B, E, X$ are collinear, applying Menelaus' Theorem to the triangle $A D C$, we have
+
+$$
+\frac{A E}{E D} \cdot \frac{D B}{B C} \cdot \frac{C X}{X A}=1
+$$
+
+This implies that $\frac{A E}{E D}=5$, and since $E F \| A C, \frac{D F}{D C}=\frac{D E}{D A}$, so $D F=\frac{D C}{6}=\frac{1}{2}$.
+4. A positive integer is written on each corner of a square such that numbers on opposite vertices are relatively prime while numbers on adjacent vertices are not relatively prime. What is the smallest possible value of the sum of these 4 numbers?
+Proposed by: Eshaan Nichani
+Answer: 60
+Two opposite vertices are relatively prime, but they both share a factor with their common neighbor. So that common neighbor must have two prime factors. So each of the 4 numbers has two prime factors, which are not shared with the opposite vertex. Moreover, it suffices to choose the vertices to be the numbers $a b, b c, c d, d a$ for some prime numbers $a, b, c, d$. It's clear that we should choose them to be the smallest primes $2,3,5,7$ in some order. The order that minimizes the sum of all of the numbers gives $14,10,15,21$ for a sum of 60 .
+5. Steph Curry is playing the following game and he wins if he has exactly 5 points at some time. Flip a fair coin. If heads, shoot a 3 -point shot which is worth 3 points. If tails, shoot a free throw which is worth 1 point. He makes $\frac{1}{2}$ of his 3 -point shots and all of his free throws. Find the probability he will win the game. (Note he keeps flipping the coin until he has exactly 5 or goes over 5 points)
+
+Proposed by: Allen Liu
+Answer: $\frac{140}{243}$
+If he misses the shot, then the state of the game is the same as before he flipped the coin. Since the probability of making a free throw is $\frac{1}{2}$ and the probability of making a 3 -point shot is $\frac{1}{4}$. Therefore, given that he earns some point, the probability it is a 3 -point shot is $\frac{1}{3}$. The possible ways of earning points are $11111,113,131$, and 311 , which have probabilities $\frac{32}{243}, \frac{4}{27}, \frac{4}{27}$, and $\frac{4}{27}$, which sum to $\frac{140}{243}$.
+6. Let $P_{1}, P_{2}, \ldots, P_{6}$ be points in the complex plane, which are also roots of the equation $x^{6}+6 x^{3}-216=0$. Given that $P_{1} P_{2} P_{3} P_{4} P_{5} P_{6}$ is a convex hexagon, determine the area of this hexagon.
+Proposed by: Eshaan Nichani
+Answer: $9 \sqrt{3}$
+Factor $x^{6}+6 x^{3}-216=\left(x^{3}-12\right)\left(x^{3}+18\right)$. This gives us 6 points equally spaced in terms of their angles from the origin, alternating in magnitude between $\sqrt[3]{12}$ and $\sqrt[3]{18}$. This means our hexagon is composed of 6 triangles, each with sides of length $\sqrt[3]{12}$ and $\sqrt[3]{18}$ and with a 60 degree angle in between them. This yields the area of each triangle as $\frac{3 \sqrt{3}}{2}$, so the total area of the hexagon is $9 \sqrt{3}$.
+7. Seven lattice points form a convex heptagon with all sides having distinct lengths. Find the minimum possible value of the sum of the squares of the sides of the heptagon.
+Proposed by: Allen Liu
+Answer: 42
+Consider the vectors corresponding to the sides of the heptagon, and call them $\left[x_{i}, y_{i}\right]$ for $i$ between 1 and 7. Then since $\sum x_{i}=\sum y_{i}=0$, and $a^{2}$ has the same parity as $a$, we have that $\sum x_{i}^{2}+y_{i}^{2}$ must be an even number. A side length of a lattice valued polygon must be expressible as $\sqrt{a^{2}+b^{2}}$, so the smallest possible values are $\sqrt{1}, \sqrt{2}, \sqrt{4}, \sqrt{5}, \sqrt{8}, \sqrt{9}, \sqrt{10}$. However, using the seven smallest lengths violates the parity constraint. If we try $\sqrt{13}$, we indeed can get a heptagon with lengths $\sqrt{1}, \sqrt{2}, \sqrt{4}, \sqrt{5}, \sqrt{8}, \sqrt{9}, \sqrt{13}$. One example is the heptagon $(0,0),(3,0),(5,1),(6,2),(3,4),(2,4),(0,2)$, and its sum of squares of side lengths is $1+2+4+5+8+9+13=42$.
+8. Let $P_{1} P_{2} \ldots P_{8}$ be a convex octagon. An integer $i$ is chosen uniformly at random from 1 to 7 , inclusive. For each vertex of the octagon, the line between that vertex and the vertex $i$ vertices to the right is painted red. What is the expected number times two red lines intersect at a point that is not one of the vertices, given that no three diagonals are concurrent?
+Proposed by: Eshaan Nichani
+Answer: $\frac{54}{7}$
+If $i=1$ or $i=7$, there are 0 intersections. If $i=2$ or $i=6$ there are 8 . If $i=3$ or $i=5$ there are 16 intersections. When $i=4$ there are 6 intersections (since the only lines drawn are the four long diagonals).
+Thus the final answer is $\frac{8+16+6+16+8}{7}=\frac{54}{7}$
+9. The vertices of a regular nonagon are colored such that 1 ) adjacent vertices are different colors and 2) if 3 vertices form an equilateral triangle, they are all different colors.
+Let $m$ be the minimum number of colors needed for a valid coloring, and $n$ be the total number of colorings using $m$ colors. Determine $m n$. (Assume each vertex is distinguishable.)
+
+## Proposed by: Eshaan Nichani
+
+Answer: 54
+
+It's clear that $m$ is more than 2 since it's impossible to alternate the color of the vertices without having two of the same color adjacent (since the graph is not bipartite). However, it's possible to use 3 colors. Number the vertices 1 through 9 in order and let the colors be $A, B, C$. Coloring the vertices in the order $B C B C A C A B A$ gives a configuration that works, so $m$ is 3 . To determine $n$, we can partition the nonagon into three equilateral triangles. Vertices $1,4,7$ must be different colors, which we can choose in $3!=6$ ways. Suppose WLOG that they're $A, B, C$ respectively. Then we look at vertices $2,5,8$. Vertex 2 can be colored $B$ or $C$. If 2 is $B$, then vertex 8 must be $A$, and vertex 5 must be $C$. In this case there are two ways to color the remaining vertices $3,6,9$. Otherwise, if vertex 2 is $C$, then vertex 5 must be $A$, and vertex 8 must be $B$. This gives us only 1 possible coloring for the remaining three vertices. So $n$ is $6(2+1)=18$. So our answer is $m n=54$.
+10. We have 10 points on a line $A_{1}, A_{2} \cdots A_{10}$ in that order. Initially there are $n$ chips on point $A_{1}$. Now we are allowed to perform two types of moves. Take two chips on $A_{i}$, remove them and place one chip on $A_{i+1}$, or take two chips on $A_{i+1}$, remove them, and place a chip on $A_{i+2}$ and $A_{i}$. Find the minimum possible value of $n$ such that it is possible to get a chip on $A_{10}$ through a sequence of moves.
+Proposed by: Allen Liu
+Answer: 46
+We claim that $n=46$ is the minimum possible value of $n$. As having extra chips cannot hurt, it is always better to perform the second operation than the first operation, except on point $A_{1}$. Assign the value of a chip on point $A_{i}$ to be $i$. Then the total value of the chips initially is $n$. Furthermore, both types of operations keep the total values of the chips the same, as $2 \cdot 1=2$ and $i+(i+2)=2 \cdot(i+1)$.
+
+When $n=46$, we claim that any sequence of these moves will eventually lead to a chip reaching $A_{10}$. If, for the sake of contradiction, that there was a way to get stuck with no chip having reached $A_{10}$, then there could only be chips on $A_{1}$ through $A_{9}$, and furthermore at most one chip on each. The total value of these chips is at most 45 , which is less than the original value of chips 46.
+
+However, if $n \leq 45$, we claim that it is impossible to get one chip to $A_{10}$. To get a chip to $A_{10}$, an operation must have been used on each of $A_{1}$ through $A_{9}$ at least once. Consider the last time the operation was used on $A_{k}$ for $2 \leq k \leq 9$. After this operation, there must be a chip on $A_{k-1}$. Additionally, since no chip is ever moved past $A_{k}$ again, there is no point to perform any operations on any chips left of $A_{k}$, which means that a chip will remain on $A_{k-1}$ until the end. Therefore, if there is a way to get a chip to $A_{10}$, there must also be a way to get a chip to $A_{10}$ and also $A_{1}$ through $A_{8}$, which means that the original value of the chips must have been already $1+2+\cdots+8+10=46$.
+
diff --git a/HarvardMIT/md/en-202-2017-feb-algnt-solutions.md b/HarvardMIT/md/en-202-2017-feb-algnt-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..b9d3495be3b4511f0f3210194b2d02c042feaafa
--- /dev/null
+++ b/HarvardMIT/md/en-202-2017-feb-algnt-solutions.md
@@ -0,0 +1,216 @@
+## February 2017
+
+February 18, 2017
+
+## Algebra and Number Theory
+
+1. Let $Q(x)=a_{0}+a_{1} x+\cdots+a_{n} x^{n}$ be a polynomial with integer coefficients, and $0 \leq a_{i}<3$ for all $0 \leq i \leq n$.
+Given that $Q(\sqrt{3})=20+17 \sqrt{3}$, compute $Q(2)$.
+Proposed by: Yang Liu
+Answer: 86
+One can evaluate
+
+$$
+Q(\sqrt{3})=\left(a_{0}+3 a_{2}+3^{2} a_{4}+\ldots\right)+\left(a_{1}+3 a_{3}+3^{2} a_{5}+\ldots\right) \sqrt{3}
+$$
+
+Therefore, we have that
+
+$$
+\left(a_{0}+3 a_{2}+3^{2} a_{4}+\ldots\right)=20 \text { and }\left(a_{1}+3 a_{3}+3^{2} a_{5}+\ldots\right)=17
+$$
+
+This corresponds to the base- 3 expansions of 20 and 17. This gives us that $Q(x)=2+2 x+2 x^{3}+2 x^{4}+x^{5}$, so $Q(2)=86$.
+2. Find the value of
+
+$$
+\sum_{1 \leq a1+b_{1}$ for all $b_{1} \geq 1$, so we need either $a=1$ or $a=2$. If $a=1$, then $b \mid b+1$, so $b=1$. This gives the pair $(1,1)$. If $a=2$, we need $2 b \mid b+2^{2017}$. Therefore, we get $b \mid 2^{2017}$, so we can write $b=2^{k}$ for $0 \leq k \leq 2017$. Then we need $2^{k+1} \mid 2^{k}+2^{2017}$. As $k \leq 2017$, we need $2 \mid 1+2^{2017-k}$. This can only happen is $k=2017$. This gives the pair $\left(2,2^{2017}\right)$.
+5. Kelvin the Frog was bored in math class one day, so he wrote all ordered triples $(a, b, c)$ of positive integers such that $a b c=2310$ on a sheet of paper. Find the sum of all the integers he wrote down. In other words, compute
+
+$$
+\sum_{\substack{a b c=2310 \\ a, b, c \in \mathbb{N}}}(a+b+c)
+$$
+
+where $\mathbb{N}$ denotes the positive integers.
+Proposed by: Yang Liu
+Answer: 49140
+Note that $2310=2 \cdot 3 \cdot 5 \cdot 7 \cdot 11$. The given sum clearly equals $3 \sum_{a b c=2310} a$ by symmetry. The inner sum can be rewritten as
+
+$$
+\sum_{a \mid 2310} a \cdot \tau\left(\frac{2310}{a}\right)
+$$
+
+as for any fixed $a$, there are $\tau\left(\frac{2310}{a}\right)$ choices for the integers $b, c$.
+
+Now consider the function $f(n)=\sum_{a \mid n} a \cdot \tau\left(\frac{n}{a}\right)$. Therefore, $f=n * \tau$, where $n$ denotes the function $g(n)=n$ and $*$ denotes Dirichlet convolution. As both $n$ and $\tau$ are multiplicative, $f$ is also multiplicative.
+
+It is easy to compute that $f(p)=p+2$ for primes $p$. Therefore, our final answer is $3(2+2)(3+2)(5+$ $2)(7+2)(11+2)=49140$.
+6. A polynomial $P$ of degree 2015 satisfies the equation $P(n)=\frac{1}{n^{2}}$ for $n=1,2, \ldots, 2016$. Find $\lfloor 2017 P(2017)\rfloor$.
+Proposed by: Alexander Katz
+Answer: -9
+Let $Q(x)=x^{2} P(x)-1$. Then $Q(n)=n^{2} P(n)-1=0$ for $n=1,2, \ldots, 2016$, and $Q$ has degree 2017 . Thus we may write
+
+$$
+Q(x)=x^{2} P(x)-1=(x-1)(x-2) \ldots(x-2016) L(x)
+$$
+
+where $L(x)$ is some linear polynomial. Then $Q(0)=-1=(-1)(-2) \ldots(-2016) L(0)$, so $L(0)=-\frac{1}{2016!}$.
+
+Now note that
+
+$$
+\begin{aligned}
+Q^{\prime}(x) & =x^{2} P^{\prime}(x)+2 x P(x) \\
+& =\sum_{i=1}^{2016}(x-1) \ldots(x-(i-1))(x-(i+1)) \ldots(x-2016) L(x)+(x-1)(x-2) \ldots(x-2016) L^{\prime}(x)
+\end{aligned}
+$$
+
+Thus
+
+$$
+Q^{\prime}(0)=0=L(0)\left(\frac{2016!}{-1}+\frac{2016!}{-2}+\ldots+\frac{2016!}{-2016}\right)+2016!L^{\prime}(0)
+$$
+
+whence $L^{\prime}(0)=L(0)\left(\frac{1}{1}+\frac{1}{2}+\ldots+\frac{1}{2016}\right)=-\frac{H_{2016}}{2016!}$, where $H_{n}$ denotes the $n$th harmonic number.
+As a result, we have $L(x)=-\frac{H_{2016} x+1}{2016!}$. Then
+
+$$
+Q(2017)=2017^{2} P(2017)-1=2016!\left(-\frac{2017 H_{2016}+1}{2016!}\right)
+$$
+
+which is $-2017 H_{2016}-1$. Thus
+
+$$
+P(2017)=\frac{-H_{2016}}{2017}
+$$
+
+From which we get $2017 P(2017)=-H_{2016}$. It remains to approximate $H_{2016}$. We alter the well known approximation
+
+$$
+H_{n} \approx \int_{1}^{n} \frac{1}{x} d x=\log x
+$$
+
+to
+
+$$
+H_{n} \approx 1+\frac{1}{2}+\int_{3}^{n} \frac{1}{x} d x=1+\frac{1}{2}+\log (2016)-\log (3) \approx \log (2016)+\frac{1}{2}
+$$
+
+so that it suffices to lower bound $\log (2016)$. Note that $e^{3} \approx 20$, which is close enough for our purposes. Then $e^{6} \approx 400 \Longrightarrow e^{7} \approx 1080$, and $e^{3} \approx 20<2^{5} \Longrightarrow e^{0.6} \ll 2 \Longrightarrow e^{7.6}<2016$, so that $\log (2016)>7.6$. It follows that $H_{2016} \approx \log (2016)+0.5=7.6+0.5>8$ (of course these are loose estimates, but more than good enough for our purposes). Thus $-9<2017 P(2017)<-8$, making our answer -9 .
+Alternatively, a well-read contestant might know that $H_{n} \approx \log n+\gamma$, where $\gamma \approx .577$ is the EulerMascheroni constant. The above solution essentially approximates $\gamma$ as 0.5 which is good enough for our purposes.
+7. Determine the largest real number $c$ such that for any 2017 real numbers $x_{1}, x_{2}, \ldots, x_{2017}$, the inequality
+
+$$
+\sum_{i=1}^{2016} x_{i}\left(x_{i}+x_{i+1}\right) \geq c \cdot x_{2017}^{2}
+$$
+
+holds.
+Proposed by: Pakawut Jiradilok
+Answer: $-\frac{1008}{2017}$
+Let $n=2016$. Define a sequence of real numbers $\left\{p_{k}\right\}$ by $p_{1}=0$, and for all $k \geq 1$,
+
+$$
+p_{k+1}=\frac{1}{4\left(1-p_{k}\right)}
+$$
+
+Note that, for every $i \geq 1$,
+
+$$
+\left(1-p_{i}\right) \cdot x_{i}^{2}+x_{i} x_{i+1}+p_{i+1} x_{i+1}^{2}=\left(\frac{x_{i}}{2 \sqrt{p_{i+1}}}+\sqrt{p_{i+1}} x_{i+1}\right)^{2} \geq 0
+$$
+
+Summing from $i=1$ to $n$ gives
+
+$$
+\sum_{i=1}^{n} x_{i}\left(x_{i}+x_{i+1}\right) \geq-p_{n+1} x_{n+1}^{2}
+$$
+
+One can show by induction that $p_{k}=\frac{k-1}{2 k}$. Therefore, our answer is $-p_{2017}=-\frac{1008}{2017}$.
+8. Consider all ordered pairs of integers $(a, b)$ such that $1 \leq a \leq b \leq 100$ and
+
+$$
+\frac{(a+b)(a+b+1)}{a b}
+$$
+
+is an integer.
+Among these pairs, find the one with largest value of $b$. If multiple pairs have this maximal value of $b$, choose the one with largest $a$. For example choose $(3,85)$ over $(2,85)$ over $(4,84)$. Note that your answer should be an ordered pair.
+Proposed by: Alexander Katz
+Answer: $(35,90)$
+Firstly note that $\frac{(a+b)(a+b+1)}{a b}=2+\frac{a^{2}+b^{2}+a+b}{a b}$. Let $c$ be this fraction so that $(a+b)(a+b+1)=a b(c+2)$ for some integers $a, b, c$. Suppose $(a, b)$ with $a \geq b$ is a solution for some $c$. Consider the quadratic
+
+$$
+x^{2}-(b c-1) x+b^{2}+b=0
+$$
+
+It has one root $a$, and the other root is therefore $b c-a-1$. Furthermore the other root can also be expressed as $\frac{b^{2}+b}{a} \leq \frac{b^{2}+b}{b+1}=b$, so that $00$ such that $N$ of the jars have exactly $d$ coins). What is the maximum possible value of $N$ ?
+Proposed by: Kevin Sun
+Answer: 2014
+Label the jars $1,2, \ldots, 2017$. I claim that the answer is 2014 . To show this, we need both a construction and an upper bound. For the construction, for $1 \leq i \leq 201$, put a coin in the jars $10 i+1,10 i+$ $2, \ldots, 10 i+10$. After this, each of the jars $1,2, \ldots, 2010$ has exactly one coin. Now, put a coin in each of the jars $2008,2009, \ldots, 2017$. Now, the jars $1,2, \ldots, 2007,2011,2012, \ldots, 2017$ all have exactly one coin. This gives a construction for $N=2014$ (where $d=1$ ).
+
+Now, we show that this is optimal. Let $c_{1}, c_{2}, \ldots, c_{2017}$ denote the number of coins in each of the jars. For $1 \leq j \leq 10$, define
+
+$$
+s_{j}=c_{j}+c_{j+10}+c_{j+20}+\ldots
+$$
+
+Note that throughout the process, $s_{1}=s_{2}=\cdots=s_{j}$. It is also easy to check that the sums $s_{1}, s_{2}, \ldots, s_{7}$ each involve 202 jars, while the sums $s_{8}, s_{9}, s_{10}$ each involve 201 jars.
+
+Call a jar good if it has exactly $d$ coins. If there are at least 2015 good jars, then one can check that it is forced that at least one of $s_{1}, s_{2}, \ldots, s_{7}$ only involves good jars, and similarly, at least one of $s_{8}, s_{9}, s_{10}$ only involves good jars. But this would mean that $202 d=201 d$ as all $s_{i}$ are equal, contradiction.
+4. Sam spends his days walking around the following $2 \times 2$ grid of squares.
+
+| 1 | 2 |
+| :--- | :--- |
+| 4 | 3 |
+
+Say that two squares are adjacent if they share a side. He starts at the square labeled 1 and every second walks to an adjacent square. How many paths can Sam take so that the sum of the numbers on every square he visits in his path is equal to 20 (not counting the square he started on)?
+Proposed by: Sam Korsky
+Answer: 167
+Note that on the first step, Sam can either step on 2 or 4 . On the second step, Sam can either step on 1 or 3 , regardless of whether he is on 2 or 4 . Now, for example, say that Sam takes 8 steps. His total sum will be $2+1+2+1+2+1+2+1+2 a$, where $a$ is the number of times that he decides to step on the larger number of his two choices. Solving gives $a=4$. As he took 8 steps, this gives him $\binom{8}{4}=70$ ways in this case.
+We can follow a similar approach by doing casework on the number of steps he takes. I will simply list them out here for brevity. For 8 steps, we get $\binom{8}{4}=70$. For 9 steps, we get $\binom{9}{3}=84$. For 12 steps, we get a contribution on $\binom{12}{1}=12$. For 13 steps, we get a contribution of $\binom{13}{0}=1$. Therefore, the final answer is $70+84+12+1=167$.
+5. Kelvin the Frog likes numbers whose digits strictly decrease, but numbers that violate this condition in at most one place are good enough. In other words, if $d_{i}$ denotes the $i$ th digit, then $d_{i} \leq d_{i+1}$ for at most one value of $i$. For example, Kelvin likes the numbers 43210, 132, and 3, but not the numbers 1337 and 123. How many 5-digit numbers does Kelvin like?
+
+## Proposed by: Alexander Katz
+
+## Answer: 14034
+
+Suppose first that no digit violates the constraint; i.e. the digits are in strictly decreasing order. There are $\binom{10}{5}$ ways to choose the digits of the number, and each set of digits can be arranged in exactly one way, so there are $\binom{10}{5}$ such numbers.
+We now perform casework on which digit violates the constraint. If it is the final digit, the first four digits must be arranged in decreasing order, which there are $\binom{10}{4}$ ways to do. The final digit can then be any digit, but we have overcounted the ones in which the number is in fully decreasing order (this can happen, for example, if the first 4 digits we chose were $5,4,3$, and 2 - a last digit of 1 was already counted in the first case). Therefore, there are $\binom{10}{4}\binom{10}{1}-252$ new numbers in this case.
+If the offending digit is second from the right, the first 3 digits must be decreasing, as must the last 2 digits. There are $\binom{10}{3}\binom{10}{2}$ ways to do this. As before, we overcount the case where the second digit from the right is not actually an offender, so we again overcount the case where all 5 digits decrease. Hence there are $\binom{10}{3}\binom{10}{2}-252$ new numbers in this case.
+The case where the third digit is the offender is identical to the previous case, so there are another $\binom{10}{3}\binom{10}{2}-252$ numbers to account for. The final case is when the second digit is the offending digit, in which case there are $\binom{10}{4}$ ways to choose the final 4 digits, but only 9 ways to choose the opening digit (as 0 cannot be a leading digit). Accounting for the usual overcounting, our final answer is
+
+$$
+252+\left[\binom{10}{4}\binom{10}{1}-252\right]+2\left[\binom{10}{3}\binom{10}{2}-252\right]+\left[\binom{10}{4} \cdot 9-252\right]
+$$
+
+which is easily calculated as 14034 .
+6. Emily starts with an empty bucket. Every second, she either adds a stone to the bucket or removes a stone from the bucket, each with probability $\frac{1}{2}$. If she wants to remove a stone from the bucket and the bucket is currently empty, she merely does nothing for that second (still with probability $\frac{1}{2}$ ). What is the probability that after 2017 seconds her bucket contains exactly 1337 stones?
+
+## Proposed by: Sam Korsky
+
+Answer: $\frac{\left(\begin{array}{l}2017 \\ 340 \\ 2^{2017} \\ \hline\end{array}\right)}{}$
+Replace 2017 with $n$ and 1337 with $k$ and denote the general answer by $f(n, k)$. I claim that $f(n, k)=$ $\frac{\left(\left\lfloor\frac{n-k}{2}\right\rfloor\right.}{2^{n}}$ ) We proceed by induction on $n$.
+The claim is obviously true for $n=0$ since $f(0,0)=1$. Moreover, we have that $f(n, 0)=\frac{1}{2} f(n-$ $1,0)+\frac{1}{2} f(n-1,1)$ and $f(n, k)=\frac{1}{2} f(n-1, k-1)+\frac{1}{2} f(n-1, k+1)$ for $k>0$ so the inductive step is immediate by Pascal's identity. This concludes the proof.
+7. There are 2017 frogs and 2017 toads in a room. Each frog is friends with exactly 2 distinct toads. Let $N$ be the number of ways to pair every frog with a toad who is its friend, so that no toad is paired with more than one frog. Let $D$ be the number of distinct possible values of $N$, and let $S$ be the sum of all possible values of $N$. Find the ordered pair $(D, S)$.
+Proposed by: Yang Liu
+Answer: $\left(1009,2^{1009}-2\right)$
+I claim that $N$ can equal 0 or $2^{i}$ for $1 \leq i \leq 1008$. We prove this now. Note that the average number of friends a toad has is also 2 . If there is a toad with 0 friends, then clearly $N=0$. If a toad has 1 friend, then it must be paired with its only friend, so we have reduced to a smaller case. Otherwise, all toads and frogs have exactly degree 2 , so the graph is a union of cycles. Each cycle can be paired off in exactly two ways. The number of cycles can range anywhere from 1 to 1008, and this completes the proof.
+
+To construct all $N=2^{1}, 2^{2}, \ldots, 2^{1008}$, we can simply let our graph be a union of $i$ cycles, which would have $2^{i}$ matchings. Clearly we can choose any $i=1,2, \ldots, 1008$.
+
+Therefore, $D=1009$ and $S=2^{1}+2^{2}+\cdots+2^{1008}=2^{1009}-2$.
+8. Kelvin and 15 other frogs are in a meeting, for a total of 16 frogs. During the meeting, each pair of distinct frogs becomes friends with probability $\frac{1}{2}$. Kelvin thinks the situation after the meeting is cool if for each of the 16 frogs, the number of friends they made during the meeting is a multiple of 4 . Say that the probability of the situation being cool can be expressed in the form $\frac{a}{b}$, where $a$ and $b$ are relatively prime. Find $a$.
+Proposed by: Yang Liu
+Consider the multivariate polynomial
+
+$$
+\prod_{1 \leq i
February 18, 2017
+
+
February 18, 2017}
+## Geometry
+
+1. Let $A, B, C, D$ be four points on a circle in that order. Also, $A B=3, B C=5, C D=6$, and $D A=4$. Let diagonals $A C$ and $B D$ intersect at $P$. Compute $\frac{A P}{C P}$.
+Proposed by: Sam Korsky
+
+Answer: | $\frac{2}{5}$ |
+| :---: |
+
+Note that $\triangle A P B \sim \triangle D P C$ so $\frac{A P}{A B}=\frac{D P}{C D}$. Similarly, $\triangle B P C \sim \triangle A P D$ so $\frac{C P}{B C}=\frac{D P}{D A}$. Dividing these two equations yields
+
+$$
+\frac{A P}{C P}=\frac{A B \cdot D A}{B C \cdot C D}=\frac{2}{5}
+$$
+
+2. Let $A B C$ be a triangle with $A B=13, B C=14$, and $C A=15$. Let $\ell$ be a line passing through two sides of triangle $A B C$. Line $\ell$ cuts triangle $A B C$ into two figures, a triangle and a quadrilateral, that have equal perimeter. What is the maximum possible area of the triangle?
+Proposed by: Sam Korsky
+Answer: $\frac{1323}{26}$
+There are three cases: $\ell$ intersects $A B, A C, \ell$ intersects $A B, B C$, and $\ell$ intersects $A C, B C$. These cases are essentially identical, so let $\ell$ intersect segment $A B$ at $M$ and segment $A C$ at $N$.
+Then the condition is equivalent to
+
+$$
+\begin{gathered}
+A M+M N+A N=M B+B C+C N+M N \\
+A M+A N=M B+C N+15
+\end{gathered}
+$$
+
+but $A N+C N=14$ and $A M+B M=13$, so that
+
+$$
+B M+C N=27-A M-A N=A M-A N-15
+$$
+
+implying that $A M+A N=21$.
+Now let $\angle B A C=\theta$ for convenience, so that
+
+$$
+[A M N]=\frac{1}{2} A M \cdot A N \cdot \sin \theta
+$$
+
+which is maximized when $A M=A N=\frac{21}{2}$. Further we can easily calculate $\sin \theta=\frac{12}{13}$ (e.g. by LOC); note that this is why the area is maximized in this case (we want to maximize $\sin \theta$, which is equivalent to maximizing $\theta$, so $\theta$ should be opposite the largest side). Our answer is thus
+
+$$
+\frac{1}{2} \cdot \frac{21}{2} \cdot \frac{21}{2} \cdot \frac{12}{13}=\frac{1323}{26}
+$$
+
+Alternatively we could also calculate
+
+$$
+\begin{aligned}
+{[A M N] } & =[A B C] \cdot \frac{A M}{A B} \cdot \frac{A N}{A C} \\
+& =84 \cdot \frac{21}{23} \cdot \frac{\frac{21}{2}}{14}
+\end{aligned}
+$$
+
+which gives the same answer.
+3. Let $S$ be a set of 2017 distinct points in the plane. Let $R$ be the radius of the smallest circle containing all points in $S$ on either the interior or boundary. Also, let $D$ be the longest distance between two of the points in $S$. Let $a, b$ are real numbers such that $a \leq \frac{D}{R} \leq b$ for all possible sets $S$, where $a$ is as large as possible and $b$ is as small as possible. Find the pair $(a, b)$.
+Proposed by: Yang Liu
+Answer: $(\sqrt{3}, 2)$
+It is easy to verify that the smallest circle enclosing all the points will either have some 2 points in $S$ as its diameter, or will be the circumcircle of some 3 points in $S$ who form an acute triangle.
+
+Now, clearly $\frac{D}{R} \leq 2$. Indeed consider the two farthest pair of points $S_{1}, S_{2}$. Then $D=\left|S_{1} S_{2}\right| \leq 2 R$, as both points $S_{1}, S_{2}$ are inside a circle of radius $R$. We can achieve this upper bound by taking $S$ to have essentially only 2 points, and the remaining 2015 points in $S$ are at the same place as these 2 points.
+
+For the other direction, I claim $\frac{D}{R} \geq \sqrt{3}$. Recall that the smallest circle is either the circumcircle of 3 points, or has some 2 points as the diameter. In the latter case, say the diameter is $S_{1} S_{2}$. Then $D \geq\left|S_{1} S_{2}\right|=2 R$, so $\frac{D}{R} \geq 2$ in that case. Now say the points $S_{1}, S_{2}, S_{3}$ are the circumcircle. WLOG, say that $S_{1} S_{2}$ is the longest side of the triangle. As remarked above, we can assume this triangle is acute. Therefore, $\frac{\pi}{3} \leq \angle S_{1} S_{3} S_{2} \leq \frac{\pi}{2}$. By the Law of Sines we have that
+
+$$
+D \geq\left|S_{1} S_{2}\right|=2 R \sin \angle S_{1} S_{3} S_{2} \geq 2 R \sin \frac{\pi}{3}=R \sqrt{3}
+$$
+
+This completes the proof. To achieve equality, we can take $S$ to have 3 points in the shape of an equilateral triangle.
+4. Let $A B C D$ be a convex quadrilateral with $A B=5, B C=6, C D=7$, and $D A=8$. Let $M, P, N, Q$ be the midpoints of sides $A B, B C, C D, D A$ respectively. Compute $M N^{2}-P Q^{2}$.
+Proposed by: Sam Korsky
+Answer: 13
+Draw in the diagonals of the quad and use the median formula three times to get $M N^{2}$ in terms of the diagonals. Do the same for $P Q^{2}$ and subtract, the diagonal length terms disappear and the answer is
+
+$$
+\frac{B C^{2}+D A^{2}-A B^{2}-C D^{2}}{2}=13
+$$
+
+5. Let $A B C D$ be a quadrilateral with an inscribed circle $\omega$ and let $P$ be the intersection of its diagonals $A C$ and $B D$. Let $R_{1}, R_{2}, R_{3}, R_{4}$ be the circumradii of triangles $A P B, B P C, C P D, D P A$ respectively. If $R_{1}=31$ and $R_{2}=24$ and $R_{3}=12$, find $R_{4}$.
+Proposed by: Sam Korsky
+Answer: 19
+Note that $\angle A P B=180^{\circ}-\angle B P C=\angle C P D=180^{\circ}-\angle D P A$ so $\sin A P B=\sin B P C=\sin C P D=$ $\sin D P A$. Now let $\omega$ touch sides $A B, B C, C D, D A$ at $E, F, G, H$ respectively. Then $A B+C D=$ $A E+B F+C G+D H=B C+D A$ so
+
+$$
+\frac{A B}{\sin A P B}+\frac{C D}{\sin C P D}=\frac{B C}{\sin B P C}+\frac{D A}{\sin D P A}
+$$
+
+and by the Extended Law of Sines this implies
+
+$$
+2 R_{1}+2 R_{3}=2 R_{2}+2 R_{4}
+$$
+
+which immediately yields $R_{4}=R_{1}+R_{3}-R_{2}=19$.
+6. In convex quadrilateral $A B C D$ we have $A B=15, B C=16, C D=12, D A=25$, and $B D=20$. Let $M$ and $\gamma$ denote the circumcenter and circumcircle of $\triangle A B D$. Line $C B$ meets $\gamma$ again at $F$, line $A F$ meets $M C$ at $G$, and line $G D$ meets $\gamma$ again at $E$. Determine the area of pentagon $A B C D E$.
+Proposed by: Evan Chen
+Answer: 396
+Note that $\angle A D B=\angle D C B=90^{\circ}$ and $B C \| A D$. Now by Pascal theorem on $D D E B F A$ implies that $B, M, E$ are collinear. So $[A D E]=[A B D]=150$ and $[B C D]=96$, so the total area is 396 .
+7. Let $\omega$ and $\Gamma$ by circles such that $\omega$ is internally tangent to $\Gamma$ at a point $P$. Let $A B$ be a chord of $\Gamma$ tangent to $\omega$ at a point $Q$. Let $R \neq P$ be the second intersection of line $P Q$ with $\Gamma$. If the radius of $\Gamma$ is 17 , the radius of $\omega$ is 7 , and $\frac{A Q}{B Q}=3$, find the circumradius of triangle $A Q R$.
+Proposed by: Sam Korsky
+Answer: $\sqrt{170}$
+Let $r$ denote the circumradius of triangle $A Q R$. By Archimedes Lemma, $R$ is the midpoint of arc $A B$ of $\Gamma$. Therefore $\angle R A Q=\angle R P B=\angle R P A$ so $\triangle R A Q \sim \triangle R P A$. By looking at the similarity ratio between the two triangles we have
+
+$$
+\frac{r}{17}=\frac{A Q}{A P}
+$$
+
+Now, let $A P$ intersect $\omega$ again at $X \neq P$. By homothety we have $X Q \| A R$ so
+
+$$
+\frac{A X}{A P}=1-\frac{P Q}{P R}=1-\frac{7}{17}=\frac{10}{17}
+$$
+
+But we also know
+
+$$
+A X \cdot A P=A Q^{2}
+$$
+
+so
+
+$$
+\frac{10}{17} A P^{2}=A Q^{2}
+$$
+
+Thus
+
+$$
+\frac{r}{17}=\frac{A Q}{A P}=\sqrt{\frac{10}{17}}
+$$
+
+so we compute $r=\sqrt{170}$ as desired.
+8. Let $A B C$ be a triangle with circumradius $R=17$ and inradius $r=7$. Find the maximum possible value of $\sin \frac{A}{2}$.
+Proposed by: Sam Korsky
+Answer: $\frac{17+\sqrt{51}}{34}$
+Letting $I$ and $O$ denote the incenter and circumcenter of triangle $A B C$ we have by the triangle inequality that
+
+$$
+A O \leq A I+O I \Longrightarrow R \leq \frac{r}{\sin \frac{A}{2}}+\sqrt{R(R-2 r)}
+$$
+
+and by plugging in our values for $r$ and $R$ we get
+
+$$
+\sin \frac{A}{2} \leq \frac{17+\sqrt{51}}{34}
+$$
+
+as desired. Equality holds when $A B C$ is isosceles and $I$ lies between $A$ and $O$.
+9. Let $A B C$ be a triangle, and let $B C D E, C A F G, A B H I$ be squares that do not overlap the triangle with centers $X, Y, Z$ respectively. Given that $A X=6, B Y=7$, and $C Z=8$, find the area of triangle $X Y Z$.
+Proposed by: Sam Korsky
+Answer: $\frac{21 \sqrt{15}}{4}$
+By the degenerate case of Von Aubel's Theorem we have that $Y Z=A X=6$ and $Z X=B Y=7$ and $X Y=C Z=8$ so it suffices to find the area of a $6-7-8$ triangle which is given by $\frac{21 \sqrt{15}}{4}$.
+To prove that $A X=Y Z$, note that by LoC we get
+
+$$
+Y X^{2}=\frac{b^{2}}{2}+\frac{c^{2}}{2}+b c \sin \angle A
+$$
+
+and
+
+$$
+\begin{aligned}
+A X^{2} & =b^{2}+\frac{a^{2}}{2}-a b(\cos \angle C-\sin \angle C) \\
+& =c^{2}+\frac{a^{2}}{2}-a c(\cos \angle B-\sin \angle B) \\
+& =\frac{b^{2}+c^{2}+a(b \sin \angle C+c \sin \angle B)}{2} \\
+& =\frac{b^{2}}{2}+\frac{c^{2}}{2}+a h
+\end{aligned}
+$$
+
+where $h$ is the length of the $A$-altitude of triangle $A B C$. In these calculations we used the well-known fact that $b \cos \angle C+c \cos \angle B=a$ which can be easily seen by drawing in the $A$-altitude. Then since $b c \sin \angle A$ and $a h$ both equal twice the area of triangle $A B C$, we are done.
+10. Let $A B C D$ be a quadrilateral with an inscribed circle $\omega$. Let $I$ be the center of $\omega$ let $I A=12$, $I B=16, I C=14$, and $I D=11$. Let $M$ be the midpoint of segment $A C$. Compute $\frac{I M}{I N}$, where $N$ is the midpoint of segment $B D$.
+Proposed by: Sam Korsky
+
+## Answer: $\frac{21}{22}$
+
+Let points $W, X, Y, Z$ be the tangency points between $\omega$ and lines $A B, B C, C D, D A$ respectively. Now invert about $\omega$. Then $A^{\prime}, B^{\prime}, C^{\prime}, D^{\prime}$ are the midpoints of segments $Z W, W X, X Y, Y Z$ respectively. Thus by Varignon's Theorem $A^{\prime} B^{\prime} C^{\prime} D^{\prime}$ is a parallelogram. Then the midpoints of segments $A^{\prime} C^{\prime}$ and $B^{\prime} D^{\prime}$ coincide at a point $P$. Note that figure $I A^{\prime} P C^{\prime}$ is similar to figure $I C M A$ with similitude ratio $\frac{r^{2}}{I A \cdot I C}$ where $r$ is the radius of $\omega$. Similarly figure $I B^{\prime} P D^{\prime}$ is similar to figure $I D M B$ with similitude ratio $\frac{r^{2}}{I B \cdot I D}$. Therefore
+
+$$
+I P=\frac{r^{2}}{I A \cdot I C} \cdot I M=\frac{r^{2}}{I B \cdot I D} \cdot I N
+$$
+
+which yields
+
+$$
+\frac{I M}{I N}=\frac{I A \cdot I C}{I B \cdot I D}=\frac{12 \cdot 14}{16 \cdot 11}=\frac{21}{22}
+$$
+
diff --git a/HarvardMIT/md/en-202-2017-feb-guts-solutions.md b/HarvardMIT/md/en-202-2017-feb-guts-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..6c6a0c546f960abb6437f0e48ff3f36125562361
--- /dev/null
+++ b/HarvardMIT/md/en-202-2017-feb-guts-solutions.md
@@ -0,0 +1,459 @@
+## February 2017
+
+## February 18, 2017
+
+## Guts
+
+1. [4] A random number generator will always output 7 . Sam uses this random number generator once. What is the expected value of the output?
+Proposed by: Sam Korsky
+Answer: 7
+The only output is 7 , so the expected value is 7 .
+2. [4] Let $A, B, C, D, E, F$ be 6 points on a circle in that order. Let $X$ be the intersection of $A D$ and $B E$, $Y$ is the intersection of $A D$ and $C F$, and $Z$ is the intersection of $C F$ and $B E . X$ lies on segments $B Z$ and $A Y$ and $Y$ lies on segment $C Z$. Given that $A X=3, B X=2, C Y=4, D Y=10, E Z=16$, and $F Z=12$, find the perimeter of triangle $X Y Z$.
+Proposed by: Sam Korsky
+Answer: $\frac{77}{6}$
+Let $X Y=z, Y Z=x$, and $Z X=y$. By Power of a Point, we have that
+
+$$
+3(z+10)=2(y+16), 4(x+12)=10(z+3), \text { and } 12(x+4)=16(y+2) .
+$$
+
+Solving this system gives $X Y=\frac{11}{3}$ and $Y Z=\frac{14}{3}$ and $Z X=\frac{9}{2}$. Therefore, our answer if $X Y+Y Z+$ $Z X=\frac{77}{6}$.
+3. [4] Find the number of pairs of integers $(x, y)$ such that $x^{2}+2 y^{2}<25$.
+
+Proposed by: Allen Liu
+Answer: 55
+We do casework on $y$.
+If $y=0$, we have $x^{2}<25$, so we get 9 values of $x$. If $y= \pm 1$, then $x^{2}<23$, so we still have 9 values of $x$. If $y= \pm 2$, we have $x^{2}<17$, so we have 9 values of $x$. If $y= \pm 3$, we have $x^{2}<7$, we get 5 values of $x$.
+Therefore, the final answer is $9+2(9+9+5)=55$.
+4. [4] Find the number of ordered triples of nonnegative integers $(a, b, c)$ that satisfy
+
+$$
+(a b+1)(b c+1)(c a+1)=84 .
+$$
+
+## Proposed by: Evan Chen
+
+Answer: 12
+The solutions are $(0,1,83)$ and $(1,2,3)$ up to permutation. First, we do the case where at least one of $a, b, c$ is 0 . WLOG, say $a=0$. Then we have $1+b c=84 \Longrightarrow b c=83$. As 83 is prime, the only solution is $(0,1,83)$ up to permutation.
+
+Otherwise, we claim that at least one of $a, b, c$ is equal to 1 . Otherwise, all are at least 2 , so $(1+$ $a b)(1+b c)(1+a c) \geq 5^{3}>84$. So WLOG, set $a=1$. We now need $(b+1)(c+1)(b c+1)=84$. Now, WLOG, say $b \leq c$. If $b=1$, then $(c+1)^{2}=42$, which has no solution. If $b \geq 3$, then $(b+1)(c+1)(b c+1) \geq 4^{2} \cdot 10=160>84$. So we need $b=2$. Then we need $(c+1)(2 c+1)=21$. Solving this gives $c=3$, for the solution $(1,2,3)$.
+Therefore, the answer is $6+6=12$.
+5. [6] Find the number of ordered triples of positive integers $(a, b, c)$ such that
+
+$$
+6 a+10 b+15 c=3000
+$$
+
+Proposed by: Yang Liu
+Answer: 4851
+Note that $6 a$ must be a multiple of 5 , so $a$ must be a multiple of 5 . Similarly, $b$ must be a multiple of 3 , and $c$ must be a multiple of 2 .
+Set $a=5 A, b=3 B, c=2 C$. Then the equation reduces to $A+B+C=100$. This has $\binom{99}{2}=4851$ solutions.
+6. [6] Let $A B C D$ be a convex quadrilateral with $A C=7$ and $B D=17$. Let $M, P, N, Q$ be the midpoints of sides $A B, B C, C D, D A$ respectively. Compute $M N^{2}+P Q^{2}$
+Proposed by: Sam Korsky
+Answer: 169
+$M P N Q$ is a parallelogram whose side lengths are 3.5 and 8.5 so the sum of squares of its diagonals is $\frac{7^{2}+17^{2}}{2}=169$
+7. [6] An ordered pair of sets $(A, B)$ is good if $A$ is not a subset of $B$ and $B$ is not a subset of $A$. How many ordered pairs of subsets of $\{1,2, \ldots, 2017\}$ are good?
+Proposed by: Alexander Katz
+Answer: $4^{2017}-2 \cdot 3^{2017}+2^{2017}$
+Firstly, there are $4^{2017}$ possible pairs of subsets, as each of the 2017 elements can be in neither subset, in $A$ only, in $B$ only, or in both.
+
+Now let us count the number of pairs of subsets for which $A$ is a subset of $B$. Under these conditions, each of the 2017 elements could be in neither subset, in $B$ only, or in both $A$ and $B$. So there are $3^{2017}$ such pairs.
+By symmetry, there are also $3^{2017}$ pairs of subsets where $B$ is a subset of $A$. But this overcounts the pairs in which $A$ is a subset of $B$ and $B$ is a subset of $A$, i.e. $A=B$. There are $2^{2017}$ such subsets.
+Thus, in total, there are $4^{2017}-2 \cdot 3^{2017}+2^{2017}$ good pairs of subsets.
+8. [6] You have 128 teams in a single elimination tournament. The Engineers and the Crimson are two of these teams. Each of the 128 teams in the tournament is equally strong, so during each match, each team has an equal probability of winning.
+Now, the 128 teams are randomly put into the bracket.
+What is the probability that the Engineers play the Crimson sometime during the tournament?
+Proposed by: Yang Liu
+Answer: $\frac{1}{64}$
+There are $\binom{128}{2}=127 \cdot 64$ pairs of teams. In each tournament, 127 of these pairs play.
+By symmetry, the answer is $\frac{127}{127 \cdot 64}=\frac{1}{64}$.
+9. [7] Jeffrey writes the numbers 1 and $100000000=10^{8}$ on the blackboard. Every minute, if $x, y$ are on the board, Jeffrey replaces them with
+
+$$
+\frac{x+y}{2} \text { and } 2\left(\frac{1}{x}+\frac{1}{y}\right)^{-1}
+$$
+
+After 2017 minutes the two numbers are $a$ and $b$. Find $\min (a, b)$ to the nearest integer.
+Proposed by: Yang Liu
+
+Answer: 10000
+Note that the product of the integers on the board is a constant. Indeed, we have that
+
+$$
+\frac{x+y}{2} \cdot 2\left(\frac{1}{x}+\frac{1}{y}\right)^{-1}=x y
+$$
+
+Therefore, we expect that the answer to the problem is approximately $\sqrt{1 \cdot 10^{8}}=10^{4}$.
+
+To be more rigorous, we have to show that the process indeed converges quickly enough. To show this, we bound the difference between the integers on the board at time $i$. Say that at time $i$, the integers on the board are $a_{i}
April 10, 2017
HMIC
+
+1. [6] Kevin and Yang are playing a game. Yang has $2017+\binom{2017}{2}$ cards with their front sides face down on the table. The cards are constructed as follows:
+
+- For each $1 \leq n \leq 2017$, there is a blue card with $n$ written on the back, and a fraction $\frac{a_{n}}{b_{n}}$ written on the front, where $\operatorname{gcd}\left(a_{n}, b_{n}\right)=1$ and $a_{n}, b_{n}>0$.
+- For each $1 \leq i
February 10, 2018
+
+## Algebra and Number Theory
+
+1. For some real number $c$, the graphs of the equation $y=|x-20|+|x+18|$ and the line $y=x+c$ intersect at exactly one point. What is $c$ ?
+Proposed by: Henrik Boecken
+Answer: 18
+We want to know the value of $c$ so that the graph $|x-20|+|x+18|-x=c$ has one solution. The graph of the function $|x-20|+|x+18|-x$ consists of an infinite section of slope -3 for $x \in(-\infty,-18]$, then a finite section of slope -1 for $x \in[-18,20]$, then an infinite section of slope 1 for $x \in[20, \infty)$. Notice that this graph is strictly decreasing on $(-\infty, 20]$ and strictly increasing on $[20, \infty)$. Therefore any horizontal line will intersect this graph 0 or 2 times, except the one that passes through the "vertex" $(20,|20-20|+|20+18|-20)=(20,18)$, giving a value of $c=18$.
+2. Compute the positive real number $x$ satisfying
+
+$$
+x^{\left(2 x^{6}\right)}=3
+$$
+
+Proposed by: Henrik Boecken
+Answer: $\sqrt[6]{3}$
+Let $t=x^{6}$, so $x^{2 t}=3$. Taking this to the third power gives $x^{6 t}=27$, or equivalently $t^{t}=3^{3}$. We can see by inspection that $t=3$, and this is the only solution as for $t>1$, the function $t^{t}$ is monotonically increasing, and if $0
February 10, 2018
Combinatorics
+
+1. Consider a $2 \times 3$ grid where each entry is one of 0,1 , and 2 . For how many such grids is the sum of the numbers in every row and in every column a multiple of 3 ? One valid grid is shown below.
+
+$$
+\left[\begin{array}{lll}
+1 & 2 & 0 \\
+2 & 1 & 0
+\end{array}\right]
+$$
+
+Proposed by: Henrik Boecken
+Answer: 9
+Any two elements in the same row fix the rest of the grid, so $3^{2}=9$.
+2. Let $a$ and $b$ be five-digit palindromes (without leading zeroes) such that $ap_{i+1}$, and does nothing otherwise. The tourist performs $n-1$ rounds of fixes, numbered $a=1,2, \ldots, n-1$. In round $a$ of fixes, the tourist fixes $p_{a}$ and $p_{a+1}$, then $p_{a+1}$ and $p_{a+2}$, and so on, up to $p_{n-1}$ and $p_{n}$. In this process, there are $(n-1)+(n-2)+\cdots+1=\frac{n(n-1)}{2}$ total fixes performed. How many permutations of $(1, \ldots, 2018)$ can the tourist start with to obtain $(1, \ldots, 2018)$ after performing these steps?
+Proposed by: Kevin Sun
+Answer: 1009! • 1010!
+Note that the given algorithm is very similar to the well-known Bubble Sort algorithm for sorting an array. The exception is that in the $i$-th round through the array, the first $i-1$ pairs are not checked.
+We claim a necessary and sufficient condition for the array to be sorted after the tourist's process is: for all $i$, after $i$ rounds, the numbers $1, \cdots, i$ are in the correct position. Firstly, this is necessary because these indices of the array are not touched in future rounds - so if a number was incorrect, then it would stay incorrect. On the other hand, suppose this condition holds. Then, we can "add" the additional fixes during each round (of the first $i-1$ pairs during the $i$-th round) to make the process identical to bubble sort. The tourist's final result won't change because by our assumption these swaps won't do anything. However, this process is now identical to bubble sort, so the resulting array will be sorted. Thus, our condition is sufficient.
+
+Now, there are two positions the 1 can be in $\left(p_{1}, p_{2}\right)$. There are three positions the 2 can be in $\left(p_{1}, \cdots, p_{4}\right.$ except for the position of 1$)$. Similarly, for $1 \leq i \leq 1009$ there are $2 i-(i-1)=i+1$ positions $i$ can be in, and after that the remaining 1009 numbers can be arranged arbitrarily. Thus, the answer is 1010 ! • 1009!.
+8. A permutation of $\{1,2, \ldots, 7\}$ is chosen uniformly at random. A partition of the permutation into contiguous blocks is correct if, when each block is sorted independently, the entire permutation becomes sorted. For example, the permutation $(3,4,2,1,6,5,7)$ can be partitioned correctly into the blocks $[3,4,2,1]$ and $[6,5,7]$, since when these blocks are sorted, the permutation becomes $(1,2,3,4,5,6,7)$.
+Find the expected value of the maximum number of blocks into which the permutation can be partitioned correctly.
+
+## Proposed by: Mehtaab Sawhney
+
+Answer:
+
+
+Let $\sigma$ be a permutation on $\{1, \ldots, n\}$. Call $m \in\{1, \ldots, n\}$ a breakpoint of $\sigma$ if $\{\sigma(1), \ldots, \sigma(m)\}=$ $\{1, \ldots, m\}$. Notice that the maximum partition is into $k$ blocks, where $k$ is the number of breakpoints: if our breakpoints are $m_{1}, \ldots, m_{k}$, then we take $\left\{1, \ldots, m_{1}\right\},\left\{m_{1}+1, \ldots, m_{2}\right\}, \ldots,\left\{m_{k-1}+1, \ldots, m_{k}\right\}$ as our contiguous blocks.
+Now we just want to find
+
+$$
+\mathbb{E}[k]=\mathbb{E}\left[X_{1}+\cdots+X_{n}\right]
+$$
+
+where $X_{i}=1$ if $i$ is a breakpoint, and $X_{i}=0$ otherwise. We use linearity of expectation and notice that
+
+$$
+\mathbb{E}\left[X_{i}\right]=\frac{i!(n-i)!}{n!}
+$$
+
+since this is the probability that the first $i$ numbers are just $1, \ldots, i$ in some order. Thus,
+
+$$
+\mathbb{E}[k]=\sum_{i=1}^{n} \frac{i!(n-i)!}{n!}=\sum_{i=1}^{n}\binom{n}{i}^{-1}
+$$
+
+We can compute for $n=7$ that the answer is $\frac{151}{105}$.
+9. How many ordered sequences of 36 digits have the property that summing the digits to get a number and taking the last digit of the sum results in a digit which is not in our original sequence? (Digits range from 0 to 9. )
+Proposed by: Kevin Sun
+Answer: $9^{36}+4$
+We will solve this problem for 36 replaced by $n$. We use $[n]$ to denote $\{1,2, \ldots, n\}$ and $\sigma_{s}$ to denote the last digit of the sum of the digits of $s$.
+Let $D$ be the set of all sequences of $n$ digits and let $S_{i}$ be the set of digit sequences $s$ such that $s_{i}=\sigma_{s}$, the $i^{\text {th }}$ digit of $s$. The quantity we are asked to compute is equal to $\left|D \backslash \bigcup_{i=1}^{n} S_{i}\right|$. We use the principle of inclusion-exclusion to compute this:
+
+$$
+\left|D \backslash \bigcup_{i=1}^{n} S_{i}\right|=\sum_{J \subseteq[n]}(-1)^{|J|}\left|\bigcap_{j \in J} S_{j}\right|
+$$
+
+Note that a digit sequence is in $S_{i}$ if and only if the $n-1$ digits which are not $i$ sum to a multiple of 10. This gives that $\left|S_{i}\right|=10 \cdot 10^{n-2}=10^{n-1}$ as there are 10 ways to pick the $i^{\text {th }}$ digit and $10^{n-2}$ ways to pick the other digits.
+Similarly, given a subset $J \subseteq[n]$, we can perform a similar analysis. If a string $s$ is in $\bigcap_{j \in J} S_{j}$, we must
+have that $s_{j}=\sigma_{s}$ for all $j \in J$. There are 10 ways to pick $\sigma_{s}$, which determines $s_{j}$ for all $j \in J$. From there, there are $10^{(n-|J|)-1}$ ways to pick the remaining digits as if we fix all but one, the last digit is uniquely determined. This gives $10^{n-|J|}$ choices.
+However, this breaks down when $|J|=n$, as not all choices of $\sigma_{s}$ lead to any valid solutions. When $|J|=n, J=[n]$ and we require that the last digit of $n \sigma_{s}$ is $\sigma_{s}$, which happens for $\operatorname{gcd}(n-1,10)$ values of $\sigma_{s}$.
+We now compare our expression from the principle of inclusion-exclusion to the binomial expansion of $(10-1)^{n}$. By the binomial theorem,
+
+$$
+9^{n}=(10-1)^{n}=\sum_{J \subseteq[n]}(-1)^{|J|} 10^{n-|J|}
+$$
+
+These agree on every term except for the term where $J=[n]$. In this case, we need to add an extra $(-1)^{n} \operatorname{gcd}(n-1,10)$ and subtract $(-1)^{n}$.
+Thus our final value for $\left|D \backslash \bigcup_{i=1}^{n} S_{i}\right|$ is $9^{n}+(-1)^{n}(\operatorname{gcd}(n-1,10)-1)$, which is $9^{36}+4$ for $n=36$.
+10. Lily has a $300 \times 300$ grid of squares. She now removes $100 \times 100$ squares from each of the four corners and colors each of the remaining 50000 squares black and white. Given that no $2 \times 2$ square is colored in a checkerboard pattern, find the maximum possible number of (unordered) pairs of squares such that one is black, one is white and the squares share an edge.
+Proposed by: Allen Liu
+Answer: 49998
+First we show an upper bound. Define a grid point as a vertex of one of the squares in the figure. Construct a graph as follows. Place a vertex at each grid point and draw an edge between two adjacent points if that edge forms a black-white boundary. The condition of there being no $2 \times 2$ checkerboard is equivalent to no vertex having degree more than 2 . There are $101^{2}+4 \cdot 99^{2}=49405$ vertices that are allowed to have degree 2 and $12 \cdot 99=1188$ vertices (on the boundary) that can have degree 1 .
+
+This gives us an upper bound of 49999 edges. We will show that exactly this many edges is impossible. Assume for the sake of contradiction that we have a configuration achieving exactly this many edges.
+
+Consider pairing up the degree 1 vertices so that those on a horizontal edge pair with the other vertex in the same column and those on a vertical edge pair with the other vertex in the same row. If we combine the pairs into one vertex, the resulting graph must have all vertices with degree exactly 2 . This means the graph must be a union of disjoint cycles. However all cycles must have even length and there are an odd number of total vertices so this is impossible. Thus we have an upper bound of 49998.
+
+We now describe the construction. The top row alternates black and white. The next 99 rows alternate between all black and all white. Lets say the second row from the top is all white. The $101^{\text {st }}$ row alternates black and white for the first 100 squares, is all black for the next 100 and alternates between white and black for the last 100 squares. The next 98 rows alternate between all black and all white (the $102^{\text {nd }}$ row is all white). Finally, the bottom 101 rows are a mirror of the top 101 rows with the colors reversed. We easily verify that this achieves the desired. We illustrate the construction for 300 replaced by 12 .
+
+
diff --git a/HarvardMIT/md/en-212-2018-feb-geo-solutions.md b/HarvardMIT/md/en-212-2018-feb-geo-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..4e77610bb348d88f489ac0f49ce27a333d5b178c
--- /dev/null
+++ b/HarvardMIT/md/en-212-2018-feb-geo-solutions.md
@@ -0,0 +1,130 @@
+# HMMT February 2018
+
+## February 10, 2018
+
+Geometry
+
+1. Triangle $G R T$ has $G R=5, R T=12$, and $G T=13$. The perpendicular bisector of $G T$ intersects the extension of $G R$ at $O$. Find $T O$.
+Proposed by: Henrik Boecken
+Answer: $\frac{169}{10}$
+First, note that $T O=G O$ as $O$ lies on the perpendicular bisector of $G T$. Then if $M$ is the midpoint of $G T$, we have that $\triangle G R T \sim \triangle G M O$, so we can compute $T O=G O=G M \cdot \frac{G T}{G R}=\frac{13}{2} \cdot \frac{13}{5}=\frac{169}{10}$.
+2. Points $A, B, C, D$ are chosen in the plane such that segments $A B, B C, C D, D A$ have lengths $2,7,5$, 12 , respectively. Let $m$ be the minimum possible value of the length of segment $A C$ and let $M$ be the maximum possible value of the length of segment $A C$. What is the ordered pair $(m, M)$ ?
+
+Proposed by: Kevin Sun
+Answer: $(7,9)$
+By the triangle inequality on triangle $A C D, A C+C D \geq A D$, or $A C \geq 7$. The minimum of 7 can be achieved when $A, C, D$ lie on a line in that order. By the triangle inequality on triangle $A B C$, $A B+B C \geq A C$, or $A C \leq 9$. The maximum of 9 can be achieved when $A, B, C$ lie on a line in that order. This gives the answer $(7,9)$.
+3. How many noncongruent triangles are there with one side of length 20 , one side of length 17 , and one $60^{\circ}$ angle?
+
+Proposed by: Dai Yang
+Answer: 2
+There are 3 possible vertices that can have an angle of $60^{\circ}$, we will name them. Call the vertex where the sides of length 20 and 17 meet $\alpha$, denote the vertex where 17 doesn't meet 20 by $\beta$, and the final vertex, which meets 20 but not 17 , we denote by $\gamma$.
+The law of cosines states that if we have a triangle, then we have the equation $c^{2}=a^{2}+b^{2}-2 a b \cos C$ where $C$ is the angle between $a$ and $b$. But $\cos 60^{\circ}=\frac{1}{2}$ so this becomes $c^{2}=a^{2}+b^{2}-a b$. We then try satisfying this equation for the 3 possible vertices and find that, for $\alpha$ the equation reads $c^{2}=400+289-340=349$ so that $c=\sqrt{349}$. For $\beta$ we find that $400=289+b^{2}-17 b$ or rather $b^{2}-17 b-111=0$ this is a quadratic, solving we find that it has two roots $b=\frac{17 \pm \sqrt{289+444}}{2}$, but since $\sqrt{733}>17$ only one of these roots is positive. We can also see that this isn't congruent to the other triangle we had, as for both the triangles the shortest side has length 17 , and so if they were congruent the lengths of all sides would need to be equal, but $18<\sqrt{349}<19$ and since $23^{2}<733$ clearly $\frac{17 \pm \sqrt{289+444}}{2}>\frac{17+23}{2}=20$ and so the triangles aren't congruent. If we try applying the law of cosines to $\gamma$ however, we get the equation $289=a^{2}+400-20 a$ which we can rewrite as $a^{2}-20 a+111=0$ which has no real solutions, as the discriminant $400-4 * 111=-44$ is negative. Thus, $\gamma$ cannot be $60^{\circ}$, and there are exactly two non congruent triangles with side lengths 20 and 17 with an angle being $60^{\circ}$.
+4. A paper equilateral triangle of side length 2 on a table has vertices labeled $A, B, C$. Let $M$ be the point on the sheet of paper halfway between $A$ and $C$. Over time, point $M$ is lifted upwards, folding the triangle along segment $B M$, while $A, B$, and $C$ remain on the table. This continues until $A$ and $C$ touch. Find the maximum volume of tetrahedron $A B C M$ at any time during this process.
+Proposed by: Dhruv Rohatgi
+Answer: $\frac{\sqrt{3}}{6}$
+
+View triangle $A B M$ as a base of this tetrahedron. Then relative to triangle $A B M$, triangle $C B M$ rotates around segment $B M$ on a hinge. Therefore the volume is maximized when $C$ is farthest from triangle $A B M$, which is when triangles $A B M$ and $C B M$ are perpendicular. The volume in this case can be calculated using the formula for the volume of a tetrahedron as $\frac{1}{6} \cdot 1 \cdot 1 \cdot \sqrt{3}=\frac{\sqrt{3}}{6}$.
+5. In the quadrilateral $M A R E$ inscribed in a unit circle $\omega, A M$ is a diameter of $\omega$, and $E$ lies on the angle bisector of $\angle R A M$. Given that triangles $R A M$ and $R E M$ have the same area, find the area of quadrilateral $M A R E$.
+Proposed by: Yuan Yao
+Answer: $\frac{8 \sqrt{2}}{9}$
+Since $A E$ bisects $\angle R A M$, we have $R E=E M$, and $E, A$ lie on different sides of $R M$. Since $A M$ is a diameter, $\angle A R M=90^{\circ}$. If the midpoint of $R M$ is $N$, then from $[R A M]=[R E M]$ and $\angle A R M=90^{\circ}$, we find $A R=N E$. Note that $O$, the center of $\omega, N$, and $E$ are collinear, and by similarity of triangles $N O M$ and $R A M, O N=\frac{1}{2} A R=\frac{1}{2} N E$. Therefore, $O N=\frac{1}{3}$ and $N E=\frac{2}{3}$. By the Pythagorean theorem on triangle $R A M, R M=\frac{4 \sqrt{2}}{3}$, Therefore, the area of $M A R E$ is $2 \cdot \frac{1}{2} \cdot \frac{4 \sqrt{2}}{3} \cdot \frac{2}{3}=\frac{8 \sqrt{2}}{9}$.
+6. Let $A B C$ be an equilateral triangle of side length 1. For a real number $0
Guts Round
+
+1. [4] A square can be divided into four congruent figures as shown:
+
+
+If each of the congruent figures has area 1 , what is the area of the square?
+Proposed by: Kevin Sun
+Answer: 4
+There are four congruent figures with area 1, so the area of the square is 4 .
+2. [4] John has a 1 liter bottle of pure orange juice. He pours half of the contents of the bottle into a vat, fills the bottle with water, and mixes thoroughly. He then repeats this process 9 more times. Afterwards, he pours the remaining contents of the bottle into the vat. What fraction of the liquid in the vat is now water?
+Proposed by: Farrell Eldrian Wu
+Answer: $\frac{5}{6}$
+All the liquid was poured out eventually. 5 liters of water was poured in, and he started with 1 liter of orange juice, so the fraction is $\frac{5}{1+5}=\frac{5}{6}$.
+3. [4] Allen and Yang want to share the numbers $1,2,3,4,5,6,7,8,9,10$. How many ways are there to split all ten numbers among Allen and Yang so that each person gets at least one number, and either Allen's numbers or Yang's numbers sum to an even number?
+Proposed by: Kevin Sun
+Answer: 1022
+Since the sum of all of the numbers is odd, exactly one of Allen's sum and Yang's sum must be odd. Therefore any way of splitting the numbers up where each person receives at least one number is valid, so the answer is $2^{10}-2=1022$.
+4. [4] Find the sum of the digits of $11 \cdot 101 \cdot 111 \cdot 110011$.
+
+Proposed by: Evan Chen
+Answer: 48
+There is no regrouping, so the answer is $2 \cdot 2 \cdot 3 \cdot 4=48$. The actual product is 13566666531 .
+5. [6] Randall proposes a new temperature system called Felsius temperature with the following conversion between Felsius ${ }^{\circ} E$, Celsius ${ }^{\circ} C$, and Fahrenheit ${ }^{\circ} F$ :
+
+$$
+{ }^{\circ} E=\frac{7 \times{ }^{\circ} C}{5}+16=\frac{7 \times{ }^{\circ} F-80}{9} .
+$$
+
+For example, $0^{\circ} C=16^{\circ} E$. Let $x, y, z$ be real numbers such that $x^{\circ} C=x^{\circ} E, y^{\circ} E=y^{\circ} F, z^{\circ} C=$ $z^{\circ} F$. Find $x+y+z$.
+Proposed by: Yuan Yao
+Answer: -120
+Notice that $(5 k)^{\circ} C=(7 k+16)^{\circ} E=(9 k+32)^{\circ} F$, so Felsius is an exact average of Celsius and Fahrenheit at the same temperature. Therefore we conclude that $x=y=z$, and it is not difficult to compute that they are all equal to -40 .
+6. [6] A bug is on a corner of a cube. A healthy path for the bug is a path along the edges of the cube that starts and ends where the bug is located, uses no edge multiple times, and uses at most two of the edges adjacent to any particular face. Find the number of healthy paths.
+Proposed by: Dhruv Rohatgi
+Answer: 6
+There are 6 symmetric ways to choose the first two edges on the path. After these are chosen, all subsequent edges are determined, until the starting corner is reached once again.
+7. [6] A triple of integers $(a, b, c)$ satisfies $a+b c=2017$ and $b+c a=8$. Find all possible values of $c$.
+
+Proposed by: Ashwin Sah
+Answer: $\quad-6,0,2,8$
+Add and subtract the two equations to find
+
+$$
+\begin{aligned}
+& (b+a)(c+1)=8+2017 \\
+& (b-a)(c-1)=2017-8
+\end{aligned}
+$$
+
+We see that $c$ is even and then that every integer $c$ with $c+1|2025, c-1| 2009$ works. We factor and solve.
+
+The full solutions are $(2017,8,0),(-667,1342,2),(-59,-346,-6),(-31,256,8)$.
+8. [6] Suppose a real number $x>1$ satisfies
+
+$$
+\log _{2}\left(\log _{4} x\right)+\log _{4}\left(\log _{16} x\right)+\log _{16}\left(\log _{2} x\right)=0
+$$
+
+Compute
+
+$$
+\log _{2}\left(\log _{16} x\right)+\log _{16}\left(\log _{4} x\right)+\log _{4}\left(\log _{2} x\right)
+$$
+
+Proposed by: Michael Tang
+Answer: $-\frac{1}{4}$
+Let $A$ and $B$ be these sums, respectively. Then
+
+$$
+\begin{aligned}
+B-A & =\log _{2}\left(\frac{\log _{16} x}{\log _{4} x}\right)+\log _{4}\left(\frac{\log _{2} x}{\log _{16} x}\right)+\log _{16}\left(\frac{\log _{4} x}{\log _{2} x}\right) \\
+& =\log _{2}\left(\log _{16} 4\right)+\log _{4}\left(\log _{2} 16\right)+\log _{16}\left(\log _{4} 2\right) \\
+& =\log _{2}\left(\frac{1}{2}\right)+\log _{4} 4+\log _{16}\left(\frac{1}{2}\right) \\
+& =(-1)+1+\left(-\frac{1}{4}\right) \\
+& =-\frac{1}{4}
+\end{aligned}
+$$
+
+Since $A=0$, we have the answer $B=-\frac{1}{4}$.
+9. [7] In a game, $N$ people are in a room. Each of them simultaneously writes down an integer between 0 and 100 inclusive. A person wins the game if their number is exactly two-thirds of the average of all the numbers written down. There can be multiple winners or no winners in this game. Let $m$ be the maximum possible number such that it is possible to win the game by writing down $m$. Find the smallest possible value of $N$ for which it is possible to win the game by writing down $m$ in a room of $N$ people.
+Proposed by: Kevin Sun
+Answer: 34
+
+Since the average of the numbers is at most 100, the winning number is an integer which is at most two-thirds of 100 , or at most 66 . This is achieved in a room with 34 people, in which 33 people pick 100 and one person picks 66 , so the average number is 99 .
+Furthermore, this cannot happen with less than 34 people. If the winning number is 66 and there are $N$ people, the sum of the numbers must be 99 . then we must have that $99 N \leq 66+100(N-1)$, which reduces to $N \geq 34$.
+10. [7] Let a positive integer $n$ be called a cubic square if there exist positive integers $a, b$ with $n=$ $\operatorname{gcd}\left(a^{2}, b^{3}\right)$. Count the number of cubic squares between 1 and 100 inclusive.
+Proposed by: Ashwin Sah
+Answer: 13
+This is easily equivalent to $v_{p}(n) \not \equiv 1,5(\bmod 6)$ for all primes $p$. We just count: $p \geq 11 \Longrightarrow v_{p}(n)=1$ is clear, so we only look at the prime factorizations with primes from $\{2,3,5,7\}$. This is easy to compute: we obtain 13 .
+11. [7] FInd the value of
+
+$$
+\sum_{k=1}^{60} \sum_{n=1}^{k} \frac{n^{2}}{61-2 n}
+$$
+
+## Proposed by: Henrik Boecken
+
+## Answer: -18910
+
+Change the order of summation and simplify the inner sum:
+
+$$
+\begin{aligned}
+\sum_{k=1}^{60} \sum_{n=1}^{k} \frac{n^{2}}{61-2 n} & =\sum_{n=1}^{60} \sum_{k=n}^{60} \frac{n^{2}}{61-2 n} \\
+& =\sum_{n=1}^{60} \frac{n^{2}(61-n)}{61-2 n}
+\end{aligned}
+$$
+
+Then, we rearrange the sum to add the terms corresponding to $n$ and $61-n$ :
+
+$$
+\begin{aligned}
+\sum_{n=1}^{60} \frac{n^{2}(61-n)}{61-2 n} & =\sum_{n=1}^{30}\left(\frac{n^{2}(61-n)}{61-2 n}+\frac{(61-n)^{2}(61-(61-n))}{61-2(61-n)}\right) \\
+& =\sum_{n=1}^{30} \frac{n^{2}(61-n)-n(61-n)^{2}}{61-2 n} \\
+& =\sum_{n=1}^{30} \frac{n(61-n)(n-(61-n))}{61-2 n} \\
+& =\sum_{n=1}^{30}-n(61-n) \\
+& =\sum_{n=1}^{30} n^{2}-61 n
+\end{aligned}
+$$
+
+Finally, using the formulas for the sum of the first $k$ squares and sum of the first $k$ positive integers, we conclude that this last sum is
+
+$$
+\frac{30(31)(61)}{6}-61 \frac{30(31)}{2}=-18910
+$$
+
+So, the original sum evaluates to -18910 .
+12. [7] $\triangle P N R$ has side lengths $P N=20, N R=18$, and $P R=19$. Consider a point $A$ on $P N . \triangle N R A$ is rotated about $R$ to $\triangle N^{\prime} R A^{\prime}$ so that $R, N^{\prime}$, and $P$ lie on the same line and $A A^{\prime}$ is perpendicular to $P R$. Find $\frac{P A}{A N}$.
+Proposed by: Henrik Boecken
+Answer: $\frac{19}{18}$
+Denote the intersection of $P R$ and $A A^{\prime}$ be $D$. Note $R A^{\prime}=R A$, so $D$, being the altitude of an isosceles triangle, is the midpoint of $A A^{\prime}$. Thus,
+
+$$
+\angle A R D=\angle A^{\prime} R D=\angle N R A
+$$
+
+so $R A$ is the angle bisector of $P N R$ through $R$. By the angle bisector theorem, we have $\frac{P A}{A N}=\frac{P R}{R N}=\frac{19}{18}$
+13. [9] Suppose $\triangle A B C$ has lengths $A B=5, B C=8$, and $C A=7$, and let $\omega$ be the circumcircle of $\triangle A B C$. Let $X$ be the second intersection of the external angle bisector of $\angle B$ with $\omega$, and let $Y$ be the foot of the perpendicular from $X$ to $B C$. Find the length of $Y C$.
+Proposed by: Caleb He
+Answer: $\frac{13}{2}$
+Extend ray $\overrightarrow{A B}$ to a point $D$, Since $B X$ is an angle bisector, we have $\angle X B C=\angle X B D=180^{\circ}-$ $\angle X B A=\angle X C A$, so $X C=X A$ by the inscribed angle theorem. Now, construct a point $E$ on $B C$ so that $C E=A B$. Since $\angle B A X \cong \angle B C X$, we have $\triangle B A X \cong \triangle E C X$ by SAS congruence. Thus, $X B=X E$, so $Y$ bisects segment $B E$. Since $B E=B C-E C=8-5=3$, we have $Y C=E C+Y E=$ $5+\frac{1}{2} \cdot 3=\frac{13}{2}$.
+(Archimedes Broken Chord Thoerem).
+14. [9] Given that $x$ is a positive real, find the maximum possible value of
+
+$$
+\sin \left(\tan ^{-1}\left(\frac{x}{9}\right)-\tan ^{-1}\left(\frac{x}{16}\right)\right)
+$$
+
+Proposed by: Yuan Yao
+Answer: $\frac{7}{25}$
+Consider a right triangle $A O C$ with right angle at $O, A O=16$ and $C O=x$. Moreover, let $B$ be on $A O$ such that $B O=9$. Then $\tan ^{-1} \frac{x}{9}=\angle C B O$ and $\tan ^{-1} \frac{x}{16}=\angle C A O$, so their difference is equal to $\angle A C B$. Note that the locus of all possible points $C$ given the value of $\angle A C B$ is part of a circle that passes through $A$ and $B$, and if we want to maximize this angle then we need to make this circle as small as possible. This happens when $O C$ is tangent to the circumcircle of $A B C$, so $O C^{2}=O A \cdot O B=144=12^{2}$, thus $x=12$, and it suffices to compute $\sin (\alpha-\beta)$ where $\sin \alpha=\cos \beta=\frac{4}{5}$ and $\cos \alpha=\sin \beta=\frac{3}{5}$. By angle subtraction formula we get $\sin (\alpha-\beta)=\left(\frac{4}{5}\right)^{2}-\left(\frac{3}{5}\right)^{2}=\frac{7}{25}$.
+15. [9] Michael picks a random subset of the complex numbers $\left\{1, \omega, \omega^{2}, \ldots, \omega^{2017}\right\}$ where $\omega$ is a primitive $2018^{\text {th }}$ root of unity and all subsets are equally likely to be chosen. If the sum of the elements in his subset is $S$, what is the expected value of $|S|^{2}$ ? (The sum of the elements of the empty set is 0 .)
+Proposed by: Nikhil Reddy
+Answer: $\frac{1009}{2}$
+Consider $a$ and $-a$ of the set of complex numbers. If $x$ is the sum of some subset of the other complex numbers, then expected magnitude squared of the sum including $a$ and $-a$ is
+
+$$
+\begin{gathered}
+\frac{(x+a)(\overline{x+a})+x \bar{x}+x \bar{x}+(x-a)(\overline{x-a})}{4} \\
+x \bar{x}+\frac{a \bar{a}}{2}
+\end{gathered}
+$$
+
+$$
+x \bar{x}+\frac{1}{2}
+$$
+
+By repeating this process on the remaining 2016 elements of the set, we can obtain a factor of $\frac{1}{2}$ every time. In total, the answer is
+
+$$
+\frac{1009}{2}
+$$
+
+16. [9] Solve for $x$ :
+
+$$
+x\lfloor x\lfloor x\lfloor x\lfloor x\rfloor\rfloor\rfloor\rfloor=122 .
+$$
+
+Proposed by: John Michael Wu
+Answer: $\frac{122}{41}$
+This problem can be done without needless casework.
+(For negative values of $x$, the left hand side will be negative, so we only need to consider positive values of $x$.)
+The key observation is that for $x \in[2,3), 122$ is an extremely large value for the expression. Indeed, we observe that:
+
+$$
+\begin{array}{rlrl}
+\lfloor x\rfloor & =2 & & =5 \\
+\lfloor x\lfloor x\rfloor\rfloor & \leq 2(3)-1 & & =14 \\
+\lfloor x\lfloor x\lfloor x\rfloor\rfloor\rfloor & \leq 3(5)-1 & =41 \\
+\lfloor x\lfloor x\lfloor x\lfloor x\rfloor\rfloor\rfloor\rfloor & \leq 3(14)-1 & =123
+\end{array}
+$$
+
+So the expression can only be as large as 122 if ALL of those equalities hold (the the fourth line equaling 40 isn't good enough), and $x=\frac{122}{41}$. Note that this value is extremely close to 3 . We may check that this value of x indeed works. Note that the expression is strictly increasing in x , so $x=\frac{122}{41}$ is the only value that works.
+17. [10] Compute the value of
+
+$$
+\frac{\cos 30.5^{\circ}+\cos 31.5^{\circ}+\ldots+\cos 44.5^{\circ}}{\sin 30.5^{\circ}+\sin 31.5^{\circ}+\ldots+\sin 44.5^{\circ}}
+$$
+
+Proposed by: Sujay Kazi
+Answer: $(\sqrt{2}-1)(\sqrt{3}+\sqrt{2})=2-\sqrt{2}-\sqrt{3}+\sqrt{6}$
+Consider a 360 -sided regular polygon with side length 1 , rotated so that its sides are at half-degree inclinations (that is, its sides all have inclinations of $0.5^{\circ}, 1.5^{\circ}, 2.5^{\circ}$, and so on. Go to the bottom point on this polygon and then move clockwise, numbering the sides $1,2,3, \ldots, 360$ as you go. Then, take the section of 15 sides from side 31 to side 45 . These sides have inclinations of $30.5^{\circ}, 31.5^{\circ}, 32.5^{\circ}$, and so on, up to $44.5^{\circ}$. Therefore, over this section, the horizontal and vertical displacements are, respectively:
+
+$$
+\begin{aligned}
+& H=\cos 30.5^{\circ}+\cos 31.5^{\circ}+\ldots+\cos 44.5^{\circ} \\
+& V=\sin 30.5^{\circ}+\sin 31.5^{\circ}+\ldots+\sin 44.5^{\circ}
+\end{aligned}
+$$
+
+However, we can also see that, letting $R$ be the circumradius of this polygon:
+
+$$
+\begin{gathered}
+H=R\left(\sin 45^{\circ}-\sin 30^{\circ}\right) \\
+V=R\left[\left(1-\cos 45^{\circ}\right)-\left(1-\cos 30^{\circ}\right)\right]
+\end{gathered}
+$$
+
+From these, we can easily compute that our desired answer is $\frac{H}{V}=(\sqrt{2}-1)(\sqrt{3}+\sqrt{2})=2-\sqrt{2}-\sqrt{3}+\sqrt{6}$.
+18. [10] Compute the number of integers $n \in\{1,2, \ldots, 300\}$ such that $n$ is the product of two distinct primes, and is also the length of the longest leg of some nondegenerate right triangle with integer side lengths.
+Proposed by:
+Answer: 13
+Let $n=p \cdot q$ for primes $pp q$, so there are no solutions.
+(b) $c-a=p$ and $c+a=p q^{2}$ : Then $a=\frac{p q^{2}-p}{2}>p q$.
+(c) $c-a=p^{2}$ and $c+a=q^{2}$. Then $a=\frac{q^{2}-p^{2}}{2}$ which we require to be less than $p q$. This is equivalent to
+
+$$
+\begin{aligned}
+\frac{q^{2}-p^{2}}{2} &
February 10, 2018
Team Round
+
+1. [20] In an $n \times n$ square array of $1 \times 1$ cells, at least one cell is colored pink. Show that you can always divide the square into rectangles along cell borders such that each rectangle contains exactly one pink cell.
+
+Proposed by: Kevin Sun
+We claim that the statement is true for arbitrary rectangles. We proceed by induction on the number of marked cells. Our base case is $k=1$ marked cell, in which case the original rectangle works.
+
+To prove it for $k$ marked cells, we split the rectangle into two smaller rectangles, both of which contains at least one marked cell. By induction, we can divide the two smaller rectangles into rectangles with exactly one marked cell. Combining these two sets of rectangles gives a way to divide our original rectangle into rectangles with exactly one marked cell, completing the induction.
+2. [25] Is the number
+
+$$
+\left(1+\frac{1}{2}\right)\left(1+\frac{1}{4}\right)\left(1+\frac{1}{6}\right) \ldots\left(1+\frac{1}{2018}\right)
+$$
+
+greater than, less than, or equal to 50 ?
+Proposed by: Henrik Boecken
+Call the expression $S$. Note that
+
+$$
+\left(1+\frac{1}{2}\right)\left(1+\frac{1}{4}\right)\left(1+\frac{1}{6}\right) \ldots\left(1+\frac{1}{2018}\right)<\left(1+\frac{1}{1}\right)\left(1+\frac{1}{3}\right)\left(1+\frac{1}{5}\right) \ldots\left(1+\frac{1}{2017}\right)
+$$
+
+Multiplying these two products together, we get
+
+$$
+\begin{aligned}
+& \left(1+\frac{1}{1}\right)\left(1+\frac{1}{2}\right)\left(1+\frac{1}{3}\right) \ldots\left(1+\frac{1}{2018}\right) \\
+& =\frac{2}{1} \cdot \frac{3}{2} \cdot \frac{4}{3} \cdots \frac{2019}{2018} \\
+& =2019
+\end{aligned}
+$$
+
+This shows that
+
+$$
+S^{2}<2019 \Longrightarrow S<\sqrt{2019}<50
+$$
+
+as desired.
+3. [30] Michelle has a word with $2^{n}$ letters, where a word can consist of letters from any alphabet. Michelle performs a switcheroo on the word as follows: for each $k=0,1, \ldots, n-1$, she switches the first $2^{k}$ letters of the word with the next $2^{k}$ letters of the word. For example, for $n=3$, Michelle changes
+
+$$
+A B C D E F G H \rightarrow B A C D E F G H \rightarrow C D B A E F G H \rightarrow E F G H C D B A
+$$
+
+in one switcheroo.
+In terms of $n$, what is the minimum positive integer $m$ such that after Michelle performs the switcheroo operation $m$ times on any word of length $2^{n}$, she will receive her original word?
+
+## Proposed by: Mehtaab Sawhney
+
+Let $m(n)$ denote the number of switcheroos needed to take a word of length $2^{n}$ back to itself. Consider a word of length $2^{n}$ for some $n>1$. After 2 switcheroos, one has separately performed a switcheroo on the first half of the word and on the second half of the word, while returning the (jumbled) first half of the word to the beginning and the (jumbled) second half of the word to the end.
+
+After $2 \cdot m(n-1)$ switcheroos, one has performed a switcheroo on each half of the word $m(n-1)$ times while returning the halves to their proper order. Therefore, the word is in its proper order. However, it is never in its proper order before this, either because the second half precedes the first half (i.e. after an odd number of switcheroos) or because the halves are still jumbled (because each half has had fewer than $m(n-1)$ switcheroos performed on it).
+
+It follows that $m(n)=2 m(n-1)$ for all $n>1$. We can easily see that $m(1)=2$, and a straightforward proof by induction shows that $m=2^{n}$.
+4. [30] In acute triangle $A B C$, let $D, E$, and $F$ be the feet of the altitudes from $A, B$, and $C$ respectively, and let $L, M$, and $N$ be the midpoints of $B C, C A$, and $A B$, respectively. Lines $D E$ and $N L$ intersect at $X$, lines $D F$ and $L M$ intersect at $Y$, and lines $X Y$ and $B C$ intersect at $Z$. Find $\frac{Z B}{Z C}$ in terms of $A B, A C$, and $B C$.
+
+## Proposed by: Faraz Masroor
+
+Because $N L \| A C$ we have triangles $D X L$ and $D E C$ are similar. From angle chasing, we also have that triangle $D E C$ is similar to triangle $A B C$. We have $\angle X N A=180^{\circ}-\angle X N B=180^{\circ}-\angle L N B=$ $180-C A B=\angle L M A$. In addition, we have $\frac{N X}{N A}=\frac{X D \cdot X E}{X L \cdot N A}=\frac{A B}{B C} \frac{X E}{L C} \frac{N M}{N A}=\frac{A B}{B C} \frac{E D}{D C} \frac{B C}{A B}=\frac{E D}{D C}=\frac{A B}{A C}=$ $\frac{M L}{M A}$. These two statements mean that triangles $A N X$ and $A M L$ are similar, and $\angle X A B=\angle X A N=$ $\angle L A M=\angle L A C$. Similarly, $\angle X A Y=\angle L A C$, making $A, X$, and $Y$ collinear, with $\angle Y A B=\angle X A B=$ $\angle L A C$; ie. line $A X Y$ is a symmedian of triangle $A B C$.
+Then $\frac{Z B}{Z C}=\frac{A B}{A C} \frac{\sin \angle Z A B}{\sin \angle Z A C}=\frac{A B}{A C} \frac{\sin \angle L A C}{\sin \angle L A B}$, by the ratio lemma. But using the ratio lemma, $1=\frac{L B}{L C}=$ $\frac{A B}{A C} \frac{\sin \angle L A B}{\sin \angle L A C}$, so $\frac{\sin \angle L A C}{\sin \angle L A B}=\frac{A B}{A C}$, so $\frac{Z B}{Z C}=\frac{A B^{2}}{A C^{2}}$.
+5. [30] Is it possible for the projection of the set of points $(x, y, z)$ with $0 \leq x, y, z \leq 1$ onto some two-dimensional plane to be a simple convex pentagon?
+Proposed by: Yuan Yao
+It is not possible. Consider $P$, the projection of $\left(\frac{1}{2}, \frac{1}{2}, \frac{1}{2}\right)$ onto the plane. Since for any point $(x, y, z)$ in the cube, $(1-x, 1-y, 1-z)$ is also in the cube, and the midpoint of their projections will be the projection of their midpoint, which is $P$, the projection of the cube onto this plane will be a centrally symmetric region around $P$, and thus cannot be a pentagon.
+6. [35] Let $n \geq 2$ be a positive integer. A subset of positive integers $S$ is said to be comprehensive if for every integer $0 \leq x
HMIC 2018
+
+1. [6] Let $m>1$ be a fixed positive integer. For a nonempty string of base-ten digits $S$, let $c(S)$ be the number of ways to split $S$ into contiguous nonempty strings of digits such that the base-ten number represented by each string is divisible by $m$. These strings are allowed to have leading zeroes.
+In terms of $m$, what are the possible values that $c(S)$ can take?
+For example, if $m=2$, then $c(1234)=2$ as the splits 1234 and $12 \mid 34$ are valid, while the other six splits are invalid.
+Proposed by: Kevin Sun
+Answer: 0 and $2^{n}$ for all nonnegative integer $n$
+First, we note that $c(1)=0$ and $c(00 \ldots 0)=2^{n-1}$ if there are $n$ zeroes in the string. Now we show that these are the only possibilities. Note that a split can be added if and only if the string before this split (ignoring all other splits) represent a multiple of $m$ (if there is a split before it, then removing the digits before this preceding split is equivalent to subtracting the removed number times a power of 10 , which will also be a multiple of $m$, so the remaining number between the two splits remain a multiple of $m$ ). Thus, whether we can add a split or not depends only on the string itself and no other splits, so $c(S)$ is 0 if the number is not divisible by $m$ and a power of two otherwise.
+2. [7] Consider a finite set of points $T \in \mathbb{R}^{n}$ contained in the $n$-dimensional unit ball centered at the origin, and let $X$ be the convex hull of $T$. Prove that for all positive integers $k$ and all points $x \in X$, there exist points $t_{1}, t_{2}, \ldots, t_{k} \in T$, not necessarily distinct, such that their centroid
+
+$$
+\frac{t_{1}+t_{2}+\cdots+t_{k}}{k}
+$$
+
+has Euclidean distance at most $\frac{1}{\sqrt{k}}$ from $x$.
+(The $n$-dimensional unit ball centered at the origin is the set of points in $\mathbb{R}^{n}$ with Euclidean distance at most 1 from the origin. The convex hull of a set of points $T \in \mathbb{R}^{n}$ is the smallest set of points $X$ containing $T$ such that each line segment between two points in $X$ lies completely inside $X$.)
+
+## Proposed by: Henrik Boecken
+
+By the definition of convex hull, we can write $x=\sum_{i=1}^{m} \lambda_{i} z_{i}$, where each $z_{i} \in T$, each $\lambda_{i} \geq 0$ and $\sum_{i=1}^{m} \lambda_{i}=1$. Consider then a random variable $Z$ that takes on value $z_{i}$ with probability $\lambda_{i}$. We have $\mathbb{E}[Z]=x$. Let $\bar{Z}=\frac{1}{k} \sum_{i=1}^{k} Z_{i}$, where each $Z_{i}$ is an independent copy of $Z$. Then we wish to compute
+
+$$
+\operatorname{Var}[\bar{Z}]=\frac{1}{k^{2}} \sum_{i=1}^{k} \operatorname{Var}\left[Z_{i}\right]
+$$
+
+Finally, we have
+
+$$
+\operatorname{Var}\left[Z_{i}\right]=\mathbb{E}\left[\left\|Z_{i}-x\right\|^{2}\right]=\mathbb{E}\left[\left\|Z_{i}\right\|^{2}\right]-x^{2} \leq \mathbb{E}\left[\left\|Z_{i}\right\|^{2}\right] \leq 1
+$$
+
+The second equality follows from the identity $\operatorname{Var}[X]=\mathbb{E}\left[X^{2}\right]-\mathbb{E}[X]^{2}$. Now, we know that
+
+$$
+\mathbb{E}\left[\left\|x-\frac{1}{k} \sum_{i=1}^{k} Z_{i}\right\|^{2}\right]=\operatorname{Var}[\bar{Z}] \leq \frac{1}{k}
+$$
+
+Thus, there must exist some realization of $x_{i}$ of the $Z_{i}$ such that
+
+$$
+\left\|x-\frac{1}{k} \sum_{i=1}^{k} x_{i}\right\|^{2} \leq \frac{1}{k}
+$$
+
+and we are done.
+3. [8] A polygon in the plane (with no self-intersections) is called equitable if every line passing through the origin divides the polygon into two (possibly disconnected) regions of equal area.
+Does there exist an equitable polygon which is not centrally symmetric about the origin?
+(A polygon is centrally symmetric about the origin if a 180-degree rotation about the origin sends the polygon to itself.)
+Proposed by: Kevin Sun
+Consider the polygon with vertices
+
+$$
+\begin{aligned}
+& A(1,0), B(0,1), C(0,5), D(5,0), E(7,0) \\
+& F(0,-7), G(-7,0), H(-\sqrt{84}, 0), I(0, \sqrt{84}), J(0,6) \\
+& K(-6,0), L(-5,0), M(0,-5), N(0,-1)
+\end{aligned}
+$$
+
+Notice that its intersection with each of the four quadrants are all trapezoids with angles $45^{\circ}, 45^{\circ}, 135^{\circ}, 135^{\circ}$, and the trapezoids in quadrant 1 and 3 both have area $\frac{5^{2}-1^{2}}{2}=\frac{7^{2}-5^{2}}{2}=12$, and the trapezoids in quadrant 2 and 4 both have area $\frac{7^{2}-1^{2}}{2}=\frac{84-6^{2}}{2}=24$, so by similar triangles, we can show that this polygon is indeed equitable. It is also apparent that this polygon is not centrally symmetric.
+4. [10] Find all functions $f: \mathbb{R}^{+} \rightarrow \mathbb{R}^{+}$such that
+
+$$
+f(x+f(y+x y))=(y+1) f(x+1)-1
+$$
+
+for all $x, y \in \mathbb{R}^{+}$.
+( $\mathbb{R}^{+}$denotes the set of positive real numbers.)
+Proposed by: Ashwin Sah
+Let $P(x, y)$ denote the assertion that
+
+$$
+f(x+f(y+x y))=(y+1) f(x+1)-1 .
+$$
+
+Claim 1. $f$ is injective. Proof: If $f(a)=f(b)$ then $P\left(x, \frac{a}{x+1}\right), P\left(x, \frac{b}{x+1}\right)$ yields $a=b$, since $f(x+1) \in \mathbb{R}^{+}$so in particular is nonzero. ○ Now $P\left(x, \frac{1}{f(x+1)}\right)$ yields
+
+$$
+f\left(x+f\left(\frac{x+1}{f(x+1)}\right)\right)=f(x+1)
+$$
+
+hence by injectivity
+
+$$
+x+f\left(\frac{x+1}{f(x+1)}\right)=x+1
+$$
+
+so that
+
+$$
+f\left(\frac{x+1}{f(x+1)}\right)=1
+$$
+
+By injectivity, this equals some constant $c$, so that
+
+$$
+\frac{x+1}{f(x+1)}=c
+$$
+
+for all $x \in \mathbb{R}^{+}$. Now letting $x, y>1$ in $P(x, y)$ automatically yields
+
+$$
+\frac{x}{c}+\frac{y+x y}{c^{2}}=(y+1)\left(\frac{x+1}{c}\right)-1
+$$
+
+which immediately yields $c=1$ if we take $x, y$ large. Finally, we have $f(x+1)=x+1 \forall x \in \mathbb{R}^{+}$. Finally, $P\left(x, \frac{y}{x+1}\right)$ yields
+
+$$
+f(x+f(y))=\left(\frac{y}{x+1}+1\right) f(x+1)-1=x+y
+$$
+
+so that fixing $y$ and letting $x>1$ yields
+
+$$
+x+f(y)=x+y
+$$
+
+so that $f(y)=y$. This was for arbitrary positive $y$, so that $f(x)=x \forall x \in \mathbb{R}^{+}$, which clearly works.
+5. [11] Let $G$ be an undirected simple graph. Let $f(G)$ be the number of ways to orient all of the edges of $G$ in one of the two possible directions so that the resulting directed graph has no directed cycles. Show that $f(G)$ is a multiple of 3 if and only if $G$ has a cycle of odd length.
+Proposed by: Yang Liu
+Let $f_{G}(q)$ be the number of ways to color $G$ with $q$ colors. This is the chromatic polynomial of $G$, and turns out to be polynomial in $q$. Indeed, choose an edge $e$ and let $G \backslash e$ be the graph $G$ with $e$ removed and let $G / e$ be graph $G$ with the vertices on either side of $e$ merged together (multiple edges are removed). It is not hard to see that
+
+$$
+f_{G}(q)=f_{G \backslash e}(q)-f_{G / e}(q)
+$$
+
+and that for an empty graph $E_{n}$ with $n$ vertices, we have $f_{E_{n}}(q)=q^{n}$. Induction finishes.
+Now we can also show that the desired number of ways to direct $G$ to avoid directed cycles is $c_{G}=$ $(-1)^{n} f_{G}(-1)$ where $n$ is the number of vertices of $G$. The way to do it is to show that
+
+$$
+c_{G}=c_{G \backslash e}+c_{G / e}
+$$
+
+and $c_{E_{n}}=1$. Thus $(-1)^{n} c_{G}$ will satisfy the desired recurrence, after multiplying the above by $(-1)^{n}$, and satisfies the correct initial conditions.
+Now all we need to know is that $f_{G}(q)$ has integer coefficients, so that $(-1)^{n} c_{G} \equiv f_{G}(-1) \equiv f_{G}(2)$ $(\bmod 3)$, and $f_{G}(2)=0$ when $G$ is not bipartite and is $2^{c(G)}$ where $c(G)$ is the number of connected components of $G$ otherwise. The result follows.
+
diff --git a/HarvardMIT/md/en-22-1999-feb-adv-solutions.md b/HarvardMIT/md/en-22-1999-feb-adv-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..3f8568fed1204213a8c28ad1fc87e4d474060a4c
--- /dev/null
+++ b/HarvardMIT/md/en-22-1999-feb-adv-solutions.md
@@ -0,0 +1,62 @@
+# Advanced Topics Solutions
+
+Harvard-MIT Math Tournament
February 27, 1999
+
+Problem AT1 [3 points]
+
+One of the receipts for a math tournament showed that 72 identical trophies were purchased for $\$-99.9-$, where the first and last digits were illegible. How much did each trophy cost?
+
+Solution: The price must be divisible by 8 and 9 . Thus the last 3 digits must be divisible by 8 , so the price ends with 992 , and the first digit must be 7 to make the total divisible by 9 . $\$ 799.92 / 72=\$ 11.11$.
+
+## Problem AT2 [3 points]
+
+Stacy has $d$ dollars. She enters a mall with 10 shops and a lottery stall. First she goes to the lottery and her money is doubled, then she goes into the first shop and spends 1024 dollars. After that she alternates playing the lottery and getting her money doubled (Stacy always wins) then going into a new shop and spending $\$ 1024$. When she comes out of the last shop she has no money left. What is the minimum possible value of $d$ ?
+
+Solution: Work backwards. Before going into the last shop she had $\$ 1024$, before the lottery she had $\$ 512$, then $\$ 1536, \$ 768, \ldots$. We can easily prove by induction that if she ran out of money after $n$ shops, $0 \leq n \leq 10$, she must have started with $1024-2^{10-n}$ dollars. Therefore $d$ is $\mathbf{1 0 2 3}$.
+
+## Problem AT3 [4 points]
+
+An unfair coin has the property that when flipped four times, it has the same probability of turning up 2 heads and 2 tails (in any order) as 3 heads and 1 tail (in any order). What is the probability of getting a head in any one flip?
+
+Solution: Let $p$ be the probability of getting a head in one flip. There are 6 ways to get 2 heads and 2 tails, each with probability $p^{2}(1-p)^{2}$, and 4 ways to get 3 heads and 1 tail, each with probability $p^{3}(1-p)$. We are given that $6 p^{2}(1-p)^{2}=4 p^{3}(1-p)$. Clearly $p$ is not 0 or 1 , so we can divide by $p^{2}(1-p)$ to get $6(1-p)=4 p$. Therefore $p$ is $\frac{3}{5}$.
+
+## Problem AT4 [4 points]
+
+You are given 16 pieces of paper numbered $16,15, \ldots, 2,1$ in that order. You want to put them in the order $1,2, \ldots, 15,16$ switching only two adjacent pieces of paper at a time. What is the minimum number of switches necessary?
+
+Solution: Piece 16 has to move to the back 15 times, piece 15 has to move to the back 14 times, $\ldots$. piece 2 has to move to the back 1 time, piece 1 has to move to the back 0 times. Since only one piece can move back in each switch, we must have at least $15+14+\ldots+1=\mathbf{1 2 0}$ switches.
+
+For any finite set $S$, let $f(S)$ be the sum of the elements of $S$ (if $S$ is empty then $f(S)=0$ ). Find the sum over all subsets $E$ of $S$ of $\frac{f(E)}{f(S)}$ for $S=\{1,2, \ldots, 1999\}$.
+
+Solution: An $n$ element set has $2^{n}$ subsets, so each element of $S$ appears in $2^{1998}$ subsets $E$, so our sum is $2^{1998} \cdot \frac{1+2+\ldots+1999}{1+2+\ldots+1999}=\mathbf{2}^{1998}$.
+
+## Problem AT6 [5 points]
+
+Matt has somewhere between 1000 and 2000 pieces of paper he's trying to divide into piles of the same size (but not all in one pile or piles of one sheet each). He tries $2,3,4,5,6,7$, and 8 piles but ends up with one sheet left over each time. How many piles does he need?
+
+Solution: The number of sheets will leave a remainder of 1 when divided by the least common multiple of $2,3,4,5,6,7$, and 8 , which is $8 \cdot 3 \cdot 5 \cdot 7=840$. Since the number of sheets is between 1000 and 2000 , the only possibility is 1681 . The number of piles must be a divisor of $1681=41^{2}$, hence it must be 41 .
+
+## Problem AT7 [5 points]
+
+Find an ordered pair $(a, b)$ of real numbers for which $x^{2}+a x+b$ has a non-real root whose cube is 343 .
+
+Solution: The cube roots of 343 are the roots of $x^{3}-343$, which is $(x-7)\left(x^{2}+7 x+49\right)$. Therefore the ordered pair we want is $(\mathbf{7}, 49)$.
+
+Problem AT8 [6 points]
+
+Let $C$ be a circle with two diameters intersecting at an angle of 30 degrees. A circle $S$ is tangent to both diameters and to $C$, and has radius 1 . Find the largest possible radius of $C$.
+
+Solution: For $C$ to be as large as possible we want $S$ to be as small as possible. It is not hard to see that this happens in the situation shown below. Then the radius of $C$ is $1+\csc 15=\mathbf{1}+\sqrt{\mathbf{2}}+\sqrt{\mathbf{6}}$. The computation of $\sin 15$ can be done via the half angle formula.
+
+
+Problem AT9 [7 points]
+
+As part of his effort to take over the world, Edward starts producing his own currency. As part of an effort to stop Edward, Alex works in the mint and produces 1 counterfeit coin for every 99 real ones. Alex isn't very good at this, so none of the counterfeit coins are the right weight. Since the mint is not perfect, each coin is weighed before leaving. If the coin is not the right weight, then it is sent to a lab for testing. The scale is accurate $95 \%$ of the time, $5 \%$ of all the coins minted are sent to the lab, and the lab's test is accurate $90 \%$ of the time. If the lab says a coin is counterfeit, what is the probability that it really is?
+
+Solution: $5 \%$ of the coins are sent to the lab, and only . $95 \%$ of the coins are sent to the lab and counterfeit, so there is a $19 \%$ chance that a coin sent to the lab is counterfeit and an $81 \%$ chance that it is real. The lab could correctly detect a counterfeit coin or falsely accuse a real one of being counterfeit, so the probability that a coin the lab says is counterfeit really is counterfeit is $\frac{19 / 100 \cdot 9 / 10}{19 / 100 \cdot 9 / 10+81 / 100 \cdot 1 / 10}=\frac{19}{\mathbf{2 8}}$.
+
+## Problem AT10 [8 points]
+
+Find the minimum possible value of the largest of $x y, 1-x-y+x y$, and $x+y-2 x y$ if $0 \leq x \leq y \leq 1$.
+Solution: I claim the answer is $4 / 9$. Let $s=x+y, p=x y$, so $x$ and $y$ are $\frac{s \pm \sqrt{s^{2}-4 p}}{2}$. Since $x$ and $y$ are real, $s^{2}-4 p \geq 0$. If one of the three quantities is less than or equal to $1 / 9$, then at least one of the others is at least $4 / 9$ by the pigeonhole principle since they add up to 1 . Assume that $s-2 p<4 / 9$, then $s^{2}-4 p<(4 / 9+2 p)^{2}-4 p$, and since the left side is non-negative we get $0 \leq p^{2}-\frac{5}{9} p+\frac{4}{81}=\left(p-\frac{1}{9}\right)\left(p-\frac{4}{9}\right)$. This implies that either $p \leq \frac{1}{9}$ or $p \geq \frac{4}{9}$, and either way we're done. This minimum is achieved if $x$ and $y$ are both $1 / 3$, so the answer is $\frac{4}{9}$, as claimed.
+
diff --git a/HarvardMIT/md/en-22-1999-feb-alg-solutions.md b/HarvardMIT/md/en-22-1999-feb-alg-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..47e95d237f893db141ede762c03239841be0060b
--- /dev/null
+++ b/HarvardMIT/md/en-22-1999-feb-alg-solutions.md
@@ -0,0 +1,88 @@
+# Algebra Solutions
+
+Harvard-MIT Math Tournament
+
+February 27, 1999
+
+## Problem A1 [3 points]
+
+If $a @ b=\frac{a^{3}-b^{3}}{a-b}$, for how many real values of $a$ does $a @ 1=0$ ?
+Solution: If $\frac{a^{3}-1}{a-1}=0$, then $a^{3}-1=0$, or $(a-1)\left(a^{2}+a+1\right)=0$. Thus $a=1$, which is an extraneous solution since that makes the denominator of the original expression 0 , or $a$ is a root of $a^{2}+a+1$. But this quadratic has no real roots, in particular its roots are $\frac{-1 \pm \sqrt{-3}}{2}$. Therefore there are no such real values of $a$, so the answer is $\mathbf{0}$.
+
+## Problem A2 [3 points]
+
+For what single digit $n$ does 91 divide the 9 -digit number $12345 n 789$ ?
+Solution 1: 123450789 leaves a remainder of 7 when divided by 91 , and 1000 leaves a remainder of 90 , or -1 , so adding 7 multiples of 1000 will give us a multiple of 91 .
+
+Solution 2: For those who don't like long division, there is a quicker way. First notice that $91=7 \cdot 13$, and $7 \cdot 11 \cdot 13=1001$. Observe that $12345 n 789=123 \cdot 1001000+45 n \cdot 1001-123 \cdot 1001+123-45 n+789$ It follows that 91 will divide $12345 n 789$ iff 91 divides $123-45 n+789=462-n$. The number 462 is divisible by 7 and leaves a remainder of $\mathbf{7}$ when divided by 13 .
+
+## Problem A3 [4 points]
+
+Alex is stuck on a platform floating over an abyss at $1 \mathrm{ft} / \mathrm{s}$. An evil physicist has arranged for the platform to fall in (taking Alex with it) after traveling 100ft. One minute after the platform was launched, Edward arrives with a second platform capable of floating all the way across the abyss. He calculates for 5 seconds, then launches the second platform in such a way as to maximize the time that one end of Alex's platform is between the two ends of the new platform, thus giving Alex as much time as possible to switch. If both platforms are 5 ft long and move with constant velocity once launched, what is the speed of the second platform (in $\mathrm{ft} / \mathrm{s}$ )?
+
+Solution: The slower the second platform is moving, the longer it will stay next to the first platform. However, it needs to be moving fast enough to reach the first platform before it's too late. Let $v$ be the velocity of the second platform. It starts 65 feet behind the first platform, so it reaches the back of the first platform at $\frac{60}{v-1}$ seconds, and passes the front at $\frac{70}{v-1}$ seconds, so the time to switch is $\frac{10}{v-1}$. Hence we want $v$ to be as small as possible while still allowing the switch before the first platform falls. Therefore the time to switch will be maximized if the back of the second platform lines up with the front of the first platform at the instant that the first platform has travelled 100ft, which occurs after 100 seconds. Since the second platform is launched 65 seconds later and has to travel 105 feet, its speed is $105 / 35=\mathbf{3 f t} / \mathrm{s}$.
+
+## Problem A4 [4 points]
+
+Find all possible values of $\frac{d}{a}$ where $a^{2}-6 a d+8 d^{2}=0, a \neq 0$.
+
+Solution: Dividing $a^{2}-6 a d+8 d^{2}=0$ by $a^{2}$, we get $1-6 \frac{d}{a}+8\left(\frac{d}{a}\right)^{2}=0$. The roots of this quadratic are $\frac{1}{2}, \frac{1}{4}$.
+
+## Problem A5 [5 points]
+
+You are trapped in a room with only one exit, a long hallway with a series of doors and land mines. To get out you must open all the doors and disarm all the mines. In the room is a panel with 3 buttons, which conveniently contains an instruction manual. The red button arms a mine, the yellow button disarms two mines and closes a door, and the green button opens two doors. Initially 3 doors are closed and 3 mines are armed. The manual warns that attempting to disarm two mines or open two doors when only one is armed/closed will reset the system to its initial state. What is the minimum number of buttons you must push to get out?
+
+Solution: Clearly we do not want to reset the system at any time. After pressing the red button $r$ times, the yellow button $y$ times, and the green button $g$ times, there will be $3+r-2 y$ armed mines and $3+y-2 g$ closed doors, so we want the values of $r, y$, and $g$ that make both of these quantities 0 while minimizing $r+y+g$. From the number of doors we see that $y$ must be odd, from the number of mines we see $y=(3+r) / 2 \geq 3 / 2$, so $y \geq 3$. Then $g=(3+y) / 2 \geq 3$, and $r=2 y-3 \geq 3$, so $r+y+g \geq 9$. Call the red, yellow, and green buttons 1,2 , and 3 respectively for notational convenience, then a sequence of buttons that would get you out is 123123123. Another possibility is 111222333 , and of course there are others. Therefore the answer is 9 .
+
+## Problem A6 [5 points]
+
+Carl and Bob can demolish a building in 6 days, Anne and Bob can do it in 3, Anne and Carl in 5. How many days does it take all of them working together if Carl gets injured at the end of the first day and can't come back? Express your answer as a fraction in lowest terms.
+
+Solution: Let $a$ be the portion of the work that Anne does in one day, similarly $b$ for Bob and $c$ for Carl. Then what we are given is the system of equations $b+c=1 / 6, a+b=1 / 3$, and $a+c=1 / 5$. Thus in the first day they complete $a+b+c=\frac{1}{2}(1 / 6+1 / 3+1 / 5)=7 / 20$, leaving $13 / 20$ for Anne and Bob to complete. This takes $\frac{13 / 20}{1 / 3}=39 / 20$ days, for a total of $\frac{\mathbf{5 9}}{\mathbf{2 0}}$.
+
+## Problem A7 [5 points]
+
+Matt has somewhere between 1000 and 2000 pieces of paper he's trying to divide into piles of the same size (but not all in one pile or piles of one sheet each). He tries $2,3,4,5,6,7$, and 8 piles but ends up with one sheet left over each time. How many piles does he need?
+
+Solution: The number of sheets will leave a remainder of 1 when divided by the least common multiple of $2,3,4,5,6,7$, and 8 , which is $8 \cdot 3 \cdot 5 \cdot 7=840$. Since the number of sheets is between 1000 and 2000, the only possibility is 1681 . The number of piles must be a divisor of $1681=41^{2}$, hence it must be 41 .
+
+## Problem A8 [6 points]
+
+If $f(x)$ is a monic quartic polynomial such that $f(-1)=-1, f(2)=-4, f(-3)=-9$, and $f(4)=-16$, find $f(1)$.
+
+Solution: The given data tells us that the roots of $f(x)+x^{2}$ are $-1,2,-3$, and 4 . Combining with the fact that $f$ is monic and quartic we get $f(x)+x^{2}=(x+1)(x-2)(x+3)(x-4)$. Hence $f(1)=(2)(-1)(4)(-3)-1=\mathbf{2 3}$.
+
+## Problem A9 [7 points]
+
+How many ways are there to cover a $3 \times 8$ rectangle with 12 identical dominoes?
+Solution: Trivially there is 1 way to tile a $3 \times 0$ rectangle, and it is not hard to see there are 3 ways to tile a $3 \times 2$. Let $T_{n}$ be the number of tilings of a $3 \times n$ rectangle, where $n$ is even. From the diagram below we see the recursion $T_{n}=3 T_{n-2}+2\left(T_{n-4}+T_{n-6}+\ldots+T_{2}+T_{0}\right)$. Given that, we can just calculate $T_{4}=11, T_{6}=41$, and $T_{8}$ is $\mathbf{1 5 3}$.
+
+etc...
+
+Problem A10 [8 points]
+
+Pyramid $E A R L Y$ is placed in $(x, y, z)$ coordinates so that $E=(10,10,0), A=(10,-10,0), R=$ $(-10,-10,0), L=(-10,10,0)$, and $Y=(0,0,10)$. Tunnels are drilled through the pyramid in such a way that one can move from $(x, y, z)$ to any of the 9 points $(x, y, z-1),(x \pm 1, y, z-1)$, $(x, y \pm 1, z-1),(x \pm 1, y \pm 1, z-1)$. Sean starts at $Y$ and moves randomly down to the base of the pyramid, choosing each of the possible paths with probability $\frac{1}{9}$ each time. What is the probability that he ends up at the point $(8,9,0)$ ?
+
+Solution 1: Start by figuring out the probabilities of ending up at each point on the way down the pyramid. Obviously we start at the top vertex with probability 1, and each point on the next level down with probability $1 / 9$. Since each probability after $n$ steps will be some integer over $9^{n}$, we will look only at those numerators. The third level down has probabilities as shown below. Think of this as what you would see if you looked at the pyramid from above, and peeled off the top two layers.
+
+12321
+24642
+36963
+24642
+12321
+
+What we can observe here is not only the symmetry along vertical, horizontal, and diagonal axes, but also that each number is the product of the numbers at the ends of its row and column (e.g. $6=2 \cdot 3$ ). This comes from the notion of independence of events, i.e. that if we east and then south, we end up in the same place as if we had moved south and then east. Since we are only looking for the probability of ending up at $(8,9,0)$, we need only know that this is true for the top two rows of the square of probabilities, which depend only on the top two rows of the previous layer. This will follow from the calculation of the top row of each square, which we can do via an algorithm similar to Pascal's triangle. In the diagram below, each element is the sum of the 3 above it.
+
+```
+ 1
+ 1 1 1
+ 1 2 3 3 1
+ 1 3 6 7 6 % 1
+ 1410161916104 1
+```
+
+ 151530455145301551
+ Now observe that the first 3 numbers in row $n$, where the top is row 0 , are $1, n, \frac{n(n+1)}{2}$. This fact is easily proved by induction on $n$, so the details are left to the reader. Now we can calculate the top two rows of each square via another induction argument, or by independence, to establish that the second row is always $n$ times the first row. Therefore the probability of ending up at the point $(8,9,0)$ is $\frac{\mathbf{5 5 0}}{\mathbf{9}^{10}}$.
+
+Solution 2: At each move, the $x$ and $y$ coordinates can each increase by 1 , decrease by 1 , or stay the same. The $y$ coordinate must increase 9 times and stay the same 1 times, the $x$ coordinate can either increase 8 times and stay the same 1 time or decrease 1 time and increase 9 times. Now we consider every possible case. First consider the cases where the $x$ coordinate decreases once. If the $x$ coordinate decreases while the $y$ coordinate increases, then we have 8 moves that are the same and 2 that are different, which can be done in $\frac{10!}{8!}=90$ ways. If the $x$ coordinate decreases while the $y$ coordinate stays the same, then we have 9 moves that are the same and 1 other, which can be done in $\frac{10!}{9!}=10$ ways. Now consider the cases where the $x$ coordinate stays the same twice. If the $y$ coordinate stays the same while the $x$ coordinate increases, then we have 7 moves that are the same, 2 that are the same, and 1 other, which can be done in $\frac{10!}{7!2!}=360$ ways. If the $y$ coordinate stays the same while the $x$ coordinate stays the same, then we have 8 moves that are the same and 2 that are different, which can be done in $\frac{10!}{8!}=90$ ways. Therefore there are $360+90+90+10=550$ paths to $(8,9,0)$, out of $9^{1} 0$ possible paths to the bottom, so the probability of ending up at the point $(8,9,0)$ is $\frac{550}{9^{10}}$.
+
diff --git a/HarvardMIT/md/en-22-1999-feb-calc-solutions.md b/HarvardMIT/md/en-22-1999-feb-calc-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..f15355a30ed9215481e77cc42471c71c6adc4363
--- /dev/null
+++ b/HarvardMIT/md/en-22-1999-feb-calc-solutions.md
@@ -0,0 +1,85 @@
+# Calculus Solutions
+
+Harvard-MIT Math Tournament
+
+February 27, 1999
+
+## Problem C1 [3 points]
+
+Find all twice differentiable functions $f(x)$ such that $f^{\prime \prime}(x)=0, f(0)=19$, and $f(1)=99$.
+Solution: Since $f^{\prime \prime}(x)=0$ we must have $f(x)=a x+b$ for some real numbers $a, b$. Thus $f(0)=$ $b=19$ and $f(1)=a+19=99$, so $a=80$. Therefore $f(x)=\mathbf{8 0 x}+\mathbf{1 9}$.
+
+## Problem C2 [3 points]
+
+A rectangle has sides of length $\sin x$ and $\cos x$ for some $x$. What is the largest possible area of such a rectangle?
+
+Solution: We wish to maximize $\sin x \cdot \cos x=\frac{1}{2} \sin 2 x$. But $\sin 2 x \leq 1$, with equality holding for $x=\pi / 4$, so the maximum is $\frac{1}{2}$.
+
+## Problem C3 [4 points]
+
+Find
+
+$$
+\int_{-4 \pi \sqrt{2}}^{4 \pi \sqrt{2}}\left(\frac{\sin x}{1+x^{4}}+1\right) d x
+$$
+
+Solution: The function $\frac{\sin x}{1+x^{4}}$ is odd, so its integral over this interval is 0 . Thus we get the same answer if we just integrate $d x$, namely, $\mathbf{8} \pi \sqrt{\mathbf{2}}$.
+
+## Problem C4 [4 points]
+
+$f$ is a continuous real-valued function such that $f(x+y)=f(x) f(y)$ for all real $x, y$. If $f(2)=5$, find $f(5)$.
+
+Solution 1: Since $f(n x)=f(x)^{n}$ for all integers $n, f(5)=f(1)^{5}$ and $f(2)=f(1)^{2}$, so $f(5)=$ $f(2)^{5 / 2}=\mathbf{2 5} \sqrt{\mathbf{5}}$.
+
+Solution 2: More generally, since $f(n x)=f(x)^{n}$ for all integers $n, f(1)=c=f(1 / n)^{n}$ for some constant $c$ and all integers $n$. Thus $f(k / n)=f(1 / n)^{k}=f(1)^{k / n}=c^{k / n}$ for all rational numbers $k / n$. By continuity, it follows that $f(x)=c^{x}$ for all real numbers $x$. Since $f(2)=5, c=\sqrt{5}$, so $f(5)=\mathbf{2 5} \sqrt{\mathbf{5}}$.
+
+## Problem C5 [5 points]
+
+Let $f(x)=x+\frac{1}{2 x+\frac{1}{2 x+\frac{1}{2 x+}}}$ for $x>0$. Find $f(99) f^{\prime}(99)$.
+
+Solution: Assume that the continued fraction converges (it does) so that $f(x)$ is well defined. Notice that $f(x)-x=\frac{1}{x+f(x)}$, so $f(x)^{2}-x^{2}=1$, or $f(x)=\sqrt{1+x^{2}}$ (we need the positive square root since $x>0$ ). Thus $f^{\prime}(x)=\frac{x}{\sqrt{1+x^{2}}}$, so $f(x) f^{\prime}(x)=x$. In particular, $f(99) f^{\prime}(99)=\mathbf{9 9}$.
+
+## Problem C6 [5 points]
+
+Evaluate $\frac{d}{d x}\left(\sin x-\frac{4}{3} \sin ^{3} x\right)$ when $x=15$.
+Solution: Of course this problem can be done by brute force, differentiating and then using the half angle formula to find $\sin$ and $\cos$ of 15 , but there is a quicker way. $e^{i x}=\cos x+i \sin x$, so $\sin (3 x)$ is the imaginary part of $(\cos x+i \sin x)^{3}$, which is $3 \cos ^{2} x \sin x-\sin ^{3} x=3 \sin x-4 \sin ^{3} x$, so the expression we are differentiating is just $\frac{1}{3} \sin (3 x)$. Hence the derivative is $\cos (3 x)$, and $\cos 45=\frac{\sqrt{2}}{2}$.
+
+## Problem C7 [5 points]
+
+If a right triangle is drawn in a semicircle of radius $1 / 2$ with one leg (not the hypotenuse) along the diameter, what is the triangle's maximum possible area?
+
+Solution: It is easy to see that we will want one vertex of the triangle to be where the diameter meets the semicircle, so the diameter is divided into segments of length $x$ and $1-x$, where $x$ is the length of the leg on the diameter. The other leg of the triangle will be the geometric mean of these two numbers, $\sqrt{x(1-x)}$. Therefore the area of the triangle is $\frac{x \sqrt{x(1-x)}}{2}$, so it will be maximized when $\frac{d}{d x}\left(x^{3}-x^{4}\right)=3 x^{2}-4 x^{3}=0$, or $x=3 / 4$. Therefore the maximum area is $\frac{3 \sqrt{3}}{32}$.
+
+## Problem C8 [6 points]
+
+A circle is randomly chosen in a circle of radius 1 in the sense that a point is randomly chosen for its center, then a radius is chosen at random so that the new circle is contained in the original circle. What is the probability that the new circle contains the center of the original circle?
+
+Solution: If the center of the new circle is more than $1 / 2$ away from the center of the original circle then the new circle cannot possibly contain the center of the original one. Let $x$ be the distance between the centers (by symmetry this is all we need to consider), then for $0 \leq x \leq 1 / 2$ the probability of the new circle containing the center of the original one is $1-\frac{x}{1-x}$. Hence we need to compute $\int_{0}^{1 / 2}\left(1-\frac{x}{1-x}\right) d x=\frac{1}{2}-\int_{0}^{1 / 2} \frac{x}{1-x} d x$. To evaluate the integral, we can integrate by parts to get
+
+$$
+-\left.x \ln (1-x)\right|_{0} ^{1 / 2}-\int_{0}^{1 / 2}-\ln (1-x) d x=-\frac{1}{2} \ln \left(\frac{1}{2}\right)-[(1-x) \ln (1-x)-(1-x)]_{0}^{1 / 2}=\ln 2-\frac{1}{2} .
+$$
+
+Alternatively, we can use polynomial division to find that $\frac{x}{1-x}=-1+\frac{1}{1-x}$, so $\int_{0}^{1 / 2} \frac{x}{1-x} d x=$ $\int_{0}^{1 / 2}\left(-1+\frac{1}{1-x}\right) d x=\ln 2-\frac{1}{2}$. Therefore the probability is $\frac{1}{2}-\left(\ln 2-\frac{1}{2}\right)=\mathbf{1}-\ln \mathbf{2}$.
+
+## Problem C9 [7 points]
+
+What fraction of the Earth's volume lies above the 45 degrees north parallel? You may assume the Earth is a perfect sphere. The volume in question is the smaller piece that we would get if the sphere were sliced into two pieces by a plane.
+
+Solution 1: Without loss of generality, look at a sphere of radius 1 centered at the origin. If you like cartesian coordinates, then you can slice the sphere into discs with the same $z$ coordinate, which have radius $\sqrt{1-z^{2}}$, so the region we are considering has volume $\int_{\sqrt{2} / 2}^{1} \pi\left(1-z^{2}\right) d z=\pi\left(\frac{2}{3}-\frac{5 \sqrt{2}}{12}\right)$, and dividing by $4 \pi / 3$ we get $\frac{8-5 \sqrt{2}}{\mathbf{1 6}}$.
+
+Solution 2: For those who prefer spherical coordinates, we can find the volume of the spherical cap plus a cone whose vertex is the center of the sphere. This region is where $r$ ranges from 0 to $1, \theta$ ranges from 0 to $2 \pi$, and $\phi$ ranges from 0 to $\pi / 4$. Remembering we need to subtract off the volume of the cone, which has height $\frac{1}{\sqrt{2}}$ and a circular base of radius $\frac{1}{\sqrt{2}}$, then divide by $\frac{4}{3} \pi$ to get the fraction of the volume of the sphere, we find that we need to evaluate $\frac{\int_{0}^{1} \int_{0}^{2 \pi} \int_{0}^{\pi / 4} r^{2} \sin \phi d \phi d \theta d r-\frac{1}{3} \pi\left(\frac{1}{\sqrt{2}}\right)^{2} \frac{1}{\sqrt{2}}}{4 \pi / 3}$. The integral is just $2 \pi \frac{1}{3}(-\cos \pi / 4+\cos 0)=\frac{4 \pi-2 \pi \sqrt{2}}{6}$. Putting this back in the answer and simplifying yields $\frac{8-5 \sqrt{2}}{16}$.
+
+Solution 3: Cavalieri's Principle states that if two solids have the same cross-sectional areas at every height, then they have the same volume. This principle is very familiar in the plane, where we know that the area of a triangle depends only on the base and height, not the precise position of the apex. To apply it to a sphere, consider a cylinder with radius 1 and height 1 . Now cut out a cone whose base is the upper circle of the cylinder and whose apex is the center of the lower circle. Then at a height $z$ the area is $\pi\left(1^{2}-z^{2}\right)$, exactly the same as for the upper hemisphere! The portion lying above the the 45 degrees north parallel is that which ranges from height $\frac{1}{\sqrt{2}}$ to 1 . The volume of the cylinder in this range is $\pi \cdot 1^{2}\left(1-\frac{1}{\sqrt{2}}\right)$. The volume of the cone in this range is the volume of the entire cone minus the portion from height 0 to $\frac{1}{\sqrt{2}}$, i.e., $\frac{1}{3} \pi\left(1^{2} \cdot 1-\left(\frac{1}{\sqrt{2}}\right)^{2} \frac{1}{\sqrt{2}}\right)$. Therefore the fraction of the Earth's volume that lies above the 45 degrees north parallel is $\frac{\pi\left(1-\frac{1}{\sqrt{2}}\right)-\frac{1}{3} \pi\left(1-\frac{1}{2 \sqrt{2}}\right)}{4 \pi / 3}=\frac{\mathbf{8 - 5} \sqrt{2}}{\mathbf{1 6}}$.
+
+Solution 4: Another way to approach this problem is to integrate the function $\sqrt{1-x^{2}-y^{2}}$ over the region $x^{2}+y^{2} \leq \frac{1}{\sqrt{2}}$, subtract off a cylinder of radius and height $\frac{1}{\sqrt{2}}$, then divide by the volume of the sphere. One could also use the nontrivial fact that the surface area of a portion of a sphere of radius $r$ between two parallel planes separated by a distance $z$ is $2 \pi r^{2} z$, so in particular the surface area of this cap is $2 \pi\left(1-\frac{1}{\sqrt{2}}\right)$. Now, the ratio of the surface area of the cap to the surface area of the sphere is the same as the ratio of the volume of the cap plus the cone considered in Solution 2 to the volume of the whole sphere, so this allows us to avoid integration entirely.
+
+## Problem C10 [8 points]
+
+Let $A_{n}$ be the area outside a regular $n$-gon of side length 1 but inside its circumscribed circle, let $B_{n}$ be the area inside the $n$-gon but outside its inscribed circle. Find the limit as $n$ tends to infinity of $\frac{A_{n}}{B_{n}}$.
+
+Solution: The radius of the inscribed circle is $\frac{1}{2} \cot \frac{\pi}{n}$, the radius of the circumscribed circle is $\frac{1}{2} \csc \frac{\pi}{n}$, and the area of the $n$-gon is $\frac{n}{4} \cot \frac{\pi}{n}$. The diagram below should help you verify that these are correct.
+
+
+Then $A_{n}=\pi\left(\frac{1}{2} \csc \frac{\pi}{n}\right)^{2}-\frac{n}{4} \cot \frac{\pi}{n}$, and $B_{n}=\frac{n}{4} \cot \frac{\pi}{n}-\pi\left(\frac{1}{2} \cot \frac{\pi}{n}\right)^{2}$, so $\frac{A_{n}}{B_{n}}=\frac{\pi\left(\csc \frac{\pi}{n}\right)^{2}-n \cot \frac{\pi}{n}}{n \cot \frac{\pi}{n}-\pi\left(\cot \frac{\pi}{n}\right)^{2}}$. Let $s$ denote $\sin \frac{\pi}{n}$ and $c$ denote $\cos \frac{\pi}{n}$. Multiply numerator and denominator by $s^{2}$ to get $\frac{A_{n}}{B_{n}} \stackrel{n}{n} \frac{\pi-n c s}{n c s-\pi c^{2}}$. Now use Taylor series to replace $s$ by $\frac{\pi}{n}-\frac{\left(\frac{\pi}{n}\right)^{3}}{6}+\ldots$ and $c$ by $1-\frac{\left(\frac{\pi}{n}\right)^{2}}{2}+\ldots$. By l'Hôpital's rule it will suffice to take just enough terms so that the highest power of $n$ in the numerator and denominator is determined, and that turns out to be $n^{-2}$ in each case. In particular, we get the limit $\frac{A_{n}}{B_{n}}=\frac{\pi-n \frac{\pi}{n}+n \frac{2}{3}\left(\frac{\pi}{n}\right)^{3}+\ldots}{n \frac{\pi}{n}-n \frac{2}{3}\left(\frac{\pi}{n}\right)^{3}-\pi+\pi\left(\frac{\pi}{n}\right)^{2}+\ldots}=\frac{\frac{2}{3} \frac{\pi^{3}}{n^{2}}+\ldots}{\frac{1}{3} \frac{\pi^{3}}{n^{2}}+\ldots} \rightarrow \mathbf{2}$.
+
diff --git a/HarvardMIT/md/en-22-1999-feb-geo-solutions.md b/HarvardMIT/md/en-22-1999-feb-geo-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..a6b010a3fdcd5f8f641a38ed804c47a209766ac9
--- /dev/null
+++ b/HarvardMIT/md/en-22-1999-feb-geo-solutions.md
@@ -0,0 +1,75 @@
+# Geometry Solutions
+
+Harvard-MIT Math Tournament
+
+February 27, 1999
+
+## Problem G1 [3]
+
+Two $10 \times 24$ rectangles are inscribed in a circle as shown. Find the shaded area.
+
+
+Solution: The rectangles are $10 \times 24$, so their diagonals, which are diameters of the circle, have length 26. Therefore the area of the circle is $\pi 13^{2}$, and the overlap is a $10 \times 10$ square, so the shaded area is $\pi 13^{2}-2 \cdot 10 \cdot 24+10^{2}=\mathbf{1 6 9} \pi-\mathbf{3 8 0}$.
+
+## Problem G2 [3]
+
+A semicircle is inscribed in a semicircle of radius 2 as shown. Find the radius of the smaller semicircle.
+
+
+Solution: Draw a line from the center of the smaller semicircle to the center of the larger one, and a line from the center of the larger semicircle to one of the other points of intersection of the two semicircles. We now have a right triangle whose legs are both the radius of the smaller semicircle and whose hypotenuse is 2 , therefore the radius of the smaller semicircle is $\sqrt{\mathbf{2}}$.
+
+Problem G3 [4]
+
+In a cube with side length 6 , what is the volume of the tetrahedron formed by any vertex and the three vertices connected to that vertex by edges of the cube?
+
+Solution: We have a tetrahedron whose base is half a face of the cube and whose height is the side length of the cube, so its volume is $\frac{1}{3} \cdot\left(\frac{1}{2} \cdot 6^{2}\right) \cdot 6=\mathbf{3 6}$.
+
+Problem G4 [4]
+
+A cross-section of a river is a trapezoid with bases 10 and 16 and slanted sides of length 5. At this section the water is flowing at $\pi \mathrm{mph}$. A little ways downstream is a dam where the water flows through 4 identical circular holes at 16 mph . What is the radius of the holes?
+
+Solution: The volume of water going through any cross-section of the river in an hour (assuming the cross-sections are parallel) is the area times the velocity. The trapezoid has height 4 , hence area 52 , so the volume of water going through at any hour is $52 \pi$. Let $r$ be the radius of the holes, then the total area is $4 \pi r^{2}$, so the volume of water is $64 \pi r^{2}$. Therefore $64 \pi r^{2}=52 \pi$, so $r=\frac{\sqrt{13}}{4}$.
+
+## Problem G5 [5]
+
+In triangle $B E N$ shown below with its altitudes intersecting at $X, N A=7, E A=3, A X=4$, and $N S=8$. Find the area of $B E N$.
+
+
+Solution: The idea is to try to find a base and height for the triangle so that we can find the area. By the Pythagorean theorem, $E X=5, N X=\sqrt{65}$, and $S X=1$. Triangles $A X E$ and $B X S$ are similar since they have the same angles. The ratio of their side lengths is $4: 1$, so $B S=3 / 4$ and $B X=5 / 4$. Now using either $N E$ or $N B$ as a base, we get that the area of $B E N$ is $\frac{1}{2} \cdot\left(8+\frac{3}{4}\right) \cdot 6$ or $\frac{1}{2} \cdot\left(4+\frac{5}{4}\right) \cdot 10$, both of which simplify to $\frac{105}{4}$.
+
+## Problem G6 [5]
+
+A sphere of radius 1 is covered in ink and rolling around between concentric spheres of radii 3 and 5. If this process traces a region of area 1 on the larger sphere, what is the area of the region traced on the smaller sphere?
+
+Solution: The figure drawn on the smaller sphere is just a scaled down version of what was drawn on the larger sphere, so the ratio of the areas is the ratio of the surface area of the spheres. This is the same as the ratio of the squares of the radii, which is $\frac{9}{25}$.
+
+## Problem G7 [5]
+
+A dart is thrown at a square dartboard of side length 2 so that it hits completely randomly. What is the probability that it hits closer to the center than any corner, but within a distance 1 of a corner?
+
+Solution: By symmetry it will suffice to consider one quarter of the dartboard, which is a square of side length 1. Therefore the probability is the area of the desired region in this square. The desired region is the part of the circle of radius 1 centered at a corner that is closer to the opposite corner. The points closer to the opposite corner are those that are on the other side of the diagonal through the other two corners, so the desired region is a quarter of a circle of radius 1 minus a right triangle with legs of length 1 . Therefore the area (and hence the probability) is $\frac{\pi-2}{4}$.
+
+## Problem G8 [6]
+
+Squares $A B K L, B C M N, C A O P$ are drawn externally on the sides of a triangle $A B C$. The line segments $K L, M N, O P$, when extended, form a triangle $A^{\prime} B^{\prime} C^{\prime}$. Find the area of $A^{\prime} B^{\prime} C^{\prime}$ if $A B C$ is an equilateral triangle of side length 2.
+
+Solution: Triangle $A B C$ has area $\sqrt{3}$, and each of the three squares has area 4 . The three remaining regions are congruent, so just consider the one that includes vertex $B$. Triangle $K B N$ has two sides of length 2 and an angle of $120^{\circ}$ between them, to bisecting that angle we get two halves of an equilateral triangle of side length 2 , so the area is again $\sqrt{3}$. The remaining region is an equilateral triangle of side length $2 \sqrt{3}$, so its area is $(2 \sqrt{3})^{2} \sqrt{3} / 4=3 \sqrt{3}$. Therefore the area of $A^{\prime} B^{\prime} C^{\prime}$ is $\sqrt{3}+3 \cdot 4+3 \cdot \sqrt{3}+3 \cdot 3 \sqrt{3}=\mathbf{1 2}+\mathbf{1 3} \sqrt{\mathbf{3}}$.
+
+Note that this problem is still solvable, but much harder, if the first triangle is not equilateral.
+
+## Problem G9 [7]
+
+A regular tetrahedron has two vertices on the body diagonal of a cube with side length 12 . The other two vertices lie on one of the face diagonals not intersecting that body diagonal. Find the side length of the tetrahedron.
+
+Solution: Let $A B C D$ be a tetrahedron of side $s$. We want to find the distance between two of its opposite sides. Let $E$ be the midpoint of $A D, F$ the midpoint of $B C$. Then $A E=s / 2$, $A F=s \sqrt{3} / 2$, and angle $A E F=90^{\circ}$. So the distance between the two opposite sides is $E F=$ $\sqrt{A F^{2}-A E^{2}}=\sqrt{3 s^{2} / 4-s^{2} / 4}=s / \sqrt{2}$.
+
+Now we find the distance between a body diagonal and a face diagonal of a cube of side $a$. Let $O$ be the center of the cube and $P$ be the midpoint of the face diagonal. Then the plane containing $P$ and the body diagonal is perpendicular to the face diagonal. So the distance between the body and face diagonals is the distance between $P$ and the body diagonal, which is $\frac{a}{2} \sqrt{\frac{2}{3}}$ (the altitude from $P$ of right triangle $O P Q$, where $Q$ is the appropriate vertex of the cube). So now $\frac{s}{\sqrt{2}}=\frac{a}{2} \sqrt{\frac{2}{3}}$, thus $s=a / \sqrt{3}=12 / \sqrt{3}=\mathbf{4} \sqrt{\mathbf{3}}$.
+
+## Problem G10 [8]
+
+In the figure below, $A B=15, B D=18, A F=15, D F=12, B E=24$, and $C F=17$. Find $B G: F G$.
+
+Solution: Our goal is to find the lengths $B G$ and $F G$. There are several ways to go about doing this, but we will show only one here. We will make several uses of Stewart's theorem, which can
+
+be proved using the law of cosines twice. By Stewart's theorem on triangle $A B D$ and line $B F$, $15^{2} \cdot 12+18^{2} \cdot 15=B F^{2} \cdot 27+15 \cdot 12 \cdot 27$, so $B F=10$ and $E F=14$. By Stewart's theorem on triangle $A B E$ and line $A F, A E^{2} \cdot 10+15^{2} \cdot 14=15^{2} \cdot 24+14 \cdot 10 \cdot 24$, so $A E=\sqrt{561}$. By Stewart's theorem on triangle $A E D$ and line $E F, E D^{2} \cdot 15+561 \cdot 12=14^{2} \cdot 27+12 \cdot 15 \cdot 27$, so $E D=2 \sqrt{57}$. By Stewart's theorem on triangle $C F E$ and line $F D, 14^{2} \cdot C D+17^{2} \cdot 2 \sqrt{57}=$ $12^{2} \cdot(C D+2 \sqrt{57})+2 \sqrt{57} \cdot C D \cdot(C D+2 \sqrt{57})$, so $C D=\sqrt{57}$ and $C E=3 \sqrt{57}$. Note that $D G=18-B G$ and apply Menelaus' theorem to triangle $B E D$ and the line through $C, G$, and $F$ to get $3 \cdot \frac{18-B G}{B G} \cdot \frac{10}{14}=1$, so $B G=\frac{135}{11}$. Similarly $C G=17-F G$, so applying Menelaus' theorem to triangle $C F E$ and the line through $B, G$, and $D$ we get $\frac{24}{10} \cdot \frac{F G}{17-F G} \cdot \frac{1}{2}=1$, so $F G=\frac{85}{11}$. Therefore $B G: F G=\mathbf{2 7}: \mathbf{1 7}$.
+
diff --git a/HarvardMIT/md/en-22-1999-feb-oral-solutions.md b/HarvardMIT/md/en-22-1999-feb-oral-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..966f62f4a4ff35c5a33e124a1fa269f3f5fef1c7
--- /dev/null
+++ b/HarvardMIT/md/en-22-1999-feb-oral-solutions.md
@@ -0,0 +1,94 @@
+# Oral Solutions
+
+Harvard-MIT Math Tournament
+
+February 27, 1999
+
+## Problem O1 [25 points]
+
+Start with an angle of $60^{\circ}$ and bisect it, then bisect the lower $30^{\circ}$ angle, then the upper $15^{\circ}$ angle, and so on, always alternating between the upper and lower of the previous two angles constructed. This process approaches a limiting line that divides the original $60^{\circ}$ angle into two angles. Find the measure (degrees) of the smaller angle.
+
+Solution: The fraction of the original angle is $\frac{1}{2}-\frac{1}{4}+\frac{1}{8}-+\cdots$. This is just a geometric series with first term $1 / 2$ and ratio $-1 / 2$, so the sum is $1 / 3$. Therefore the smaller angle is $20^{\circ}$.
+
+Score 20 points for the correct answer, 5 points for a correct justification. Just setting up the sum is worth 6 points, getting $1 / 3$ is worth 9 more.
+
+## Problem O2 [25 points]
+
+Alex, Pei-Hsin, and Edward got together before the contest to send a mailing to all the invited schools. Pei-Hsin usually just stuffs the envelopes, but if Alex leaves the room she has to lick them as well and has a $25 \%$ chance of dying from an allergic reaction before he gets back. Licking the glue makes Edward a bit psychotic, so if Alex leaves the room there is a $20 \%$ chance that Edward will kill Pei-Hsin before she can start licking envelopes. Alex leaves the room and comes back to find Pei-Hsin dead. What is the probability that Edward was responsible?
+
+Solution: There are two possibilities: either Edward killed Pei-Hsin or the envelopes did. The envelope could only be responsible if Edward was not, so the chances of that would be $4 / 5 \cdot 1 / 4=1 / 5$. This is the same as the probability that Edward killed her, so the events are equally likely and the answer is $\mathbf{5 0 \%}$, or $\mathbf{1 / 2}$.
+
+Score 20 points for the correct answer, 5 points for a correct justification. Not many places to give partial credit.
+
+## Problem O3 [30 points]
+
+If $x, y$, and $z$ are distinct positive integers such that $x^{2}+y^{2}=z^{3}$, what is the smallest possible value of $x+y+z$.
+
+Solution 1: Without loss of generality let $x>y$. We must have $z^{3}$ expressible as the sum of two squares, and this first happens when $z=5$. Then $x$ and $y$ can be 10 and 5 or 11 and 2 . If $z>5$ then $z \geq 10$ for $z^{3}$ to be a sum of two distinct squares, so $x^{2}>500, x>22$, so $x+y+z>32$. Thus the smallest possible value of $x+y+z$ is $11+2+5=\mathbf{1 8}$.
+
+Solution 2: If $z>5$, then $z \geq 6$, so $z^{3} \geq 216$. Now $x^{2}+y^{2} \geq 216$, so $x \geq 11$ and $y \geq 1$, thus $x+y+z \geq 18$. Since $x=11, y=1, z=6$ does not work, we must have $x+y+z>18$, and the solution given is the best possible.
+
+Score 20 points for the correct answer, 5 points for justifying that we can't do better with $z \leq 5,5$ points for justifying that we can't do better with $z>5$.
+
+## Problem O4 [35 points]
+
+Evaluate $\sum_{n=0}^{\infty} \frac{\cos n \theta}{2^{n}}$, where $\cos \theta=\frac{1}{5}$.
+
+Solution: $\cos n \theta$ is the real part of $e^{i n \theta}$, so the sum is the real part of $\sum_{n=0}^{\infty} \frac{e^{i n \theta}}{2^{n}}$. This is a geometric series with initial term 1 and ratio $\frac{e^{i \theta}}{2}$, so its sum is $\frac{1}{1-e^{i \theta} / 2}$. We are given $\cos \theta=\frac{1}{5}$, so $\sin \theta= \pm \frac{2 \sqrt{6}}{5}$. Thus the sum is $\frac{10}{10-1 \mp 2 i \sqrt{6}}=\frac{90 \pm 20 i \sqrt{6}}{105}$, and the real part is $\frac{\mathbf{6}}{\mathbf{7}}$.
+
+Score 20 points for the correct answer, 15 points for a correct justification.
+
+Problem O5 [45 points]
+
+Let $r$ be the radius of the inscribed circle of triangle $A B C$. Take a point $D$ on side $B C$, and let $r_{1}$ and $r_{2}$ be the inradii of triangles $A B D$ and $A C D$. Prove that $r, r_{1}$, and $r_{2}$ can always be the side lengths of a triangle.
+
+Solution: We must show that $r, r_{1}$, and $r_{2}$ satisfy the triangle inequality, i.e. that the sum of any two of them exceeds the third. Clearly $r$ is the largest of the three, so we need only verify that $r_{1}+r_{2}>r$. Let $K$ and $s$ be the area and semiperimeter of triangle $A B C$. Similarly define $K_{1}$, $K_{2}, s_{1}$, and $s_{2}$. Observe that $s$ is larger than $s_{1}$ or $s_{2}$ and that $K_{1}+K_{2}=K$. While these facts are almost trivial to verify, they must be stated. Then $r=K / s, r_{1}=K_{1} / s_{1}$, and $r_{2}=K_{2} / s_{2}$, so $r_{1}+r_{2}=K_{1} / s_{1}+K_{2} / s_{2}>K_{1} / s+K_{2} / s=K / s=r$.
+
+The correct use of areas and semiperimeters is worth 25 points, each of the critical facts is worth 10 points. I don't know of any other way to do this problem, so attempts at alternate proofs should get at most 15 points for effort unless they really on the right track to another solution.
+
+## Problem O6 [45 points]
+
+You want to sort the numbers 54321 using block moves. In other words, you can take any set of numbers that appear consecutively and put them back in at any spot as a block. For example, $653421 \rightarrow 426531$ is a valid block move for 6 numbers. What is the minimum number of block moves necessary to get 12345 ?
+
+Solution 1: Here is a sequence of 3 moves that works: $54321 \rightarrow 32541 \rightarrow 34125 \rightarrow 12345$. But how do we know we can't do it in 2 moves? From any position there are 20 possible permutations via block moves, 16 from moving a block of size 1 and 4 from moving a block of size 2 . One could simply write the 20 permutations of 54321 and the 20 permutations of 12345 and try to see that they have nothing in common, which would suffice since the inverse of a block move is also a block move. A more clever method is to notice that if we could sort 54321 in 2 moves then we could sort 4321 in 2 moves as well by simply deleting the 5 from each step. But 4321 has only 10 permutations from block moves, namely $3421,3241,3214,4231,4213,2431,4312,1432,4132$, and 2143 . The 10
+permutations of 1234 are $2134,2314,2341,1324,1342,3124,1243,4123,1423$, and 3412 . These two sets of permutations have nothing in common, thus it takes at least 3 moves to sort 4321, and hence at least 3 moves to sort 54321.
+
+Solution 2: There is a more elegant way to show we need at least 3 moves. Given a permutation of $\{1,2,3,4,5\}$ (or any ordered set), define a descent to be an adjacent pair of numbers in the permutation such that the left number is greater than the right one. For example, 12345,34215 , and 54321 have 0,2 , and 4 descents, respectively. Any permutation obtained from 12345 by one block move has (at most) one descent, at the left edge of the moved block. Similarly, any permutation obtained from 54321 by one block move has (at least) three descents, so that we can't get from 54321 to 12345 by two block moves.
+
+Score 20 points for the correct answer, 10 points for a numerical example proving that is attainable, and 15 points for proving it can't be done in 2 or fewer moves.
+
+## Problem O7 [55 points]
+
+Evaluate $\sum_{n=1}^{\infty} \frac{n^{5}}{n!}$.
+Solution: We start by noticing that $\sum_{n=1}^{\infty} \frac{n}{n!}=\sum_{n=1}^{\infty} \frac{1}{(n-1)!}=\sum_{n=0}^{\infty} \frac{1}{n!}=e$. Next we see that $\sum_{n=1}^{\infty} \frac{n^{2}}{n!}=\sum_{n=1}^{\infty} \frac{n}{(n-1)!}=\sum_{n=0}^{\infty} \frac{1+n}{n!}=\sum_{n=0}^{\infty} \frac{1}{n!}+\sum_{n=0}^{\infty} \frac{n}{n!}=e+e=2 e$. Let $f(k)=\sum_{n=1}^{\infty} \frac{n^{k}}{n!}$, then $\sum_{n=1}^{\infty} \frac{n^{k}}{n!}=\sum_{n=1}^{\infty} \frac{n^{k-1}}{(n-1)!}=\sum_{n=0}^{\infty} \frac{(1+n)^{k-1}}{n!}$, so by the binomial theorem $f(k)=\sum_{j=0}^{k-1}\binom{k-1}{j} \cdot f(j)$. Armed with this formula, we can easily compute $f(3)=f(0)+2 f(1)+f(2)=e+2 e+2 e=5 e$, $f(4)=1 \cdot e+3 \cdot e+3 \cdot 2 e+1 \cdot 5 e=15 e$, and $f(5)=1 \cdot e+4 \cdot e+6 \cdot 2 e+4 \cdot 5 e+1 \cdot 15 e=52 \mathbf{e}$.
+
+Score 30 points for the correct answer, 25 points for a correct justification. If on the right track with a good justification, but an arithmetic error is made along the way, score 5 points for each $f(j), j=0,1,2,3,4$, correctly computed.
+
+## Problem O8 [55 points]
+
+What is the smallest square-free composite number that can divide a number of the form $4242 \ldots 42 \pm 1$ ?
+
+Solution: It is easy to see that such a number can never be divisible by $2,3,5$, or 7 . They can be divisible by 11, the smallest example being $4242424241=11 \cdot 547 \cdot 705073$. What makes this problem hard is finding the next prime that can divide such a number. Let $T_{n}=\sum_{i=0}^{n} 42 \cdot 10^{2 i}$. Then the numbers $T_{n}$ modulo a prime $p$ will always be periodic, since $T_{n}=100 T_{n_{1}}+42$, so we just need to compute one period and see if it contains $\pm 1$. Thus we find that modulo 13 we get $3,4,0$, $3, \ldots$, modulo 17 we get $8,9,7,11,3,2,4,0,8, \ldots$, modulo 19 we get $4,5,10,16,8,6,15,3,0,4$, $\ldots$, and modulo 23 we get $19,10,7,6,21,3,20,18,2,12,0,19, \ldots$, so none of these primes can ever divide $T_{n} \pm 1$. But $424241=29 \cdot 14629$, so 29 can also divide numbers of this form. Therefore the smallest composite number that can divide $T_{n} \pm 1$ for some $n$ is $\mathbf{3 1 9}$, and the smallest such $n$ is 83 .
+
+Score 30 points for the correct answer, 15 points for showing it is the smallest, 10 points for showing it does work. Just seeing that 11 is the smallest prime divisor is worth 5 points, finding for exactly which $n$ is worth 5 more.
+
+## Problem O9 [60 points]
+
+You are somewhere on a ladder with 5 rungs. You have a fair coin and an envelope that contains either a double-headed coin or a double-tailed coin, each with probability $1 / 2$. Every minute you flip a coin. If it lands heads you go up a rung, if it lands tails you go down a rung. If you move up from the top rung you win, if you move down from the bottom rung you lose. You can open the envelope at any time, but if you do then you must immediately flip that coin once, after which you can use it or the fair coin whenever you want. What is the best strategy (i.e. on what rung(s) should you open the envelope)?
+
+Solution: First consider the probability of winning if you never open the envelope. Let $q(n)$ be the probability of winning from the $n$th rung with just the fair coin, then $q(n)=\frac{q(n-1)+q(n+1)}{2}$, so it is not hard to calculate that $q(n)=n / 6$. If we open the envelope, then there's a $1 / 2$ chance that it is heads and we win, and a $1 / 2$ chance that it is tails and we end up one rung down with just the fair coin (obviously we keep using the double sided coin iff it is double headed). Let us start by analyzing rung 1 . If we don't open the envelope, then we have a $1 / 2$ chance of losing and a $1 / 2$ chance of ending up on rung 2 with the envelope. If we do open the envelope, then we have a $1 / 2$ chance of losing and a $1 / 2$ chance of winning, which is a better outcome, so we should open the envelope on rung 1 . Next we look at rung 5 . If we don't open the envelope, then we have a $1 / 2$ chance of winning and a $1 / 2$ chance of moving down to rung 4 with the envelope. If we do open the envelope, then we we have a $1 / 2$ chance of winning and a $1 / 2$ chance of moving down to rung 4 without the envelope. Let $p(n)$ be the probability of winning from rung $n$ if we are there with the envelope still unopened. Then clearly $p(n) \geq q(n)$ for all $n$ if we're using optimal strategy, so we should not open the envelope on rung 5 . Next we look at rung 4. If we open the envelope, then our chance of winning is $1 / 2+q(3) / 2=3 / 4$. If we don't, then our chance of winning is $p(5) / 2+p(3) / 2$. We do know that $p(5)=1 / 2+p(4) / 2$, but this is not enough to tell us what to do on rung 4. Looking at rung 3 , we can open the envelope for a probability $1 / 2+q(2) / 2=2 / 3$ of winning, and we can not open the envelope for a probability $p(4) / 2+p(2) / 2$ of winning. On rung 2 , we can open the envelope for a probability $1 / 2+q(1) / 2=7 / 12$ of winning, and we can not open the envelope for a probability $p(3) / 2+p(1) / 2=p(3) / 2+1 / 4$ of winning.
+Now we can use all this information together for the complete answer. We know $p(2) \geq 7 / 12$, therefore $p(3) \geq p(4) / 2+7 / 24$, and we know $p(4) \geq p(5) / 2+p(3) / 2 \geq \frac{1 / 2+p(4) / 2}{2}+p(3) / 2 \geq$ $\frac{1 / 2+p(4) / 2}{2}+\frac{p(4) / 2+7 / 24}{2}$. Isolating $p(4)$ in this inequality, we get $p(4) \geq 1 / 2+7 / 24>3 / 4$, therefore we should not open the envelope on rung 4 . Now from $p(4)=p(5) / 2+p(3) / 2$ and $p(5)=1 / 2+p(4) / 2$ we have $p(4)=\frac{1 / 2+p(4) / 2}{2}+p(3) / 2$, so $p(3)=3 p(4) / 2-1 / 2 \geq 11 / 16>2 / 3$, so we should not open the envelope on rung 3 . Now $p(2) \geq p(3) / 2+1 / 4 \geq 19 / 32>7 / 12$, so we should not open the envelope on rung 2. Therefore the best strategy is to open the envelope iff we are on the bottom rung.
+
+For each rung, score 4 points for the correct answer and 8 more for a correct justification.
+
+## Problem O10 [75 points]
+
+$A, B, C, D$, and $E$ are relatively prime integers (i.e., have no single common factor) such that the polynomials $5 A x^{4}+4 B x^{3}+3 C x^{2}+2 D x+E$ and $10 A x^{3}+6 B x^{2}+3 C x+D$ together have 7 distinct integer roots. What are all possible values of $A$ ? Your team has been given a sealed envelope that contains a hint for this problem. If you open the envelope, the value of this problem decreases by 20 points. To get full credit, give the sealed envelope to the judge before presenting your solution.
+
+Hint: Consider $A=1, B=D=0, C=750$, and $E=19845$.
+Solution: Call the negatives of the roots of the first polynomial $a, b, c, d$, and the negatives of the roots of the second polynomial $e, f, g$ (using the negatives avoids negative signs for the rest of the proof, thus preventing the possibility of dropping a sign). Then $5 A x^{4}+4 B x^{3}+3 C x^{2}+2 D x+E=$ $5 A(x+a)(x+b)(x+c)(x+d)$ and $10 A x^{3}+6 B x^{2}+3 C x+D=10 A(x+e)(x+f)(x+g)$. Thus $B=\frac{5}{4} A(a+b+c+d)=\frac{5}{3} A(e+f+g), C=\frac{5}{3} A(a b+a c+a d+b c+b d+c d)=\frac{10}{3} A(e f+e g+f g)$, $D=\frac{5}{2} A(a b c+a b d+a c d+b c d)=10 A(e f g)$, and $E=5 A(a b c d)$. From these equations we see that since all the variables are integers, it must be the case that $A|B, A| 3 C, A \mid D$, and $A \mid E$, therefore $A, B, C, D$, and $E$ can only be relatively prime if $A$ is $\pm \mathbf{1}$ or $\pm \mathbf{3}$. Now we need numerical examples to show that both of these are possible. Without loss of generality let $g=0$, so $D=0$. Then $e$ and $f$ are $\frac{-3 B \pm \sqrt{9 B^{2}-30 A C}}{10 A}$, so $9 B^{2}-30 A C$ must be a perfect square. Let $B=0$ in the hope that solutions will still exist to this simplified problem. First let us try to find an example with $A=-1$, so we need $30 C$ to be a perfect square. This first happens for $C=30$, and in that case $e$ and $f$ are $\pm 3$. We need $a+b+c+d=0$, so let's try to look for $a=-b, c=-d$. This doesn't work for $C=30$ since $3 C / 5=18$ is not the sum of two distinct squares. For that we will need to try $C=5^{2} \cdot 30=750$, for which we get $e, f= \pm 15, a, b= \pm 3$, and $c, d= \pm 21$. Thus for $A= \pm 1$ we can use $B=D=0, C=\mp 750$, and $E= \pm 19845$. Similarly we can find $A= \pm 3, B=D=0, C=\mp 250$, and $E= \pm 735$, for which $(a, b, c, d, e, f, g)=(1,-1,7,-7,5,-5,0)$.
+
+Note that these give us quintic polynomials with integer coefficients possessing 4 relative extrema and 3 points of inflection at lattice points, such as $3 x^{5}-250 x^{3}+735 x$.
+
+Score 20 points for the correct answer, 15 points for a correct justification, 20 points for a numerical example for $\pm 1,20$ points for a numerical example for $\pm 3$. If the sealed envelope isn't presented at the beginning of the solution, no credit is given for the $\pm 1$ example. If the $\pm$ is forgotten, give 10 points for the answer, 10 for the justification, and 10 for each numerical example. There are infinitely many possible examples, so anything other than the two given above must be checked for accuracy.
+
diff --git a/HarvardMIT/md/en-22-1999-feb-team-solutions.md b/HarvardMIT/md/en-22-1999-feb-team-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..f3761bc1c1eb4aa9a3ffb93ad5d9c782733fd5ea
--- /dev/null
+++ b/HarvardMIT/md/en-22-1999-feb-team-solutions.md
@@ -0,0 +1,84 @@
+# Team Solutions
+
+Harvard-MIT Math Tournament
+
+February 27, 1999
+
+## Problem T1 [15]
+
+A combination lock has a 3 number combination, with each number an integer between 0 and 39 inclusive. Call the numbers $n_{1}, n_{2}$, and $n_{3}$. If you know that $n_{1}$ and $n_{3}$ leave the same remainder when divided by 4 , and $n_{2}$ and $n_{1}+2$ leave the same remainder when divided by 4 , how many possible combinations are there?
+
+Solution: There are 40 choices for the last number, and for each of these we have 10 choices for each of the first two numbers, thus giving us a total of $\mathbf{4 0 0 0}$ possible combinations. It is interesting to note that these restrictions are actually true for Master locks.
+
+## Problem T2 [15]
+
+A ladder is leaning against a house with its lower end 15 feet from the house. When the lower end is pulled 9 feet farther from the house, the upper end slides 13 feet down. How long is the ladder (in feet)?
+
+Solution: Of course the house makes a right angle with the ground, so we can use the Pythagorean theorem. Let $x$ be the length of the ladder and $y$ be the original height at which it touched the house. Then we are given $x^{2}=15^{2}+y^{2}=24^{2}+(y-13)^{2}$. Isolating $y$ in the second equation we get $y=20$, thus $x$ is $\mathbf{2 5}$.
+
+## Problem T3 [20]
+
+How many non-empty subsets of $\{1,2,3,4,5,6,7,8\}$ have exactly $k$ elements and do not contain the element $k$ for some $k=1,2, \ldots, 8$.
+
+Solution: Probably the easiest way to do this problem is to count how many non-empty subsets of $\{1,2, \ldots, n\}$ have $k$ elements and do contain the element $k$ for some $k$. The element $k$ must have $k-1$ other elements with it to be in a subset of $k$ elements, so there are $\binom{n-1}{k-1}$ such subsets. Now $\sum_{k=1}^{n}\binom{n-1}{k-1}=(1+1)^{n-1}=2^{n-1}$, so that is how many non-empty sets contain some $k$ and have $k$ elements. The set $\{1,2, \ldots, n\}$ has $2^{n}$ subsets (each element either is or is not in a particular subset), one of which is the empty set, so the number of non-empty subsets of $\{1,2,3,4,5,6,7,8\}$ have exactly $k$ elements and do not contain the element $k$ for some $k$ is $2^{n}-2^{n-1}-1=2^{n-1}-1$. In the case $n=8$, this yields $\mathbf{1 2 7}$.
+
+Problem T4 [20]
+
+Consider the equation $F O R T Y+T E N+T E N=S I X T Y$, where each of the ten letters represents a distinct digit from 0 to 9 . Find all possible values of SIXTY.
+
+Solution: Since $Y+N+N$ ends in $Y, N$ must be 0 or 5 . But if $N=5$ then $T+E+E+1$ ends in T, which is impossible, so $N=0$ and $E=5$. Since $F \neq S$ we must have $O=9, R+T+T+1>10$, and $S=F+1$. Now $I \neq 0$, so it must be that $I=1$ and $R+T+T+1>20$. Thus $R$ and $T$ are 6 and 7,6 and 8 , or 7 and 8 in some order. But $X$ can't be 0 or 1 since those are taken, and $X$ cannot be 3 since $F$ and $S$ have to be consecutive, so it must be that $R+T+T+1$ is 21 or 23 . This is satisfied only for $R=7, T=8$, so $F=2, S=3$, and $Y=6$. This $S I X T Y=\mathbf{3 1 4 8 6}$.
+
+## Problem T5 [30]
+
+If $a$ and $b$ are randomly selected real numbers between 0 and 1 , find the probability that the nearest integer to $\frac{a-b}{a+b}$ is odd.
+
+Solution: The only reasonable way I know of to do this problem is geometrically (yes, you can use integrals to find the areas of the triangles involved, but I don't consider that reasonable). First let us find the points ( $a, b$ ) in the plane for which the nearest integer to $\frac{a-b}{a+b}$ is 0 , i.e. $-\frac{1}{2} \leq \frac{a-b}{a+b} \leq \frac{1}{2}$. Taking the inequalities one at a time, $-\frac{1}{2} \leq \frac{a-b}{a+b}$ implies that $a+b \geq 2(b-a)$, or $b \leq 3 a$, so these points must lie below the line $y=3 x$. Similarly, $\frac{a-b}{a+b} \leq \frac{1}{2}$ implies that ( $a, b$ ) must lie above the line $y=\frac{1}{3} x$. Now we can look for the points $(a, b)$ for which the nearest integer to $\frac{a-b}{a+b}$ is 1 , i.e. $\frac{1}{2} \leq \frac{a-b}{a+b} \leq \frac{3}{2}$, and we find that all points in the first quadrant that lie above the line $y=3 x$ satisfy this inequality. Similarly, the closest integer to $\frac{a-b}{a+b}$ is -1 for all points in the first quadrant below the line $y=\frac{1}{3} x$. For $a$ and $b$ between 0 and 1 , the locus of points $(a, b)$ for which the nearest integer to $\frac{a-b}{a+b}$ is odd is two right triangles with legs of length 1 and $\frac{1}{3}$, so together they have area $\frac{1}{3}$. The locus of all points $(a, b)$ with $a$ and $b$ between 0 and 1 is a square of side length 1 , and thus has area 1 . Therefore the probability that the nearest integer to $\frac{a-b}{a+b}$ is odd is $\frac{1}{3}$.
+
+## Problem T6 [30]
+
+Reduce the number $\sqrt[3]{2+\sqrt{5}}+\sqrt[3]{2-\sqrt{5}}$.
+Solution: Observe that $(\sqrt[3]{2+\sqrt{5}}+\sqrt[3]{2-\sqrt{5}})^{3}=(2+\sqrt{5})-3(\sqrt[3]{2+\sqrt{5}})-3(\sqrt[3]{2-\sqrt{5}})+(2-\sqrt{5})=$ $4-3(\sqrt[3]{2+\sqrt{5}}+\sqrt[3]{2-\sqrt{5}})$. Hence $\sqrt[3]{2+\sqrt{5}}+\sqrt[3]{2-\sqrt{5}}$ is a root of the cubic $x^{3}+3 x-4=$ $(x-1)\left(x^{2}+x+4\right)$. The roots of $x^{2}+x+4$ are imaginary, so $\sqrt[3]{2+\sqrt{5}}+\sqrt[3]{2-\sqrt{5}}=\mathbf{1}$.
+
+## Problem T7 [30]
+
+Let $\frac{1}{1-x-x^{2}-x^{3}}=\sum_{i=0}^{\infty} a_{n} x^{n}$, for what positive integers $n$ does $a_{n-1}=n^{2}$ ?
+Solution: Multiplying both sides by $1-x-x^{2}-x^{3}$ the right hand side becomes $a_{0}+\left(a_{1}-a_{0}\right) x+\left(a_{2}-\right.$ $\left.a_{1}-a_{0}\right) x^{2}+\ldots$, and setting coefficients of $x^{n}$ equal to each other we find that $a_{0}=1, a_{1}=1, a_{2}=2$, and $a_{n}=a_{n-1}+a_{n-2}+a_{n-3}$ for $n \geq 3$. Thus the sequence of $a_{n}$ 's starts $1,1,2,4,7,13,24,44,81$, $149, \ldots$. So we now see that $a_{0}=1^{2}$ and $a_{8}=9^{2}$. What makes it impossible for this to happen again is that the sequence is growing exponentially. It will suffice to show that $a_{n}>1.5^{n}$ for $n>2$, since $n^{2} /(n-1)^{2}<1.5$ for $n \geq 6$, thus when $a_{n-1}$ exceeds $n^{2}$ at $n=10$ there can be no more solutions to $a_{n-1}=n^{2}$. Observe that $a_{n}>1.5 a_{n-1}$ for $n=3,4,5$. By way of induction, assume it for $n-2$,
+$n-1$, and $n$, then $a_{n+1}=a_{n}+a_{n-1}+a_{n-2}>1.5^{n}+1.5^{n-1}+1.5^{n-2}=1.5^{n-2}\left(1+1.5+1.5^{2}\right)>1.5^{n+1}$. Thus, by induction, $a_{n}>1.5^{n}$ for $n>2$, so the only solutions are $\mathbf{1 , 9}$.
+
+## Problem T8 [35]
+
+Find all the roots of $\left(x^{2}+3 x+2\right)\left(x^{2}-7 x+12\right)\left(x^{2}-2 x-1\right)+24=0$.
+Solution: We re-factor as $(x+1)(x-3)(x+2)(x-4)\left(x^{2}-2 x-1\right)+24$, or $\left(x^{2}-2 x-3\right)\left(x^{2}-\right.$ $2 x-8)\left(x^{2}-2 x-1\right)+24$, and this becomes $(y-4)(y-9)(y-2)+24$ where $y=(x-1)^{2}$. Now, $(y-4)(y-9)(y-2)+24=(y-8)(y-6)(y-1)$, so $y$ is 1,6 , or 8 . Thus the roots of the original polynomial are $0,2,1 \pm \sqrt{6}, 1 \pm 2 \sqrt{2}$.
+
+## Problem T9 [40]
+
+Evaluate $\sum_{n=2}^{17} \frac{n^{2}+n+1}{n^{4}+2 n^{3}-n^{2}-2 n}$.
+Solution: Observe that the denominator $n^{4}+2 n^{3}-n^{2}-2 n=n(n-1)(n+1)(n+2)$. Thus we can rewrite the fraction as $\frac{n^{2}-n+1}{n^{4}+2 n^{3}-n^{2}-2 n}=\frac{a}{n-1}+\frac{b}{n}+\frac{c}{n+1}+\frac{d}{n+2}$ for some real numbers $a, b, c$, and $d$. This method is called partial fractions. Condensing the right hand side as a fraction over $n^{4}+2 n^{3}-n^{2}-2 n$ we get $n^{2}-n+1=a\left(n^{3}+3 n^{2}+2 n\right)+b\left(n^{3}+2 n^{2}-n-2\right)+c\left(n^{3}+n^{2}-2 n\right)+d\left(n^{3}-n\right)$. Comparing coefficients of each power of $n$ we get $a+b+c+d=0,3 a+2 b+c=2,2 a-b-2 c-d=2$, and $-2 b=2$. This is a system of 4 equations in 4 variables, and its solution is $a=1 / 2, b=-1 / 2, c=1 / 2$, and $d=$ $-1 / 2$. Thus the summation becomes $\frac{1}{2}\left(1-\frac{1}{2}+\frac{1}{3}-\frac{1}{4}+\frac{1}{2}-\frac{1}{3}+\frac{1}{4}-\frac{1}{5}+\frac{1}{3}-\frac{1}{4}+\frac{1}{5}-\frac{1}{6}+\cdots+\frac{1}{16}-\frac{1}{17}+\frac{1}{18}-\frac{1}{19}\right)$. Notice that almost everything cancels to leave us with $\frac{1}{2}\left(1+\frac{1}{3}-\frac{1}{17}-\frac{1}{19}\right)=\frac{\mathbf{5 9 2}}{\mathbf{9 6 9}}$.
+
+## Problem T10 [45]
+
+If 5 points are placed in the plane at lattice points (i.e. points $(x, y)$ where $x$ and $y$ are both integers) such that no three are collinear, then there are 10 triangles whose vertices are among these points. What is the minimum possible number of these triangles that have area greater than $1 / 2$ ?
+
+Solution: By the pigeonhole principle, the 5 points cannot all be distinct modulo 2, so two of them must have a midpoint that is also a lattice point. This midpoint is not one of the 5 since no 3 are collinear. Pick's theorem states that the area of a polygon whose vertices are lattice points is $B / 2+I-1$ where $B$ is the number of lattice points on the boundary and $I$ is the number in the interior. Thus those two points form the base of 3 triangles whose area will be greater than $1 / 2$ by Pick's theorem since there are 4 lattice points on the boundary. Now it also turns out that at least one of the triangles must contain a lattice point, thus giving us a fourth triangle with area greater than $1 / 2$. This is actually pretty easy to show with the aid of a picture or some visualization. Suppose we have 4 points and we're trying to find a 5 th one so that no triangle will contain an interior lattice point. The 4 lattice points must form a quadrilateral of area 1 , so in fact it is a parallelogram (think deeply about it). Draw the four sides, extending them throughout the plain. Each vertex is now the tip of an infinite triangular region of the plane, and if the 5th lattice point is chosen in that region then the triangle formed by the 5th point and the two vertices of the parallelogram adjacent to the one we are considering will form a triangle containing the vertex we
+are considering. But the part of the plane that isn't in one of these 4 regions contains no lattice points or else we could draw a parallelogram congruent to the first one with lattice point vertices and containing that lattice point, but that would violate Pick's theorem since the parallelogram has area 1 . Therefore we must have a fourth triangle with area greater than $1 / 2$ (one must justify that this really is in addition to the 3 triangles we already knew we'd get). An example that achieves this minimum is the points $(0,0),(1,0),(1,1),(2,1)$, and $(2,-1)$. Therefore the minumum possible number of these triangles that have area greater than $1 / 2$ is 4 .
+A less trivial example that achieves the minimum is $(0,0),(1,1),(2,1),(3,2)$, and $(7,5)$.
+
+Problem T11 [55]
+
+Circles $C_{1}, C_{2}, C_{3}$ have radius 1 and centers $O, P, Q$ respectively. $C_{1}$ and $C_{2}$ intersect at $A, C_{2}$ and $C_{3}$ intersect at $B, C_{3}$ and $C_{1}$ intersect at $C$, in such a way that $\angle A P B=60^{\circ}, \angle B Q C=36^{\circ}$, and $\angle C O A=72^{\circ}$. Find angle $A B C$ (degrees).
+
+Solution: Using a little trig, we have $B C=2 \sin 18, A C=2 \sin 36$, and $A B=2 \sin 30$ (see left diagram). Call these $a, b$, and $c$, respectively. By the law of cosines, $b^{2}=a^{2}+c^{2}-2 a c \cos A B C$, therefore $\cos A B C=\frac{\sin ^{2} 18+\sin ^{2} 30-\sin ^{2} 36}{2 \sin 18 \sin 30}$. In the right diagram below we let $x=2 \sin 18$ and see that $x+x^{2}=1$, hence $\sin 18=\frac{-1+\sqrt{5}}{4}$. Using whatever trig identities you prefer you can find that $\sin ^{2} 36=\frac{5-\sqrt{5}}{4}$, and of course $\sin 30=\frac{1}{2}$. Now simplification yields $\sin ^{2} 18+\sin ^{2} 30-\sin ^{2} 36=0$, so $\angle A B C=\mathbf{9 0}^{\circ}$.
+Note that this means that if a regular pentagon, hexagon, and decagon are inscribed in a circle, then we can take one side from each and form a right triangle.
+
+
+Problem T12 [65]
+
+A fair coin is flipped every second and the results are recorded with 1 meaning heads and 0 meaning tails. What is the probability that the sequence 10101 occurs before the first occurance of the sequence 010101?
+
+Solution: Call it a win if we reach 10101, a loss if we reach 010101. Let $x$ be the probability of winning if the first flip is a 1 , let $y$ be the probability of winning if the first flip is a 0 . Then the probability of winning is $(x+y) / 2$ since the first flip is 1 or 0 , each with probability $1 / 2$. If we ever get two 1's in a row, that is the same as starting with a 1 as far as the probability is concerned. Similarly, if we get two 0's in a row, then we might as well have started with a single 0 .
+
+|  |
+| :---: |
+
+From the tree of all possible sequences, shown above, in which the probability of moving along any particular line is $1 / 2$, we see that $x=x(1 / 2+1 / 8)+y(1 / 4+1 / 16)+1 / 16$, and $y=x(1 / 4+1 / 16)+$ $y(1 / 2+1 / 8+1 / 32)$. Solving these two equations in two unknowns we get $x=11 / 16$ and $y=5 / 8$. Therefore the probablity that the sequence 10101 occurs before the first occurance of the sequence 010101 is $\mathbf{2 1} / \mathbf{3 2}$.
+
diff --git a/HarvardMIT/md/en-221-2018-nov-gen-solutions.md b/HarvardMIT/md/en-221-2018-nov-gen-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..dcd936ed7717880165f50ae52e82ef1070ad89c2
--- /dev/null
+++ b/HarvardMIT/md/en-221-2018-nov-gen-solutions.md
@@ -0,0 +1,133 @@
+# HMMT November 2018
+
+## November 10, 2018
+
+## General Round
+
+1. What is the largest factor of 130000 that does not contain the digit 0 or 5 ?
+
+Proposed by: Farrell Eldrian Wu
+Answer: 26
+If the number is a multiple of 5 , then its units digit will be either 0 or 5 . Hence, the largest such number must have no factors of 5 .
+We have $130000=2^{4} \cdot 5^{4} \cdot 13$. Removing every factor of 5 , we get that our number must be a factor of $2^{4} \cdot 13=208$.
+If our number contains a factor of 13 , we cancel the factor of 2 from 208,104 , and 52 until we get 26 . Otherwise, the largest number we can have is $2^{4}=16$. We conclude that the answer is 26 .
+2. Twenty-seven players are randomly split into three teams of nine. Given that Zack is on a different team from Mihir and Mihir is on a different team from Andrew, what is the probability that Zack and Andrew are on the same team?
+Proposed by: Yuan Yao
+Answer:
+
+
+Once we have assigned Zack and Mihir teams, there are 8 spots for more players on Zack's team and 9 for more players on the third team. Andrew is equally likely to occupy any of these spots, so our answer is $\frac{8}{17}$.
+3. A square in the $x y$-plane has area $A$, and three of its vertices have $x$-coordinates 2,0 , and 18 in some order. Find the sum of all possible values of $A$.
+Proposed by: Yuan Yao
+Answer: 1168
+More generally, suppose three vertices of the square lie on lines $y=y_{1}, y=y_{2}, y=y_{3}$. One of these vertices must be adjacent to two others. If that vertex is on $y=y_{1}$ and the other two are on $y=y_{2}$ and $y=y_{3}$, then we can use the Pythagorean theorem to get that the square of the side length is $\left(y_{2}-y_{1}\right)^{2}+\left(y_{3}-y_{1}\right)^{2}$.
+For $\left(y_{1}, y_{2}, y_{3}\right)=(2,0,18)$, the possibilities are $2^{2}+16^{2}, 2^{2}+18^{2}, 16^{2}+18^{2}$, so the sum is $2\left(2^{2}+16^{2}+\right.$ $\left.18^{2}\right)=2(4+256+324)=1168$.
+4. Find the number of eight-digit positive integers that are multiples of 9 and have all distinct digits.
+
+Proposed by: James Lin
+Answer: 181440
+Note that $0+1+\cdots+9=45$. Consider the two unused digits, which must then add up to 9 . If it's 0 and 9 , there are $8 \cdot 7$ ! ways to finish; otherwise, each of the other four pairs give $7 \cdot 7$ ! ways to finish, since 0 cannot be the first digit. This gives a total of $36 \cdot 7!=181440$.
+5. Compute the smallest positive integer $n$ for which
+
+$$
+\sqrt{100+\sqrt{n}}+\sqrt{100-\sqrt{n}}
+$$
+
+is an integer.
+Proposed by: Michael Tang
+Answer: 6156
+
+The number $\sqrt{100+\sqrt{n}}+\sqrt{100-\sqrt{n}}$ is a positive integer if and only if its square is a perfect square. We have
+
+$$
+\begin{aligned}
+(\sqrt{100+\sqrt{n}}+\sqrt{100-\sqrt{n}})^{2} & =(100+\sqrt{n})+(100-\sqrt{n})+2 \sqrt{(100+\sqrt{n})(100-\sqrt{n})} \\
+& =200+2 \sqrt{10000-n}
+\end{aligned}
+$$
+
+To minimize $n$, we should maximize the value of this expression, given that it is a perfect square. For this expression to be a perfect square, $\sqrt{10000-n}$ must be an integer. Then $200+2 \sqrt{10000-n}$ is even, and it is less than $200+2 \sqrt{10000}=400=20^{2}$. Therefore, the greatest possible perfect square value of $200+2 \sqrt{10000-n}$ is $18^{2}=324$. Solving
+
+$$
+200+2 \sqrt{10000-n}=324
+$$
+
+for $n$ gives the answer, $n=6156$.
+6. Call a polygon normal if it can be inscribed in a unit circle. How many non-congruent normal polygons are there such that the square of each side length is a positive integer?
+Proposed by: Yuan Yao
+Answer: 14
+The side lengths of the polygon can only be from the set $\{1, \sqrt{2}, \sqrt{3}, 2\}$, which take up $60^{\circ}, 90^{\circ}, 120^{\circ}, 180^{\circ}$ of the circle respectively. By working modulo 60 degrees we see that $\sqrt{2}$ must be used an even number of times. We now proceed to casework on the longest side of the polygon.
+
+Case 1: If the longest side has length 2, then the remaining sides must contribute the remaining 180 degrees. There are 3 possibilities: $(1,1,1,2),(1, \sqrt{3}, 2),(\sqrt{2}, \sqrt{2}, 2)$.
+Case 2: If the longest side has length $\sqrt{3}$, then it takes up either $120^{\circ}$ or $240^{\circ}$ of the circle. In the former case we have 6 possibilities: $(1,1,1,1, \sqrt{3}),(1, \sqrt{2}, \sqrt{2}, \sqrt{3}),(\sqrt{2}, 1, \sqrt{2}, \sqrt{3}),(1,1, \sqrt{3}, \sqrt{3})$, $(1, \sqrt{3}, 1, \sqrt{3}),(\sqrt{3}, \sqrt{3}, \sqrt{3})$. In the latter case there is only 1 possibility: $(1,1, \sqrt{3})$.
+Case 3: If the longest side has length $\sqrt{2}$, then it shows up either twice or four times. In the former case we have 2 possibilities: $(1,1,1, \sqrt{2}, \sqrt{2}),(1,1, \sqrt{2}, 1, \sqrt{2})$. In the latter case there is only 1 possibility: $(\sqrt{2}, \sqrt{2}, \sqrt{2}, \sqrt{2})$.
+Case 4: If all sides have length 1 , then there is 1 possibility: $(1,1,1,1,1,1)$.
+Adding up all cases, we have $3+6+1+2+1+1=14$ polygons.
+7. Anders is solving a math problem, and he encounters the expression $\sqrt{15!}$. He attempts to simplify this radical by expressing it as $a \sqrt{b}$ where $a$ and $b$ are positive integers. The sum of all possible distinct values of $a b$ can be expressed in the form $q \cdot 15$ ! for some rational number $q$. Find $q$.
+Proposed by: Nikhil Reddy
+Answer: 4
+Note that $15!=2^{11} \cdot 3^{6} \cdot 5^{3} \cdot 7^{2} \cdot 11^{1} \cdot 13^{1}$. The possible $a$ are thus precisely the factors of $2^{5} \cdot 3^{3} \cdot 5^{1} \cdot 7^{1}=$ 30240. Since $\frac{a b}{15!}=\frac{a b}{a^{2} b}=\frac{1}{a}$, we have
+
+$$
+\begin{aligned}
+q & =\frac{1}{15!} \sum_{\substack{a, b: \\
+a \sqrt{b}=\sqrt{15!}}} a b \\
+& =\sum_{a \mid 30420} \frac{a b}{15!} \\
+& =\sum_{a \mid 30420} \frac{1}{a} \\
+& =\left(1+\frac{1}{2}+\frac{1}{4}+\frac{1}{8}+\frac{1}{16}+\frac{1}{32}\right)\left(1+\frac{1}{3}+\frac{1}{9}+\frac{1}{27}\right)\left(1+\frac{1}{5}\right)\left(1+\frac{1}{7}\right) \\
+& =\left(\frac{63}{32}\right)\left(\frac{40}{27}\right)\left(\frac{6}{5}\right)\left(\frac{8}{7}\right) \\
+& =4 .
+\end{aligned}
+$$
+
+8. Equilateral triangle $A B C$ has circumcircle $\Omega$. Points $D$ and $E$ are chosen on minor arcs $A B$ and $A C$ of $\Omega$ respectively such that $B C=D E$. Given that triangle $A B E$ has area 3 and triangle $A C D$ has area 4 , find the area of triangle $A B C$.
+Proposed by: Yuan Yao
+Answer: $\frac{37}{7}$
+A rotation by $120^{\circ}$ about the center of the circle will take $A B E$ to $B C D$, so $B C D$ has area 3 . Let $A D=x, B D=y$, and observe that $\angle A D C=\angle C D B=60^{\circ}$. By Ptolemy's Theorem, $C D=x+y$. We have
+
+$$
+\begin{aligned}
+& 4=[A C D]=\frac{1}{2} A D \cdot C D \cdot \sin 60^{\circ}=\frac{\sqrt{3}}{4} x(x+y) \\
+& 3=[B C D]=\frac{1}{2} B D \cdot C D \cdot \sin 60^{\circ}=\frac{\sqrt{3}}{4} y(x+y)
+\end{aligned}
+$$
+
+By dividing these equations find $x: y=4: 3$. Let $x=4 t, y=3 t$. Substitute this into the first equation to get $1=\frac{\sqrt{3}}{4} \cdot 7 t^{2}$. By the Law of Cosines,
+
+$$
+A B^{2}=x^{2}+x y+y^{2}=37 t^{2}
+$$
+
+The area of $A B C$ is then
+
+$$
+\frac{A B^{2} \sqrt{3}}{4}=\frac{37}{7}
+$$
+
+9. 20 players are playing in a Super Smash Bros. Melee tournament. They are ranked $1-20$, and player $n$ will always beat player $m$ if $n
February 16, 2019
Geometry
+
+1. Let $d$ be a real number such that every non-degenerate quadrilateral has at least two interior angles with measure less than $d$ degrees. What is the minimum possible value for $d$ ?
+Proposed by: James Lin
+
+## Answer: 120
+
+The sum of the internal angles of a quadrilateral triangle is $360^{\circ}$. To find the minimum $d$, we note the limiting case where three of the angles have measure $d$ and the remaining angle has measure approaching zero. Hence, $d \geq 360^{\circ} / 3=120$. It is not difficult to see that for any $0<\alpha<120$, a quadrilateral of which three angles have measure $\alpha$ degrees and fourth angle has measure ( $360-3 \alpha$ ) degrees can be constructed.
+2. In rectangle $A B C D$, points $E$ and $F$ lie on sides $A B$ and $C D$ respectively such that both $A F$ and $C E$ are perpendicular to diagonal $B D$. Given that $B F$ and $D E$ separate $A B C D$ into three polygons with equal area, and that $E F=1$, find the length of $B D$.
+
+Proposed by: Yuan Yao
+Answer: $\sqrt{3}$
+Observe that $A E C F$ is a parallelogram. The equal area condition gives that $B E=D F=\frac{1}{3} A B$. Let $C E \cap B D=X$, then $\frac{E X}{C X}=\frac{B E}{C D}=\frac{1}{3}$, so that $B X^{2}=E X \cdot C X=3 E X^{2} \Rightarrow B X=\sqrt{3} E X \Rightarrow$ $\angle E B X=30^{\circ}$. Now, $C E=2 B E=C F$, so $C E F$ is an equilateral triangle and $C D=\frac{3}{2} C F=\frac{3}{2}$. Hence, $B D=\frac{2}{\sqrt{3}} \cdot \frac{3}{2}=\sqrt{3}$.
+3. Let $A B$ be a line segment with length 2 , and $S$ be the set of points $P$ on the plane such that there exists point $X$ on segment $A B$ with $A X=2 P X$. Find the area of $S$.
+Proposed by: Yuan Yao
+Answer: $\sqrt{3}+\frac{2 \pi}{3}$
+Observe that for any $X$ on segment $A B$, the locus of all points $P$ such that $A X=2 P X$ is a circle centered at $X$ with radius $\frac{1}{2} A X$. Note that the point $P$ on this circle where $P A$ forms the largest angle with $A B$ is where $P A$ is tangent to the circle at $P$, such that $\angle P A B=\arcsin (1 / 2)=30^{\circ}$. Therefore, if we let $Q$ and $Q^{\prime}$ be the tangent points of the tangents from $A$ to the circle centered at $B$ (call it $\omega$ ) with radius $\frac{1}{2} A B$, we have that $S$ comprises the two $30-60-90$ triangles $A Q B$ and $A Q^{\prime} B$, each with area $\frac{1}{2} \sqrt{3}$ and the $240^{\circ}$ sector of $\omega$ bounded by $B Q$ and $B Q^{\prime}$ with area $\frac{2}{3} \pi$. Therefore the total area is $\sqrt{3}+\frac{2 \pi}{3}$.
+4. Convex hexagon $A B C D E F$ is drawn in the plane such that $A C D F$ and $A B D E$ are parallelograms with area 168. $A C$ and $B D$ intersect at $G$. Given that the area of $A G B$ is 10 more than the area of $C G B$, find the smallest possible area of hexagon $A B C D E F$.
+
+Proposed by: Andrew Lin
+Answer: 196
+Since $A C D F$ and $A B D E$ have area 168, triangles $A B D$ and $A C D$ (which are each half a parallelogram) both have area 84 . Thus, $B$ and $C$ are the same height away from $A D$, and since $A B C D E F$ is convex, $B$ and $C$ are on the same side of $A D$. Thus, $B C$ is parallel to $A D$, and $A B C D$ is a trapezoid. In particular, we have that the area of $A B G$ equals the area of $C D G$. Letting this quantity be $x$, we have that the area of $B C G$ is $x-10$, and the area of $A D G$ is $84-x$. Then notice that $\frac{[A B G]}{[C B G]}=\frac{A G}{G C}=\frac{[A D G]}{[C D G]}$. This means that $\frac{x}{x-10}=\frac{84-x}{x}$. Simplifying, we have $x^{2}-47 x+420=0$; this has solutions $x=12$ and $x=35$. The area of $A B C D E F$ is twice the area of trapezoid $A B C D$, or $2[x+(x-10)+(84-x)+x]=4 x+148$; choosing $x=12$, we get that the smallest possible area is $48+148=196$.
+5. Isosceles triangle $A B C$ with $A B=A C$ is inscribed in a unit circle $\Omega$ with center $O$. Point $D$ is the reflection of $C$ across $A B$. Given that $D O=\sqrt{3}$, find the area of triangle $A B C$.
+Proposed by: Lillian Zhang
+Answer: $\frac{\sqrt{2}+1}{2}$ OR $\frac{\sqrt{2}-1}{2}$
+Solution 1. Observe that
+$\angle D B O=\angle D B A+\angle A B O=\angle C B A+\angle B A O=\frac{1}{2}(\angle C B A+\angle B C A)+\frac{1}{2}(\angle B A C)=\frac{1}{2}\left(180^{\circ}\right)=90^{\circ}$.
+Thus $B C=B D=\sqrt{2}$ by the Pythagorean Theorem on $\triangle D B O$. Then $\angle B O C=90^{\circ}$, and the distance from $O$ to $B C$ is $\frac{\sqrt{2}}{2}$. Depending on whether $A$ is on the same side of $B C$ as $O$, the height from $A$ to $B C$ is either $1+\frac{\sqrt{2}}{2}$ or $1-\frac{\sqrt{2}}{2}$, so the area is $\left(\sqrt{2} \cdot\left(1 \pm \frac{\sqrt{2}}{2}\right)\right) / 2=\frac{\sqrt{2} \pm 1}{2}$.
+Solution 2. One can observe that $\angle D B A=\angle C B A=\angle A C B$ by property of reflection and $A B C$ being isosceles, hence $D B$ is tangent to $\Omega$ and Power of a Point (and reflection property) gives $B C=$ $B D=\sqrt{O D^{2}-O B^{2}}=\sqrt{2}$. Proceed as in Solution 1.
+Note. It was intended, but not specified in the problem statement that triangle $A B C$ is acute, so we accepted either of the two possible answers.
+6. Six unit disks $C_{1}, C_{2}, C_{3}, C_{4}, C_{5}, C_{6}$ are in the plane such that they don't intersect each other and $C_{i}$ is tangent to $C_{i+1}$ for $1 \leq i \leq 6$ (where $C_{7}=C_{1}$ ). Let $C$ be the smallest circle that contains all six disks. Let $r$ be the smallest possible radius of $C$, and $R$ the largest possible radius. Find $R-r$.
+Proposed by: Daniel Liu
+Answer: $\sqrt{3}-1$
+The minimal configuration occurs when the six circles are placed with their centers at the vertices of a regular hexagon of side length 2 . This gives a radius of 3 .
+The maximal configuration occurs when four of the circles are placed at the vertices of a square of side length 2 . Letting these circles be $C_{1}, C_{3}, C_{4}, C_{6}$ in order, we place the last two so that $C_{2}$ is tangent to $C_{1}$ and $C_{3}$ and $C_{5}$ is tangent to $C_{4}$ and $C_{6}$. (Imagine pulling apart the last two circles on the plane; this is the configuration you end up with.) The resulting radius is $2+\sqrt{3}$, so the answer is $\sqrt{3}-1$.
+Now we present the proofs for these configurations being optimal. First, we rephrase the problem: given an equilateral hexagon of side length 2 , let $r$ be the minimum radius of a circle completely containing the vertices of the hexagon. Find the difference between the minimum and maximum values in $r$. (Technically this $r$ is off by one from the actual problem, but since we want $R-r$ in the actual problem, this difference doesn't matter.)
+
+Proof of minimality. We claim the minimal configuration stated above cannot be covered by a circle with radius $r<2$. If $r<2$ and all six vertices $O_{1}, O_{2}, \ldots, O_{6}$ are in the circle, then we have that $\angle O_{1} O O_{2}>60^{\circ}$ since $O_{1} O_{2}$ is the largest side of the triangle $O_{1} O O_{2}$, and similar for other angles $\angle O_{2} O O_{3}, \angle O_{3} O O_{4}, \ldots$, but we cannot have six angles greater than $60^{\circ}$ into $360^{\circ}$, contradiction. Therefore $r \geq 2$.
+Proof of maximality. Let $A B C D E F$ be the hexagon, and choose the covering circle to be centered at $O$, the midpoint of $A D$, and radius $\sqrt{3}+1$. We claim the other vertices are inside this covering circle. First, we will show the claim for $B$. Let $M$ be the midpoint of $A C$. Since $A B C$ is isosceles and $A M \geq 1$, we must have $B M \leq \sqrt{4-1}=\sqrt{3}$. Furthermore, $M O$ is a midline of $A C D$, so $M O=\frac{C D}{2}=1$. Thus by the triangle inequality, $O B \leq M B+O M=\sqrt{3}+1$, proving the claim. A similar argument proves the claim for $C, E, F$. Finally, an analogous argument to above shows if we define $P$ as the midpoint of $B E$, then $A P \leq \sqrt{3}+1$ and $D P \leq \sqrt{3}+1$, so by triangle inequality $A D \leq 2(\sqrt{3}+1)$. Hence $O A=O D \leq \sqrt{3}+1$, proving the claim for $A$ and $D$. Thus the covering circle contains all six vertices of $A B C D E F$.
+7. Let $A B C$ be a triangle with $A B=13, B C=14, C A=15$. Let $H$ be the orthocenter of $A B C$. Find the radius of the circle with nonzero radius tangent to the circumcircles of $A H B, B H C, C H A$.
+
+Proposed by: Michael Ren
+Answer: $\square$
+Solution 1. We claim that the circle in question is the circumcircle of the anticomplementary triangle of $A B C$, the triangle for which $A B C$ is the medial triangle.
+Let $A^{\prime} B^{\prime} C^{\prime}$ be the anticomplementary triangle of $A B C$, such that $A$ is the midpoint of $B^{\prime} C^{\prime}, B$ is the midpoint of $A^{\prime} C^{\prime}$, and $C$ is the midpoint of $A^{\prime} B^{\prime}$. Denote by $\omega$ the circumcircle of $A^{\prime} B^{\prime} C^{\prime}$. Denote by $\omega_{A}$ the circumcircle of $B H C$, and similarly define $\omega_{B}, \omega_{C}$.
+Since $\angle B A^{\prime} C=\angle B A C=180^{\circ}-\angle B H C$, we have that $\omega_{A}$ passes through $A^{\prime}$. Thus, $\omega_{A}$ can be redefined as the circumcircle of $A^{\prime} B C$. Since triangle $A^{\prime} B^{\prime} C^{\prime}$ is triangle $A^{\prime} B C$ dilated by a factor of 2 from point $A^{\prime}, \omega$ is $\omega_{A}$ dilated by a factor of 2 from point $A^{\prime}$. Thus, circles $\omega$ and $\omega_{A}$ are tangent at $A^{\prime}$.
+
+By a similar logic, $\omega$ is also tangent to $\omega_{B}$ and $\omega_{C}$. Therefore, the circumcircle of the anticomplementary triangle of $A B C$ is indeed the circle that the question is asking for.
+Using the formula $R=\frac{a b c}{4 A}$, we can find that the circumradius of triangle $A B C$ is $\frac{65}{8}$. The circumradius of the anticomplementary triangle is double of that, so the answer is $\frac{65}{4}$.
+Solution 2. It is well-known that the circumcircle of $A H B$ is the reflection of the circumcircle of $A B C$ over $A B$. In particular, the circumcircle of $A H B$ has radius equal to the circumradius $R=\frac{65}{8}$. Similarly, the circumcircles of $B H C$ and $C H A$ have radii $R$. Since $H$ lies on all three circles (in the question), the circle centered at $H$ with radius $2 R=\frac{65}{4}$ is tangent to each circle at the antipode of $H$ in that circle.
+8. In triangle $A B C$ with $A B0$. We get $E\left(\frac{a+0.5}{2}, \frac{b}{2}\right), F\left(\frac{a-0.5}{2}, \frac{b}{2}\right), M(0,0)$. Thus $N$ must have $x$-coordinate equal to the average of those of $E$ and $F$, or $\frac{a}{2}$. Since $N$ lies on $B C$, we have $N\left(\frac{a}{2}, 0\right)$.
+Since $M N=E N$, we have $\frac{a^{2}}{4}=\frac{1}{16}+\frac{b^{2}}{4}$. Thus $a^{2}=b^{2}+\frac{1}{4}$. The other equation is $A B+A C=5$, which is just
+
+$$
+\sqrt{(a+0.5)^{2}+b^{2}}+\sqrt{(a-0.5)^{2}+b^{2}}=5
+$$
+
+This is equivalent to
+
+$$
+\begin{gathered}
+\sqrt{2 a^{2}+a}+\sqrt{2 a^{2}-a}=5 \\
+\sqrt{2 a^{2}+a}=5-\sqrt{2 a^{2}-a} \\
+2 a^{2}+a=25-10 \sqrt{2 a^{2}-a}+2 a^{2}-a \\
+25-2 a=10 \sqrt{2 a^{2}-a} \\
+625-100 a+4 a^{2}=200 a^{2}-100 a \\
+196 a^{2}=625
+\end{gathered}
+$$
+
+Thus $a^{2}=\frac{625}{196}$, so $b^{2}=\frac{576}{196}$. Thus $b=\frac{24}{14}=\frac{12}{7}$, so $[A B C]=\frac{b}{2}=\frac{6}{7}$.
+9. In a rectangular box $A B C D E F G H$ with edge lengths $A B=A D=6$ and $A E=49$, a plane slices through point $A$ and intersects edges $B F, F G, G H, H D$ at points $P, Q, R, S$ respectively. Given that $A P=A S$ and $P Q=Q R=R S$, find the area of pentagon $A P Q R S$.
+Proposed by: Yuan Yao
+Answer: $\frac{141 \sqrt{11}}{2}$
+Let $A D$ be the positive $x$-axis, $A B$ be the positive $y$-axis, and $A E$ be the positive $z$-axis, with $A$ the origin. The plane, which passes through the origin, has equation $k_{1} x+k_{2} y=z$ for some undetermined parameters $k_{1}, k_{2}$. Because $A P=A S$ and $A B=A D$, we get $P B=S D$, so $P$ and $S$ have the same $z$-coordinate. But $P\left(0,6,6 k_{2}\right)$ and $S\left(6,0,6 k_{1}\right)$, so $k_{1}=k_{2}=k$ for some $k$. Then $Q$ and $R$ both have $z$-coordinate 49 , so $Q\left(\frac{49}{k}-6,6,49\right)$ and $R\left(6, \frac{49}{k}-6,49\right)$. The equation $Q R^{2}=R S^{2}$ then gives
+
+$$
+\left(\frac{49}{k}-6\right)^{2}+(49-6 k)^{2}=2\left(12-\frac{49}{k}-12\right)^{2}
+$$
+
+This is equivalent to
+
+$$
+(49-6 k)^{2}\left(k^{2}+1\right)=2(49-12 k)^{2}
+$$
+
+which factors as
+
+$$
+(k-7)\left(36 k^{3}-336 k^{2}-203 k+343\right)=0 .
+$$
+
+This gives $k=7$ as a root. Note that for $Q$ and $R$ to actually lie on $F G$ and $G H$ respectively, we must have $\frac{49}{6} \geq k \geq \frac{49}{12}$. Via some estimation, one can show that the cubic factor has no roots in this range (for example, it's easy to see that when $k=1$ and $k=\frac{336}{36}=\frac{28}{3}$, the cubic is negative, and it also remains negative between the two values), so we must have $k=7$.
+Now consider projecting $A P Q R S$ onto plane $A B C D$. The projection is $A B C D$ save for a triangle $Q^{\prime} C R^{\prime}$ with side length $12-\frac{49}{k}=5$. Thus the projection has area $36-\frac{25}{2}=\frac{47}{2}$. Since the area of the projection equals $[A P Q R S] \cdot \cos \theta$, where $\theta$ is the (smaller) angle between planes $A P Q R S$ and $A B C D$, and since the planes have normal vectors $(k, k,-1)$ and $(0,0,1)$ respectively, we get $\cos \theta=\frac{(k, k,-1) \cdot(0,0,1)}{\sqrt{k^{2}+k^{2}+1}}=\frac{1}{\sqrt{2 k^{2}+1}}=\frac{1}{\sqrt{99}}$ and so
+
+$$
+[A P Q R S]=\frac{47 \sqrt{99}}{2}=\frac{141 \sqrt{11}}{2}
+$$
+
+10. In triangle $A B C, A B=13, B C=14, C A=15$. Squares $A B B_{1} A_{2}, B C C_{1} B_{2}, C A A_{1} C_{2}$ are constructed outside the triangle. Squares $A_{1} A_{2} A_{3} A_{4}, B_{1} B_{2} B_{3} B_{4}, C_{1} C_{2} C_{3} C_{4}$ are constructed outside the hexagon $A_{1} A_{2} B_{1} B_{2} C_{1} C_{2}$. Squares $A_{3} B_{4} B_{5} A_{6}, B_{3} C_{4} C_{5} B_{6}, C_{3} A_{4} A_{5} C_{6}$ are constructed outside the hexagon $A_{4} A_{3} B_{4} B_{3} C_{4} C_{3}$. Find the area of the hexagon $A_{5} A_{6} B_{5} B_{6} C_{5} C_{6}$.
+Proposed by: Yuan Yao
+Answer: 19444
+
+## Solution 1.
+
+We can use complex numbers to find synthetic observations. Let $A=a, B=b, C=c$. Notice that $B_{2}$ is a rotation by $-90^{\circ}$ (counter-clockwise) of $C$ about $B$, and similarly $C_{1}$ is a rotation by $90^{\circ}$ of $B$ about $C$. Since rotation by $90^{\circ}$ corresponds to multiplication by $i$, we have $B_{2}=(c-b) \cdot(-i)+b=b(1+i)-c i$ and $C_{1}=(b-c) \cdot i+c=b i+c(1-i)$. Similarly, we get $C_{2}=c(1+i)-a i, A_{1}=c i+a(1-i)$, $A_{2}=a(1+i)-b i, B_{1}=a i+b(1-i)$. Repeating the same trick on $B_{1} B_{2} B_{3} B_{4}$ et. al, we get $C_{4}=-a+b(-1+i)+c(3-i), C_{3}=a(-1-i)-b+c(3+i), A_{4}=-b+c(-1+i)+a(3-i)$, $A_{3}=b(-1-i)-c+a(3+i), B_{4}=-c+a(-1+i)+b(3-i), B_{3}=c(-1-i)-a+b(3+i)$. Finally, repeating the same trick on the outermost squares, we get $B_{6}=-a+b(3+5 i)+c(-3-3 i), C_{5}=$ $-a+b(-3+3 i)+c(3-5 i), C_{6}=-b+c(3+5 i)+a(-3-3 i), A_{5}=-b+c(-3+3 i)+a(3-5 i), A_{6}=$ $-c+a(3+5 i)+b(-3-3 i), B_{5}=-c+a(-3+3 i)+b(3-5 i)$.
+From here, we observe the following synthetic observations.
+S1. $B_{2} C_{1} C_{4} B_{3}, C_{2} A_{1} A_{4} C_{3}, A_{2} B_{1} B_{4} A_{3}$ are trapezoids with bases of lengths $B C, 4 B C ; A C, 4 A C ; A B, 4 A B$ and heights $h_{a}, h_{b}, h_{c}$ respectively (where $h_{a}$ is the length of the altitude from $A$ to $B C$, and likewise for $h_{b}, h_{c}$ )
+S2. If we extend $B_{5} B_{4}$ and $B_{6} B_{3}$ to intersect at $B_{7}$, then $B_{7} B_{4} B_{3} \cong B B_{1} B_{2} \sim B_{7} B_{5} B_{6}$ with scale factor 1:5. Likewise when we replace all $B$ 's with $A$ 's or $C$ 's.
+
+Proof of S1. Observe $C_{1}-B_{2}=c-b$ and $C_{4}-B_{3}=4(c-b)$, hence $B_{2} C_{1} \| B_{3} C_{4}$ and $B_{3} C_{4}=4 B_{2} C_{1}$. Furthermore, since translation preserves properties of trapezoids, we can translate $B_{2} C_{1} C_{4} B_{3}$ such that $B_{2}$ coincides with $A$. Being a translation of $a-B_{2}$, we see that $B_{3}$ maps to $B_{3}^{\prime}=2 b-c$ and $C_{4}$ maps to $C_{4}^{\prime}=-2 b+3 c$. Both $2 b-c$ and $-2 b+3 c$ lie on the line determined by $b$ and $c$ (since $-2+3=2-1=1$ ), so the altitude from $A$ to $B C$ is also the altitude from $A$ to $B_{3}^{\prime} C_{4}^{\prime}$. Thus $h_{a}$ equals the length of the altitude from $B_{2}$ to $B_{3} C_{4}$, which is the height of the trapezoid $B_{2} C_{1} C_{4} B_{3}$. This proves S 1 for $B_{2} C_{1} C_{4} B_{3}$; the other trapezoids follow similarly.
+Proof of S2. Notice a translation of $-a+2 b-c$ maps $B_{1}$ to $B_{4}, B_{2}$ to $B_{3}$, and $B$ to a point $B_{8}=-a+3 b-c$. This means $B_{8} B_{3} B_{4} \cong B B_{1} B_{2}$. We can also verify that $4 B_{8}+B_{6}=5 B_{3}$ and $4 B_{8}+B_{5}=5 B_{4}$, showing that $B_{8} B_{5} B_{6}$ is a dilation of $B_{8} B_{4} B_{3}$ with scale factor 5 . We also get $B_{8}$ lies on $B_{3} B_{6}$ and $B_{5} B_{4}$, so $B_{8}=B_{7}$. This proves S 2 for $B_{3} B_{4} B_{5} B_{6}$, and similar arguments prove the likewise part.
+Now we are ready to attack the final computation. By S2, $\left[B_{3} B_{4} B_{5} B_{6}\right]+\left[B B_{1} B_{2}\right]=\left[B_{7} B_{5} B_{6}\right]=$ $\left[B B_{1} B_{2}\right]$. But by the $\frac{1}{2} a c \sin B$ formula, $\left[B B_{1} B_{2}\right]=[A B C]$ (since $\left.\angle B_{1} B B_{2}=180^{\circ}-\angle A B C\right)$. Hence,
+$\left[B_{3} B_{4} B_{5} B_{6}\right]+\left[B B_{1} B_{2}\right]=25[A B C]$. Similarly, $\left[C_{3} C_{4} C_{5} C_{6}\right]+\left[C C_{1} C_{2}\right]=25[A B C]$ and $\left[A_{3} A_{4} A_{5} A_{6}\right]+$ $\left[A A_{1} A_{2}\right]=25[A B C]$. Finally, the formula for area of a trapezoid shows $\left[B_{2} C_{1} C_{4} B_{3}\right]=\frac{5 B C}{2} \cdot h_{a}=$ $5[A B C]$, and similarly the other small trapezoids have area $5[A B C]$. The trapezoids thus contribute area $(75+3 \cdot 5)=90[A B C]$. Finally, $A B C$ contributes area $[A B C]=84$.
+By S1, the outside squares have side lengths $4 B C, 4 C A, 4 A B$, so the sum of areas of the outside squares is $16\left(A B^{2}+A C^{2}+B C^{2}\right)$. Furthermore, a Law of Cosines computation shows $A_{1} A_{2}^{2}=A B^{2}+A C^{2}+$ $2 \cdot A B \cdot A C \cdot \cos \angle B A C=2 A B^{2}+2 A C^{2}-B C^{2}$, and similarly $B_{1} B_{2}^{2}=2 A B^{2}+2 B C^{2}-A C^{2}$ and $C_{1} C_{2}^{2}=2 B C^{2}+2 A C^{2}-A B^{2}$. Thus the sum of the areas of $A_{1} A_{2} A_{3} A_{4}$ et. al is $3\left(A B^{2}+A C^{2}+B C^{2}\right)$. Finally, the small squares have area add up to $A B^{2}+A C^{2}+B C^{2}$. Aggregating all contributions from trapezoids, squares, and triangle, we get
+
+$$
+\left[A_{5} A_{6} B_{5} B_{6} C_{5} C_{6}\right]=91[A B C]+20\left(A B^{2}+A C^{2}+B C^{2}\right)=7644+11800=19444
+$$
+
+Solution 2. Let $a=B C, b=C A, c=A B$. We can prove S 1 and S 2 using some trigonometry instead.
+Proof of S1. The altitude from $B_{3}$ to $B_{2} C_{1}$ has length $B_{2} B_{3} \sin \angle B B_{2} B_{1}=B_{1} B_{2} \sin \angle B B_{2} B_{1}=$ $B B_{1} \sin \angle B_{1} B B_{2}=A B \sin \angle A B C=h_{a}$ using Law of Sines. Similarly, we find the altitude from $C_{4}$ to $B_{2} C_{1}$ equals $h_{a}$, thus proving $B_{2} C_{1} C_{4} B_{3}$ is a trapezoid. Using $B_{1} B_{2}=\sqrt{2 a^{2}+2 c^{2}-b^{2}}$ from end of Solution 1, we get the length of the projection of $B_{2} B_{3}$ onto $B_{3} C_{4}$ is $B_{2} B_{3} \cos B B_{2} B_{1}=$ $\frac{\left(2 a^{2}+2 c^{2}-b^{2}\right)+a^{2}-c^{2}}{2 a}=\frac{3 a^{2}+c^{2}-b^{2}}{2 a}$, and similarly the projection of $C_{1} C_{4}$ onto $B_{3} C_{4}$ has length $\frac{3 a^{2}+b^{2}-c^{2}}{2 a}$. It follows that $B_{3} C_{4}=\frac{3 a^{2}+c^{2}-b^{2}}{2 a}+a+\frac{3 a^{2}+b^{2}-c^{2}}{2 a}=4 a$, proving S1 for $B_{2} C_{1} C_{4} B_{3}$; the other cases follow similarly.
+Proof of S2. Define $B_{8}$ to be the image of $B$ under the translation taking $B_{1} B_{2}$ to $B_{4} B_{3}$. We claim $B_{8}$ lies on $B_{3} B_{6}$. Indeed, $B_{8} B_{4} B_{3} \cong B B_{1} B_{2}$, so $\angle B_{8} B_{3} B_{4}=\angle B B_{2} B_{1}=180^{\circ}-\angle B_{3} B_{2} C_{1}=\angle B_{2} B_{3} C_{4}$. Thus $\angle B_{8} B_{3} C_{4}=\angle B_{4} B_{3} B_{2}=90^{\circ}$. But $\angle B_{6} B_{3} C_{4}=90^{\circ}$, hence $B_{8}, B_{3}, B_{6}$ are collinear. Similarly we can prove $B_{5} B_{4}$ passes through $B_{8}$, so $B_{8}=B_{7}$. Finally, $\frac{B_{7} B_{3}}{B_{7} B_{6}}=\frac{B_{7} B_{4}}{B_{7} B_{5}}=\frac{1}{5}$ (using $B_{3} B_{6}=4 a, B_{4} B_{5}=$ $4 c, B_{7} B_{3}=a, B_{7} B_{4}=c$ ) shows $B_{7} B_{4} B_{3} \sim B_{7} B_{5} B_{6}$ with scale factor 1:5, as desired. The likewise part follows similarly.
+
diff --git a/HarvardMIT/md/en-222-2019-feb-guts-solutions.md b/HarvardMIT/md/en-222-2019-feb-guts-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..80a790d12e9b3e270f97966efc9a61554d487005
--- /dev/null
+++ b/HarvardMIT/md/en-222-2019-feb-guts-solutions.md
@@ -0,0 +1,632 @@
+# HMMT February 2019
February 16, 2019
Guts Round
+
+1. [3] Find the sum of all real solutions to $x^{2}+\cos x=2019$.
+
+Proposed by: Evan Chen
+Answer: 0
+The left-hand side is an even function, hence for each $x$ that solves the equation, $-x$ will also be a solution. Pairing the solutions up in this way, we get that the sum must be 0 .
+2. [3] There are 100 people in a room with ages $1,2, \ldots, 100$. A pair of people is called cute if each of them is at least seven years older than half the age of the other person in the pair. At most how many pairwise disjoint cute pairs can be formed in this room?
+
+Proposed by: Yuan Yao
+Answer: 43
+For a cute pair $(a, b)$ we would have
+
+$$
+a \geq \frac{b}{2}+7, b \geq \frac{a}{2}+7
+$$
+
+Solving the system, we get that $a$ and $b$ must both be at least 14 . However 14 could only be paired with itself or a smaller number; therefore, only people with age 15 or above can be paired with someone of different age. Pairing consecutive numbers $(15,16),(17,18), \ldots,(99,100)$ works, giving $\frac{100-14}{2}=43$ pairs.
+3. [3] Let $S(x)$ denote the sum of the digits of a positive integer $x$. Find the maximum possible value of $S(x+2019)-S(x)$.
+Proposed by: Alec Sun
+Answer: 12
+We note that $S(a+b) \leq S(a)+S(b)$ for all positive $a$ and $b$, since carrying over will only decrease the sum of digits. (A bit more rigorously, one can show that $S\left(x+a \cdot 10^{b}\right)-S(x) \leq a$ for $0 \leq a \leq 9$.) Hence we have $S(x+2019)-S(x) \leq S(2019)=12$, and equality can be achieved with $x=100000$ for example.
+4. [3] Tessa has a figure created by adding a semicircle of radius 1 on each side of an equilateral triangle with side length 2 , with semicircles oriented outwards. She then marks two points on the boundary of the figure. What is the greatest possible distance between the two points?
+Proposed by: Yuan Yao
+Answer: 3
+Note that both points must be in different semicircles to reach the maximum distance. Let these points be $M$ and $N$, and $O_{1}$ and $O_{2}$ be the centers of the two semicircles where they lie respectively. Then
+
+$$
+M N \leq M O_{1}+O_{1} O_{2}+O_{2} N
+$$
+
+Note that the the right side will always be equal to $3\left(M O_{1}=O_{2} N=1\right.$ from the radius condition, and $O_{1} O_{2}=1$ from being a midline of the equliateral triangle), hence $M N$ can be at most 3 . Finally, if the four points are collinear (when $M$ and $N$ are defined as the intersection of line $O_{1} O_{2}$ with the two semicircles), then equality will hold. Therefore, the greatest possible distance between $M$ and $N$ is 3 .
+5. [4] Call a positive integer $n$ weird if $n$ does not divide $(n-2)$ !. Determine the number of weird numbers between 2 and 100 inclusive.
+
+Proposed by: Yuan Yao
+Answer: 26
+We claim that all the weird numbers are all the prime numbers and 4 . Since no numbers between 1 and $p-2$ divide prime $p,(p-2)$ ! will not be divisible by $p$. We also have $2!=2$ not being a multiple of 4 .
+Now we show that all other numbers are not weird. If $n=p q$ where $p \neq q$ and $p, q \geq 2$, then since $p$ and $q$ both appear in $1,2, \ldots, n-2$ and are distinct, we have $p q \mid(n-2)!$. This leaves the only case of $n=p^{2}$ for prime $p \geq 3$. In this case, we can note that $p$ and $2 p$ are both less than $p^{2}-2$, so $2 p^{2} \mid(n-2)$ ! and we are similarly done.
+Since there are 25 prime numbers not exceeding 100, there are $25+1=26$ weird numbers.
+6. [4] The pairwise products $a b, b c, c d$, and $d a$ of positive integers $a, b, c$, and $d$ are $64,88,120$, and 165 in some order. Find $a+b+c+d$.
+Proposed by: Anders Olsen
+Answer: 42
+The sum $a b+b c+c d+d a=(a+c)(b+d)=437=19 \cdot 23$, so $\{a+c, b+d\}=\{19,23\}$ as having either pair sum to 1 is impossible. Then the sum of all 4 is $19+23=42$. (In fact, it is not difficult to see that the only possible solutions are $(a, b, c, d)=(8,8,11,15)$ or its cyclic permutations and reflections.)
+7. [4] For any real number $\alpha$, define
+
+$$
+\operatorname{sign}(\alpha)= \begin{cases}+1 & \text { if } \alpha>0 \\ 0 & \text { if } \alpha=0 \\ -1 & \text { if } \alpha<0\end{cases}
+$$
+
+How many triples $(x, y, z) \in \mathbb{R}^{3}$ satisfy the following system of equations
+
+$$
+\begin{aligned}
+& x=2018-2019 \cdot \operatorname{sign}(y+z) \\
+& y=2018-2019 \cdot \operatorname{sign}(z+x) \\
+& z=2018-2019 \cdot \operatorname{sign}(x+y) ?
+\end{aligned}
+$$
+
+Proposed by: Pakawut Jiradilok
+Answer: 3
+Since $\operatorname{sign}(x+y)$ can take one of 3 values, $z$ can be one of 3 values: 4037, 2018, or -1 . The same is true of $x$ and $y$. However, this shows that $x+y$ cannot be 0 , so $z$ can only be 4037 or -1 . The same is true of $x$ and $y$. Now note that, if any two of $x, y, z$ are -1 , then the third one must be 4037 . Furthermore, if any one of $x, y, z$ is 4037 , then the other two must be -1 . Thus, the only possibility is to have exactly two of $x, y, z$ be -1 and the third one be 4037 . This means that the only remaining triples are $(-1,-1,4037)$ and its permutations. These all work, so there are exactly 3 ordered triples.
+8. [4] A regular hexagon $P R O F I T$ has area 1. Every minute, greedy George places the largest possible equilateral triangle that does not overlap with other already-placed triangles in the hexagon, with ties broken arbitrarily. How many triangles would George need to cover at least $90 \%$ of the hexagon's area?
+Proposed by: Yuan Yao
+Answer: 46
+It's not difficult to see that the first triangle must connect three non-adjacent vertices (e.g. POI), which covers area $\frac{1}{2}$, and leaves three 30-30-120 triangles of area $\frac{1}{6}$ each. Then, the next three triangles cover $\frac{1}{3}$ of the respective small triangle they are in, and leave six 30-30-120 triangles of area $\frac{1}{18}$ each.
+
+This process continues, doubling the number of 30-30-120 triangles each round and the area of each triangle is divided by 3 each round. After $1+3+6+12+24=46$ triangles, the remaining area is $\frac{3 \cdot 2^{4}}{6 \cdot 3^{4}}=\frac{48}{486}=\frac{8}{81}<0.1$, and the last triangle removed triangle has area $\frac{1}{486}$, so this is the minimum number necessary.
+9. [5] Define $P=\{\mathrm{S}, \mathrm{T}\}$ and let $\mathcal{P}$ be the set of all proper subsets of $P$. (A proper subset is a subset that is not the set itself.) How many ordered pairs $(\mathcal{S}, \mathcal{T})$ of proper subsets of $\mathcal{P}$ are there such that
+(a) $\mathcal{S}$ is not a proper subset of $\mathcal{T}$ and $\mathcal{T}$ is not a proper subset of $\mathcal{S}$; and
+(b) for any sets $S \in \mathcal{S}$ and $T \in \mathcal{T}, S$ is not a proper subset of $T$ and $T$ is not a proper subset of $S$ ?
+
+Proposed by: Yuan Yao
+Answer: 7
+For ease of notation, we let $0=\varnothing, 1=\{\mathrm{S}\}, 2=\{\mathrm{T}\}$. Then both $\mathcal{S}$ and $\mathcal{T}$ are proper subsets of $\{0,1,2\}$. We consider the following cases:
+Case 1. If $\mathcal{S}=\varnothing$, then $\mathcal{S}$ is a proper subset of anyset except the empty set, so we must have $\mathcal{T}=\varnothing$.
+Case 2. If $\mathcal{S}=\{0\}$, then $\mathcal{T}$ cannot be empty, nor can it contain either 1 or 2 , so we must have $\mathcal{T}=\{0\}$. This also implies that if $\mathcal{S}$ contains another element, then there would be no choice of $\mathcal{T}$ because $\{0\}$ would be a proper subset.
+
+Case 3. If $\mathcal{S}=\{1\}$, then $\mathcal{T}$ cannot contain 0 , and cannot contain both 1 and 2 (or it becomes a proper superset of $\mathcal{S}$ ), so it can only be $\{1\}$ or $\{2\}$, and both work. The similar apply when $\mathcal{S}=\{2\}$.
+Case 4. If $\mathcal{S}=\{1,2\}$, then since $\mathcal{T}$ cannot contain 0 , it must contain both 1 and 2 (or it becomes a proper subset of $\mathcal{S}$ ), so $\mathcal{T}=\{1,2\}$.
+Hence, all the possibilities are
+
+$$
+(\mathcal{S}, \mathcal{T})=(\varnothing, \varnothing),(\{0\},\{0\}),(\{1\},\{1\}),(\{1\},\{2\}),(\{2\},\{1\}),(\{2\},\{2\}),(\{1,2\},\{1,2\})
+$$
+
+for 7 possible pairs in total.
+10. [5] Let
+
+$$
+\begin{aligned}
+& A=(1+2 \sqrt{2}+3 \sqrt{3}+6 \sqrt{6})(2+6 \sqrt{2}+\sqrt{3}+3 \sqrt{6})(3+\sqrt{2}+6 \sqrt{3}+2 \sqrt{6})(6+3 \sqrt{2}+2 \sqrt{3}+\sqrt{6}) \\
+& B=(1+3 \sqrt{2}+2 \sqrt{3}+6 \sqrt{6})(2+\sqrt{2}+6 \sqrt{3}+3 \sqrt{6})(3+6 \sqrt{2}+\sqrt{3}+2 \sqrt{6})(6+2 \sqrt{2}+3 \sqrt{3}+\sqrt{6})
+\end{aligned}
+$$
+
+Compute the value of $A / B$.
+Proposed by: Yuan Yao
+Answer: 1
+Note that
+
+$$
+\begin{aligned}
+& A=((1+2 \sqrt{2})(1+3 \sqrt{3}))((2+\sqrt{3})(1+3 \sqrt{2}))((3+\sqrt{2})(1+2 \sqrt{3}))((3+\sqrt{3})(2+\sqrt{2})) \\
+& B=((1+3 \sqrt{2})(1+2 \sqrt{3}))((2+\sqrt{2})(1+3 \sqrt{3}))((3+\sqrt{3})(1+2 \sqrt{2}))((2+\sqrt{3})(3+\sqrt{2}))
+\end{aligned}
+$$
+
+It is not difficult to check that they have the exact same set of factors, so $A=B$ and thus the ratio is 1.
+11. [5] In the Year 0 of Cambridge there is one squirrel and one rabbit. Both animals multiply in numbers quickly. In particular, if there are $m$ squirrels and $n$ rabbits in Year $k$, then there will be $2 m+2019$ squirrels and $4 n-2$ rabbits in Year $k+1$. What is the first year in which there will be strictly more rabbits than squirrels?
+Proposed by: Yuan Yao
+Answer: 13
+
+In year $k$, the number of squirrels is
+
+$$
+2(2(\cdots(2 \cdot 1+2019)+2019)+\cdots)+2019=2^{k}+2019 \cdot\left(2^{k-1}+2^{k-2}+\cdots+1\right)=2020 \cdot 2^{k}-2019
+$$
+
+and the number of rabbits is
+
+$$
+4(4(\cdots(4 \cdot 1-2)-2)-\cdots)-2=4^{k}-2 \cdot\left(4^{k-1}+4^{k-2}+\cdots+1\right)=\frac{4^{k}+2}{3}
+$$
+
+For the number of rabbits to exceed that of squirrels, we need
+
+$$
+4^{k}+2>6060 \cdot 2^{k}-6057 \Leftrightarrow 2^{k}>6059
+$$
+
+Since $2^{13}>6059>2^{12}, k=13$ is the first year for which there are more rabbits than squirrels.
+12. [5] Bob is coloring lattice points in the coordinate plane. Find the number of ways Bob can color five points in $\{(x, y) \mid 1 \leq x, y \leq 5\}$ blue such that the distance between any two blue points is not an integer.
+Proposed by: Michael Ren
+
+## Answer: 80
+
+We can see that no two blue points can have the same $x$ or $y$ coordinate. The blue points then must make a permutation of $1,2,3,4,5$ that avoid the pattern of $3-4-5$ triangles. It is not hard to use complementary counting to get the answer from here.
+There are 8 possible pairs of points that are a distance of 5 apart while not being in the same row or column (i.e. a pair that is in the $3-4-5$ position). If such a pair of points is included in the choice of five points, then there are $3!=6$ possibilities for the remaining three points, yielding $8 \times 6=48$ configurations that have violations. However, we now need to consider overcounting.
+The only way to have more than one violation in one configuration is to have a corner point and then two points adjacent to the opposite corner, e.g. $(1,1),(4,5),(5,4)$. In each such case, there are exactly $2!=2$ possibilities for the other two points, and there are exactly two violations so there are a total of $2 \times 4=8$ configurations that are double-counted.
+Therefore, there are $48-8=40$ permutations that violate the no-integer-condition, leaving $120-40=$ 80 good configurations.
+13. [7] Reimu has 2019 coins $C_{0}, C_{1}, \ldots, C_{2018}$, one of which is fake, though they look identical to each other (so each of them is equally likely to be fake). She has a machine that takes any two coins and picks one that is not fake. If both coins are not fake, the machine picks one uniformly at random. For each $i=1,2, \ldots, 1009$, she puts $C_{0}$ and $C_{i}$ into the machine once, and machine picks $C_{i}$. What is the probability that $C_{0}$ is fake?
+Proposed by: Yuan Yao
+Answer: $\frac{2^{1009}}{2^{1009}+1009}$
+Let $E$ denote the event that $C_{0}$ is fake, and let $F$ denote the event that the machine picks $C_{i}$ over $C_{0}$ for all $i=1,2, \ldots 1009$. By the definition of conditional probability, $P(E \mid F)=\frac{P(E \cap F)}{P(F)}$. Since $E$ implies $F$, $P(E \cap F)=P(E)=\frac{1}{2019}$. Now we want to compute $P(F)$. If $C_{0}$ is fake, $F$ is guaranteed to happen. If $C_{i}$ is fake for some $1 \leq i \leq 1009$, then $F$ is impossible. Finally, if $C_{i}$ is fake for some $1010 \leq i \leq 2018$, then $F$ occurs with probability $2^{-1009}$, since there is a $\frac{1}{2}$ probability for each machine decision. Therefore, $P(F)=\frac{1}{2019} \cdot 1+\frac{1009}{2019} \cdot 0+\frac{1009}{2019} \cdot 2^{-1009}=\frac{2^{1009}+1009}{2019 \cdot 2^{1009}}$. Therefore, $P(E \mid F)=\frac{2^{1009}}{2^{1009}+1009}$.
+14. [7] Let $A B C$ be a triangle where $A B=9, B C=10, C A=17$. Let $\Omega$ be its circumcircle, and let $A_{1}, B_{1}, C_{1}$ be the diametrically opposite points from $A, B, C$, respectively, on $\Omega$. Find the area of the convex hexagon with the vertices $A, B, C, A_{1}, B_{1}, C_{1}$.
+Proposed by: Yuan Yao
+
+
+We first compute the circumradius of $A B C$ : Since $\cos A=\frac{9^{2}-17^{2}-10^{2}}{2 \cdot 9 \cdot 17}=-\frac{15}{17}$, we have $\sin A=\frac{8}{17}$ and $R=\frac{a}{2 \sin A}=\frac{170}{16}$. Moreover, we get that the area of triangle $A B C$ is $\frac{1}{2} b c \sin A=36$.
+Note that triangle $A B C$ is obtuse, The area of the hexagon is equal to twice the area of triangle $A B C$ (which is really $[A B C]+\left[A_{1} B_{1} C_{1}\right]$ ) plus the area of rectangle $A C A_{1} C_{1}$. The dimensions of $A C A_{1} C_{1}$ are $A C=17$ and $A_{1} C=\sqrt{(2 R)^{2}-A C^{2}}=\frac{51}{4}$, so the area of the hexagon is $36 \cdot 2+17 \cdot \frac{51}{4}=\frac{1155}{4}$.
+15. [7] Five people are at a party. Each pair of them are friends, enemies, or frenemies (which is equivalent to being both friends and enemies). It is known that given any three people $A, B, C$ :
+
+- If $A$ and $B$ are friends and $B$ and $C$ are friends, then $A$ and $C$ are friends;
+- If $A$ and $B$ are enemies and $B$ and $C$ are enemies, then $A$ and $C$ are friends;
+- If $A$ and $B$ are friends and $B$ and $C$ are enemies, then $A$ and $C$ are enemies.
+
+How many possible relationship configurations are there among the five people?
+Proposed by: Yuan Yao
+Answer: 17
+If $A$ and $B$ are frenemies, then regardless of whether another person $C$ is friends or enemies with $A$, $C$ will have to be frenemies with $B$ and vice versa. Therefore, if there is one pair of frenemies then all of them are frenemies with each other, and there is only one possibility.
+If there are no frenemies, then one can always separate the five people into two possibly "factions" (one of which may be empty) such that two people are friends if and only if they belong to the same faction. Since the factions are unordered, there are $2^{5} / 2=16$ ways to assign the "alignments" that each gives a unique configuration of relations. So in total there are $16+1=17$ possibilities.
+16. [7] Let $\mathbb{R}$ be the set of real numbers. Let $f: \mathbb{R} \rightarrow \mathbb{R}$ be a function such that for all real numbers $x$ and $y$, we have
+
+$$
+f\left(x^{2}\right)+f\left(y^{2}\right)=f(x+y)^{2}-2 x y
+$$
+
+Let $S=\sum_{n=-2019}^{2019} f(n)$. Determine the number of possible values of $S$.
+Proposed by: Yuan Yao
+Answer: 2039191 OR $\binom{2020}{2}+1$
+Letting $y=-x$ gives
+
+$$
+f\left(x^{2}\right)+f\left(x^{2}\right)=f(0)^{2}+2 x^{2}
+$$
+
+for all $x$. When $x=0$ the equation above gives $f(0)=0$ or $f(0)=2$.
+If $f(0)=2$, then $f(x)=x+2$ for all nonegative $x$, so the LHS becomes $x^{2}+y^{2}+4$, and RHS becomes $x^{2}+y^{2}+4 x+4 y+4$ for all $x+y \geq 0$, which cannot be equal to LHS if $x+y>0$.
+If $f(0)=0$ then $f(x)=x$ for all nonnegative $x$. Moreover, letting $y=0$ gives
+
+$$
+f\left(x^{2}\right)=f(x)^{2} \Rightarrow f(x)= \pm x
+$$
+
+for all $x$. Since negative values are never used as inputs on the LHS and the output on the RHS is always squared, we may conclude that for all negative $x, f(x)=x$ and $f(x)=-x$ are both possible (and the values are independent). Therefore, the value of $S$ can be written as
+
+$$
+S=f(0)+(f(1)+f(-1))+(f(2)+f(-2))+\cdots+(f(2019)+f(-2019))=2 \sum_{i=1}^{2019} i \delta_{i}
+$$
+
+for $\delta_{1}, \delta_{2}, \ldots, \delta_{2019} \in\{0,1\}$. It is not difficult to see that $\frac{S}{2}$ can take any integer value between 0 and $\frac{2020 \cdot 2019}{2}=2039190$ inclusive, so there are 2039191 possible values of $S$.
+17. [9] Let $A B C$ be a triangle with $A B=3, B C=4$, and $C A=5$. Let $A_{1}, A_{2}$ be points on side $B C$, $B_{1}, B_{2}$ be points on side $C A$, and $C_{1}, C_{2}$ be points on side $A B$. Suppose that there exists a point $P$ such that $P A_{1} A_{2}, P B_{1} B_{2}$, and $P C_{1} C_{2}$ are congruent equilateral triangles. Find the area of convex hexagon $A_{1} A_{2} B_{1} B_{2} C_{1} C_{2}$.
+Proposed by: Michael Ren
+Answer: $\frac{12+22 \sqrt{3}}{15}$
+Since $P$ is the shared vertex between the three equilateral triangles, we note that $P$ is the incenter of $A B C$ since it is equidistant to all three sides. Since the area is 6 and the semiperimeter is also 6 , we can calculate the inradius, i.e. the altitude, as 1 , which in turn implies that the side length of the equilateral triangle is $\frac{2}{\sqrt{3}}$. Furthermore, since the incenter is the intersection of angle bisectors, it is easy to see that $A B_{2}=A C_{1}, B C_{2}=B A_{1}$, and $C A_{2}=C B_{1}$. Using the fact that the altitudes from $P$ to $A B$ and $C B$ form a square with the sides, we use the side lengths of the equilateral triangle to compute that $A B_{2}=A C_{1}=2-\frac{1}{\sqrt{3}}, B A_{1}=B C_{2}=1-\frac{1}{\sqrt{3}}$, and $C B_{1}=C A_{2}=3-\frac{1}{\sqrt{3}}$. We have that the area of the hexagon is therefore
+
+$$
+6-\left(\frac{1}{2}\left(2-\frac{1}{\sqrt{3}}\right)^{2} \cdot \frac{4}{5}+\frac{1}{2}\left(1-\frac{1}{\sqrt{3}}\right)^{2}+\frac{1}{2}\left(3-\frac{1}{\sqrt{3}}\right)^{2} \cdot \frac{3}{5}\right)=\frac{12+22 \sqrt{3}}{15} .
+$$
+
+18. [9] 2019 points are chosen independently and uniformly at random on the interval $[0,1]$. Tairitsu picks 1000 of them randomly and colors them black, leaving the remaining ones white. Hikari then computes the sum of the positions of the leftmost white point and the rightmost black point. What is the probability that this sum is at most 1?
+Proposed by: Yuan Yao
+
+## Answer: $\frac{1019}{2019}$
+
+Note that each point is chosen uniformly and independently from 0 to 1 , so we can apply symmetry. Given any coloring, suppose that we flip all the positions of the black points: then the problem becomes computing the probability that the leftmost white point is to the left of the leftmost black point, which is a necessary and sufficient condition for the sum of the original leftmost white point and the original rightmost black point being at most 1. This condition, however, is equivalent to the leftmost point of all 2019 points being white. Since there are 1019 white points and 1000 black points and each point is equally likely to be the leftmost, this happens with probability $\frac{1019}{2019}$.
+19. [9] Complex numbers $a, b, c$ form an equilateral triangle with side length 18 in the complex plane. If $|a+b+c|=36$, find $|b c+c a+a b|$.
+Proposed by: Henrik Boecken
+Answer: 432
+Using basic properties of vectors, we see that the complex number $d=\frac{a+b+c}{3}$ is the center of the triangle. From the given, $|a+b+c|=36 \Longrightarrow|d|=12$. Then, let $a^{\prime}=a-d, b^{\prime}=b-d$, and $c^{\prime}=c-d$. Due to symmetry, $\left|a^{\prime}+b^{\prime}+c^{\prime}\right|=0$ and $\left|b^{\prime} c^{\prime}+c^{\prime} a^{\prime}+a^{\prime} b^{\prime}\right|=0$.
+Finally, we compute
+
+$$
+\begin{aligned}
+|b c+c a+a b| & =\left|\left(b^{\prime}+d\right)\left(c^{\prime}+d\right)+\left(c^{\prime}+d\right)\left(a^{\prime}+d\right)+\left(a^{\prime}+d\right)\left(b^{\prime}+d\right)\right| \\
+& =\left|b^{\prime} c^{\prime}+c^{\prime} a^{\prime}+a^{\prime} b^{\prime}+2 d\left(a^{\prime}+b^{\prime}+c^{\prime}\right)+3 d^{2}\right| \\
+& =\left|3 d^{2}\right|=3 \cdot 12^{2}=432
+\end{aligned}
+$$
+
+20. [9] On floor 0 of a weird-looking building, you enter an elevator that only has one button. You press the button twice and end up on floor 1. Thereafter, every time you press the button, you go up by one floor with probability $\frac{X}{Y}$, where $X$ is your current floor, and $Y$ is the total number of times you have pressed the button thus far (not including the current one); otherwise, the elevator does nothing.
+
+Between the third and the $100^{\text {th }}$ press inclusive, what is the expected number of pairs of consecutive presses that both take you up a floor?
+Proposed by: Kevin Yang
+Answer: $\frac{97}{3}$
+By induction, we can determine that after $n$ total button presses, your current floor is uniformly distributed from 1 to $n-1$ : the base case $n=2$ is trivial to check, and for the $n+1$ th press, the probability that you are now on floor $i$ is $\frac{1}{n-1}\left(1-\frac{i}{n}\right)+\frac{1}{n-1}\left(\frac{i-1}{n}\right)=\frac{1}{n}$ for $i=1,2, \ldots, n$, finishing the inductive step.
+Hence, the probability that the $(n+1)$-th and $(n+2)$-th press both take you up a floor is
+
+$$
+\frac{1}{n-1} \sum_{i=1}^{n-1} \frac{i}{n} \cdot \frac{i+1}{n+1}=\frac{\sum_{i=1}^{n-1} i^{2}+i}{(n-1) n(n+1)}=\frac{\frac{(n-1) n(2 n-1)}{6}+\frac{n(n-1)}{2}}{(n-1) n(n+1)}=\frac{1}{3}
+$$
+
+Since there are $100-3=97$ possible pairs of consecutive presses, the expected value is $\frac{97}{3}$.
+21. [12] A regular hexagon $A B C D E F$ has side length 1 and center $O$. Parabolas $P_{1}, P_{2}, \ldots, P_{6}$ are constructed with common focus $O$ and directrices $A B, B C, C D, D E, E F, F A$ respectively. Let $\chi$ be the set of all distinct points on the plane that lie on at least two of the six parabolas. Compute
+
+$$
+\sum_{X \in \chi}|O X|
+$$
+
+(Recall that the focus is the point and the directrix is the line such that the parabola is the locus of points that are equidistant from the focus and the directrix.)
+Proposed by: Yuan Yao
+Answer: $35 \sqrt{3}$
+Recall the focus and the directrix are such that the parabola is the locus of points equidistant from the focus and the directrix. We will consider pairs of parabolas and find their points of intersections (we label counterclockwise):
+(1): $P_{1} \cap P_{2}$, two parabolas with directrices adjacent edges on the hexagon (sharing vertex $A$ ). The intersection inside the hexagon can be found by using similar triangles: by symmetry this $X$ must lie on $O A$ and must have that its distance from $A B$ and $F A$ are equal to $|O X|=x$, which is to say
+
+$$
+\sin 60^{\circ}=\frac{\sqrt{3}}{2}=\frac{x}{|O A|-x}=\frac{x}{1-x} \Longrightarrow x=2 \sqrt{3}-3
+$$
+
+By symmetry also, the second intersection point, outside the hexagon, must lie on $O D$. Furthermore, $X$ must have that its distance $A B$ and $F A$ are equal to $|O X|$. Then again by similar triangles
+
+$$
+\sin 60^{\circ}=\frac{\sqrt{3}}{2}=\frac{x}{|O A|+x}=\frac{x}{1+x} \Longrightarrow x=2 \sqrt{3}+3
+$$
+
+(2): $P_{1} \cap P_{3}$, two parabolas with directrices edges one apart on the hexagon, say $A B$ and $C D$. The intersection inside the hexagon is clearly immediately the circumcenter of triangle $B O C$ (equidistance condition), which gives
+
+$$
+x=\frac{\sqrt{3}}{3}
+$$
+
+Again by symmetry the $X$ outside the hexagon must lie on the lie through $O$ and the midpoint of $E F$; then one can either observe immediately that $x=\sqrt{3}$ or set up
+
+$$
+\sin 30^{\circ}=\frac{1}{2}=\frac{x}{x+\sqrt{3}} \Longrightarrow x=\sqrt{3}
+$$
+
+where we notice $\sqrt{3}$ is the distance from $O$ to the intersection of $A B$ with the line through $O$ and the midpoint of $B C$.
+(3): $P_{1} \cap P_{4}$, two parabolas with directrices edges opposite on the hexagon, say $A B$ and $D E$. Clearly the two intersection points are both inside the hexagon and must lie on $C F$, which gives
+
+$$
+x=\frac{\sqrt{3}}{2} .
+$$
+
+These together give that the sum desired is
+
+$$
+6(2 \sqrt{3}-3)+6(2 \sqrt{3}+3)+6\left(\frac{\sqrt{3}}{3}\right)+6(\sqrt{3})+6\left(\frac{\sqrt{3}}{2}\right)=35 \sqrt{3}
+$$
+
+22. [12] Determine the number of subsets $S$ of $\{1,2, \ldots, 1000\}$ that satisfy the following conditions:
+
+- $S$ has 19 elements, and
+- the sum of the elements in any non-empty subset of $S$ is not divisible by 20 .
+
+Proposed by: Alec Sun
+Answer: $8 \cdot\binom{50}{19}$
+First we prove that each subset must consist of elements that have the same residue mod 20 . Let a subset consist of elements $a_{1}, \ldots, a_{19}$, and consider two lists of partial sums
+
+$$
+\begin{aligned}
+& a_{1}, a_{1}+a_{2}, a_{1}+a_{2}+a_{3}, \ldots, a_{1}+a_{2}+\cdots+a_{19} \\
+& a_{2}, a_{1}+a_{2}, a_{1}+a_{2}+a_{3}, \ldots, a_{1}+a_{2}+\cdots+a_{19}
+\end{aligned}
+$$
+
+The residues mod 20 of the partial sums in each list must be pairwise distinct, otherwise subtracting the sum with less terms from the sum with more terms yields a subset whose sum of elements is 0 (mod 20). Since the residues must also be nonzero, each list forms a complete nonzero residue class $\bmod 20$. Since the latter 18 sums in the two lists are identical, $a_{1} \equiv a_{2}(\bmod 20)$. By symmetric arguments, $a_{i} \equiv a_{j}(\bmod 20)$ for any $i, j$.
+Furthermore this residue $1 \leq r \leq 20$ must be relatively prime to 20 , because if $d=\operatorname{gcd}(r, 20)>1$ then any $20 / d$ elements of the subset will sum to a multiple of 20 . Hence there are $\varphi(20)=8$ possible residues. Since there are 50 elements in each residue class, the answer is $\binom{50}{19}$. We can see that any such subset whose elements are a relatively prime residue $r(\bmod 20)$ works because the sum of any $1 \leq k \leq 19$ elements will be $k r \neq 0(\bmod 20)$.
+23. [12] Find the smallest positive integer $n$ such that
+
+$$
+\underbrace{2^{2^{2} \omega^{2}}}_{n 2^{\prime} \mathrm{s}}>\underbrace{((\cdots((100!)!)!\cdots)!)!}_{100 \text { factorials }}
+$$
+
+Proposed by: Zack Chroman
+Answer: 104
+Note that $2^{2^{2^{2}}}>100^{2}$. We claim that $a>b^{2} \Longrightarrow 2^{a}>(b!)^{2}$, for $b>2$. This is because
+
+$$
+2^{a}>b^{2 b} \Longleftrightarrow a>2 b \log _{2}(b)
+$$
+
+and $\log _{2}(b)2$. Then since $b^{b}>b$ ! this bound works. Then
+
+$$
+\underbrace{\left(2^{2^{2^{\cdots 2}}}\right)}_{m 2^{\prime} \mathrm{s}}>\underbrace{((((100!)!)!)!\ldots)^{2}}_{m-4 \text { factorials }}
+$$
+
+for all $m \geq 4$ by induction. So $n=104$ works. The lower bound follows from the fact that $n!>2^{n}$ for $n>3$, and since $100>2^{2^{2}}$, we have
+
+$$
+\underbrace{(((100!)!)!)!\ldots)}_{100 \text { factorials }}>\underbrace{2^{2 \cdots^{2^{100}}}}_{1002 \text { 's }}>\underbrace{2^{2 \omega^{2}}}_{1032 \text { 's }}
+$$
+
+24. [12] Let $S$ be the set of all positive factors of 6000 . What is the probability of a random quadruple $(a, b, c, d) \in S^{4}$ satisfies
+
+$$
+\operatorname{lcm}(\operatorname{gcd}(a, b), \operatorname{gcd}(c, d))=\operatorname{gcd}(\operatorname{lcm}(a, b), \operatorname{lcm}(c, d)) ?
+$$
+
+Proposed by: Yuan Yao
+
+## Answer: $\frac{41}{512}$
+
+For each prime factor, let the greatest power that divides $a, b, c, d$ be $p, q, r, s$. WLOG assume that $p \leq q$ and $r \leq s$, and further WLOG assume that $p \leq r$. Then we need $r=\min (q, s)$. If $q=r$ then we have $p \leq q=r \leq s$, and if $r=s$ then we have $p \leq r=s \leq q$, and in either case the condition reduces to the two "medians" among $p, q, r, s$ are equal. (It is not difficult to see that this condition is also sufficient.)
+Now we compute the number of quadruples ( $p, q, r, s$ ) of integers between 0 and $n$ inclusive that satisfy the above condition. If there are three distinct numbers then there are $\binom{n+1}{3}$ ways to choose the three numbers and $4!/ 2=12$ ways to assign them (it must be a $1-2-1$ split). If there are two distinct numbers then there are $\binom{n+1}{2}$ ways to choose the numbers and $4+4=8$ ways to assign them (it must be a $3-1$ or a $1-3$ split). If there is one distinct number then there are $n+1$ ways to assign. Together we have
+
+$$
+12\binom{n+1}{3}+8\binom{n+1}{2}+(n+1)=2(n+1) n(n-1)+4(n+1) n+(n+1)=(n+1)(2 n(n+1)+1)
+$$
+
+possible quadruples. So if we choose a random quadruple then the probability that it satisfies the condition is $\frac{(n+1)(2 n(n+1)+1)}{(n+1)^{4}}=\frac{2 n(n+1)+1}{(n+1)^{3}}$.
+Since $6000=2^{4} \cdot 5^{3} \cdot 3^{1}$ and the power of different primes are independent, we plug in $n=4,3,1$ to get the overall probability to be
+
+$$
+\frac{41}{125} \cdot \frac{25}{64} \cdot \frac{5}{8}=\frac{41}{512}
+$$
+
+25. [15] A 5 by 5 grid of unit squares is partitioned into 5 pairwise incongruent rectangles with sides lying on the gridlines. Find the maximum possible value of the product of their areas.
+Proposed by: Yuan Yao
+Answer: 2304
+The greatest possible value for the product is $3 \cdot 4 \cdot 4 \cdot 6 \cdot 8=2304$, achieved when the rectangles are $3 \times 1,1 \times 4,2 \times 2,2 \times 3,4 \times 2$. To see that this is possible, orient these rectangles so that the first number is the horizontal dimension and the second number is the vertical dimension. Then, place the bottom-left corners of these rectangles at $(2,4),(4,0),(2,2),(0,2),(0,0)$ respectively on the grid.
+We will now prove that no larger product can be achieved. Suppose that there is at least one rectangle of area at most 2 . Then the product is at most $2 \cdot 5.75^{4}=2 \cdot 33.0625^{2}<2 \cdot 1100=2200$ by AM-GM. Now suppose that there is at least one rectangle of area at least 9 . Then the product is at most $9 \cdot 4^{4}=2304$ by AM-GM. (Neither of these is tight, since you cannot have non-integer areas, nor can you have four rectangles all of area 4.)
+Now consider the last possibility that is not covered by any of the above: that there are no rectangles of size at most 2 and no rectangles of area at least 9 . There can be at most one rectangle of area $3,5,6,8$ each, at most two rectangles of area 4 , and no rectangles of area 7 . The only way to achieve a sum of 25 with these constraints is $3,4,4,6,8$, which produces a product of 2304 . We have shown through the earlier cases that a larger product cannot be achieved, so this is indeed the maximum.
+26. [15] Let $A B C$ be a triangle with $A B=13, B C=14, C A=15$. Let $I_{A}, I_{B}, I_{C}$ be the $A, B, C$ excenters of this triangle, and let $O$ be the circumcenter of the triangle. Let $\gamma_{A}, \gamma_{B}, \gamma_{C}$ be the corresponding excircles and $\omega$ be the circumcircle. $X$ is one of the intersections between $\gamma_{A}$ and $\omega$. Likewise, $Y$ is an intersection of $\gamma_{B}$ and $\omega$, and $Z$ is an intersection of $\gamma_{C}$ and $\omega$. Compute
+
+$$
+\cos \angle O X I_{A}+\cos \angle O Y I_{B}+\cos \angle O Z I_{C} .
+$$
+
+Proposed by: Andrew Gu
+Answer:
+
+
+Let $r_{A}, r_{B}, r_{C}$ be the exradii. Using $O X=R, X I_{A}=r_{A}, O I_{A}=\sqrt{R\left(R+2 r_{A}\right)}$ (Euler's theorem for excircles), and the Law of Cosines, we obtain
+
+$$
+\cos \angle O X I_{A}=\frac{R^{2}+r_{A}^{2}-R\left(R+2 r_{A}\right)}{2 R r_{A}}=\frac{r_{A}}{2 R}-1 .
+$$
+
+Therefore it suffices to compute $\frac{r_{A}+r_{B}+r_{C}}{2 R}-3$. Since
+
+$$
+r_{A}+r_{B}+r_{C}-r=2 K\left(\frac{1}{-a+b+c}+\frac{1}{a-b+c}+\frac{1}{a+b-c}-\frac{1}{a+b+c}\right)=2 K \frac{8 a b c}{(4 K)^{2}}=\frac{a b c}{K}=4 R
+$$
+
+where $K=[A B C]$, this desired quantity the same as $\frac{r}{2 R}-1$. For this triangle, $r=4$ and $R=\frac{65}{8}$, so the answer is $\frac{4}{65 / 4}-1=-\frac{49}{65}$.
+27. [15] Consider the eighth-sphere $\left\{(x, y, z) \mid x, y, z \geq 0, x^{2}+y^{2}+z^{2}=1\right\}$. What is the area of its projection onto the plane $x+y+z=1$ ?
+Proposed by: Yuan Yao
+Answer: $\frac{\pi \sqrt{3}}{4}$
+Consider the three flat faces of the eighth-ball. Each of these is a quarter-circle of radius 1 , so each has area $\frac{\pi}{4}$. Furthermore, the projections of these faces cover the desired area without overlap. To find the projection factor one can find the cosine of the angle $\theta$ between the planes, which is the same as the angle between their normal vectors. Using the dot product formula for the cosine of the angle between two vectors, $\cos \theta=\frac{(1,0,0) \cdot(1,1,1)}{|(1,0,0)|(1,1,1) \mid}=\frac{1}{\sqrt{3}}$. Therefore, each area is multiplied by $\frac{1}{\sqrt{3}}$ by the projection, so the area of the projection is $3 \cdot \frac{\pi}{4} \cdot \frac{1}{\sqrt{3}}=\frac{\pi \sqrt{3}}{4}$.
+28. [15] How many positive integers $2 \leq a \leq 101$ have the property that there exists a positive integer $N$ for which the last two digits in the decimal representation of $a^{2^{n}}$ is the same for all $n \geq N$ ?
+Proposed by: Pakawut Jiradilok
+Answer: 36
+Solution 1. It suffices to consider the remainder mod 100. We start with the four numbers that have the same last two digits when squared: $0,1,25,76$.
+We can now go backwards, repeatedly solving equations of the form $x^{2} \equiv n(\bmod 100)$ where $n$ is a number that already satisfies the condition.
+0 and 25 together gives all multiples of 5 , for 20 numbers in total.
+1 gives $1,49,51,99$, and 49 then gives $7,43,57,93$. Similarly 76 gives $24,26,74,76$, and 24 then gives $18,32,68,82$, for 16 numbers in total.
+Hence there are $20+16=36$ such numbers in total.
+Solution 2. An equivalent formulation of the problem is to ask for how many elements of $\mathbb{Z}_{100}$ the map $x \mapsto x^{2}$ reaches a fixed point. We may separately solve this modulo 4 and modulo 25.
+Modulo 4, it is easy to see that all four elements work.
+
+Modulo 25 , all multiples of 5 will work, of which there are 5 . For the remaining 25 elements that are coprime to 5 , we may use the existence of a primitive root to equivalently ask for how many elements of $\mathbb{Z}_{20}$ the map $y \mapsto 2 y$ reaches a fixed point. The only fixed point is 0 , so the only valid choices are the multiples of 5 again. There are $5+4=9$ solutions here.
+Finally, the number of solutions modulo 100 is $4 \times 9=36$.
+29. [20] Yannick picks a number $N$ randomly from the set of positive integers such that the probability that $n$ is selected is $2^{-n}$ for each positive integer $n$. He then puts $N$ identical slips of paper numbered 1 through $N$ into a hat and gives the hat to Annie. Annie does not know the value of $N$, but she draws one of the slips uniformly at random and discovers that it is the number 2 . What is the expected value of $N$ given Annie's information?
+
+Proposed by: Yuan Yao
+Answer: $\frac{1}{2 \ln 2-1}$
+Let $S$ denote the value drawn from the hat. The probability that 2 is picked is $\frac{1}{n}$ if $n \geq 2$ and 0 if $n=1$. Thus, the total probability $X$ that 2 is picked is
+
+$$
+P(S=2)=\sum_{k=2}^{\infty} \frac{2^{-k}}{k}
+$$
+
+By the definition of conditional probability, $P(N=n \mid S=2)=\frac{P(N=n, S=2)}{P(S=2)}=\frac{2^{-n} / n}{X}$ if $n \geq 2$ and 0 if $n=1$. Thus the conditional expectation of $N$ is
+
+$$
+\mathbb{E}[N \mid S=2]=\sum_{n=1}^{\infty} n \cdot P(N=n \mid S=2)=\sum_{n=2}^{\infty} n \cdot \frac{2^{-n} / n}{X}=\frac{1}{X} \sum_{n=2}^{\infty} 2^{-n}=\frac{1}{2 X}
+$$
+
+It remains to compute $X$. Note that $\sum_{k=0}^{\infty} x^{k}=\frac{1}{1-x}$ for $|x|<1$. Integrating both sides with respect to $x$ yields
+
+$$
+\sum_{k=1}^{\infty} \frac{x^{k}}{k}=-\ln (1-x)+C
+$$
+
+for some constant $C$, and plugging in $x=0$ shows that $C=0$. Plugging in $x=\frac{1}{2}$ shows that $\sum_{k=1}^{\infty} \frac{2^{-k}}{k}=\ln 2$. Note that $X$ is exactly this summation but without the first term. Thus, $X=\ln 2-\frac{1}{2}$, so $\frac{1}{2 X}=\frac{1}{2 \ln 2-1}$.
+30. [20] Three points are chosen inside a unit cube uniformly and independently at random. What is the probability that there exists a cube with side length $\frac{1}{2}$ and edges parallel to those of the unit cube that contains all three points?
+Proposed by: Yuan Yao
+Answer: $\frac{1}{8}$
+Let the unit cube be placed on a $x y z$-coordinate system, with edges parallel to the $x, y, z$ axes. Suppose the three points are labeled $A, B, C$. If there exists a cube with side length $\frac{1}{2}$ and edges parallel to the edges of the unit cube that contain all three points, then there must exist a segment of length $\frac{1}{2}$ that contains all three projections of $A, B, C$ onto the $x$-axis. The same is true for the $y$ - and $z$ - axes. Likewise, if there exists segments of length $\frac{1}{2}$ that contains each of the projections of $A, B, C$ onto the $x, y$, and $z$ axes, then there must exist a unit cube of side length $\frac{1}{2}$ that contains $A, B, C$. It is easy to see that the projection of a point onto the $x$-axis is uniform across a segment of length 1 , and that each of the dimensions are independent. The problem is therefore equivalent to finding the cube of the probability that a segment of length $\frac{1}{2}$ can cover three points chosen randomly on a segment of length 1.
+
+Note that selecting three numbers $p2$ and positive integers $k, \lambda\left(p^{k}\right)=(p-1) p^{k-1}$.
+- For a positive integer $k$,
+
+$$
+\lambda\left(2^{k}\right)= \begin{cases}2^{k-2} & \text { if } k \geq 3 \\ 2^{k-1} & \text { if } k \leq 2\end{cases}
+$$
+
+- For a positive integer $n$ with prime factorization $n=\prod p_{i}^{k_{i}}$,
+
+$$
+\lambda(n)=\operatorname{lcm}\left(\lambda\left(p_{1}^{k_{1}}\right), \lambda\left(p_{2}^{k_{2}}\right), \ldots\right)
+$$
+
+Meanwhile, for $n=\prod p_{i}^{k_{i}}$, we have $\varphi(n)=\prod\left(p_{i}-1\right) p_{i}^{k_{i}-1}$. Hence the intuition is roughly that the $\left(p_{i}-1\right) p_{i}^{k_{i}-1}$ terms must share divisors in order to reach a high value of $\frac{\varphi(n)}{\lambda(n)}$.
+We will now show that $n \geq 240$ by doing casework on the prime divisors of $z=\frac{\varphi(n)}{\lambda(n)}$. Suppose $p \mid z$ and $p>2$. This requires two terms among $\lambda\left(p_{1}^{k_{1}}\right), \lambda\left(p_{2}^{k_{2}}\right), \ldots$ to be multiples of $p$ because $\lambda(n)$ is the lcm of the terms whereas the product of these numbers has the same number of factors of $p$ as $\varphi(n)$ (note that this does not hold for $p=2$ because $\lambda\left(2^{k}\right) \neq 2^{k-1}$ in general). These correspond to either $p^{2} \mid n$ or $q \mid n$ with $q \equiv 1(\bmod p)$. Therefore
+
+$$
+n \geq \max \left(p^{2}(2 p+1),(2 p+1)(4 p+1)\right)
+$$
+
+because the smallest primes congruent to $1(\bmod p)$ are at least $2 p+1$ and $4 p+1$. For $p \geq 5$ this gives $n>240$, so we may assume $p \leq 3$.
+First we address the case $p=3$. This means that two numbers among $9,7,13,19,31,37, \ldots$ divide $n$. As $7 \times 37>240$, we discard primes greater than 31 . Of the remaining numbers, we have
+
+$$
+\lambda(9)=6, \lambda(7)=6, \lambda(13)=12, \lambda(19)=18, \lambda(31)=30 .
+$$
+
+No candidate value of $n$ is the product of just two of these numbers as the gcd of any two of the associated $\lambda$ values is at most 6 . Furthermore, multiplying by just 2 will not affect $\varphi(n)$ or $\lambda(n)$, so we must multiply at least two of these numbers by a number greater than 2 . Throwing out numbers greater than 240 , this leaves only $3 \times 9 \times 7$, which does not work. (A close candidate is $3 \times 7 \times 13=273$, for which $\varphi(n)=144, \lambda(n)=12$.)
+
+The remaining case is when the only prime divisors of $\frac{\varphi(n)}{\lambda(n)}$ are 2 . It is not hard to see that $\lambda(n) \geq 4$ when $n \nmid 24$ (and when $n \mid 24$ it's clear that $\phi(n) \leq 8$, so we do not need to consider them). When $\lambda(n)=4$, we need $\varphi(n) \geq 4 \cdot 2^{4}=64$ and $v_{2}(n) \leq 4$, so the smallest such integer is $n=2^{4} \cdot 3 \cdot 5=240$, which we can check does indeed satisfy $\frac{\varphi(n)}{\lambda(n)}>10$. It is not difficult to check that higher values of $\lambda(n)$ will not yield any $n$ below 240, so 240 is indeed the smallest possible $n$.
+Note: The sequence $\frac{\varphi(n)}{\lambda(n)}$ is given by A034380 in the OEIS.
+$H_{1}$. Let $r=H_{1}$ be the answer to this problem. Given that $r$ is a nonzero real number, what is the value of $r^{4}+4 r^{3}+6 r^{2}+4 r$ ?
+Answer: -1
+Since $H_{1}$ is the answer, we know $r^{4}+4 r^{3}+6 r^{2}+4 r=r \Rightarrow(r+1)^{4}=r+1$. Either $r+1=0$, or $(r+1)^{3}=1 \Rightarrow r=0$. Since $r$ is nonzero, $r=-1$.
+$H_{2}$. Given two distinct points $A, B$ and line $\ell$ that is not perpendicular to $A B$, what is the maximum possible number of points $P$ on $\ell$ such that $A B P$ is an isosceles triangle?
+
+## Answer: 5
+
+In an isosceles triangle, one vertex lies on the perpendicular bisector of the opposite side. Thus, either $P$ is the intersection of $A B$ and $\ell$, or $P$ lies on the circle centered at $A$ with radius $A B$, or $P$ lies on the circle centered at $B$ with radius $A B$. Each circle-line intersection has at most two solutions, and the line-line intersection has at most one, giving 5 . This can be easily constructed by taking any $\overline{A B}$, and taking $\ell$ that isn't a diameter but intersects both relevant circles twice.
+$H_{3}$. Let $A=H_{1}, B=H_{6}+1$. A real number $x$ is chosen randomly and uniformly in the interval $[A, B]$. Find the probability that $x^{2}>x^{3}>x$.
+
+## Answer:
$\square$
+
+$A=-1, B=3$. For $x^{3}>x$, either $x>1$ or $-1
$\square$
+
+Extending three sides of the equiangular hexagon gives an equilateral triangle. Thus, if the sides are $a, b, c, d, e, f$, in order, then $a+b+c=a+f+e \Rightarrow b+c=e+f \Rightarrow f-c=b-e$. By a symmetric argument, we see that $d-a=f-c=b-e$ holds, which means that they must be separated into three groups of two with equal differences. If the grouping is $(1,2),(3,4),(5,6)$, then we have $1,4,5,2,3,6$ around the hexagon. If the grouping is $(1,4),(2,5),(3,6)$, then we get $1,5,3,4,2,6$ as the other possibility. Finally, we can use our equilateral triangle trick to find the areas. For the first, we get a big triangle of side $1+4+5=10$, and must subtract smaller triangles of sides $1,5,3$. This gives $(100-1-25-9) \sqrt{3} / 4=65 \sqrt{3} / 4$. For the other, we get $(81-1-9-4) \sqrt{3} / 4=67 \sqrt{3} / 4$. The positive difference between these is $\sqrt{3} / 2$.
+$M_{12}$. Determine the second smallest positive integer $n$ such that $n^{3}+n^{2}+n+1$ is a perfect square.
+Answer: 7
+$n^{3}+n^{2}+n+1=(n+1)\left(n^{2}+1\right)$. Note that $\operatorname{gcd}\left(n^{2}+1, n+1\right)=\operatorname{gcd}(2, n+1)=1$ or 2 , and since $n^{2}+1$ is not a perfect square for $n \geq 1$, we must have $n^{2}+1=2 p^{2}$ and $n+1=2 q^{2}$ for some integers $p$ and $q$. The first equation is a variant of Pell's equation, which (either by brute-forcing small cases or using the known recurrence) gives solutions $(n, p)=(1,1),(7,5), \ldots$ Incidentally, both smallest solutions $n=1$ and $n=7$ allows an integer solution to the second equation, so $n=7$ is the second smallest integer that satisfy the condition.
+$M_{13}$. Given that $A, B$ are nonzero base-10 digits such that $A \cdot \overline{A B}+B=\overline{B B}$, find $\overline{A B}$.
+Answer: 25
+We know $A \cdot \overline{A B}$ ends in 0 . Since neither is 0 , they must be 2,5 in some order. We easily find that $A=2, B=5$ works while the opposite doesn't, so $\overline{A B}=25$.
+$T_{1}$. Let $S, P, A, C, E$ be (not necessarily distinct) decimal digits where $E \neq 0$. Given that $N=\sqrt{\overline{E S C A P E}}$ is a positive integer, find the minimum possible value of $N$.
+Answer: 319
+Since $E \neq 0$, the 6 -digit number $\overline{E S C A P E}$ is at least $10^{5}$, so $N \geq 317$. If $N$ were 317 or 318 , the last digit of $N^{2}$ would not match the first digit of $N^{2}$, which contradicts the condition. However, $N=319$ will work, since the first and last digit of $N^{2}$ are both 1.
+$T_{2}$. Let $X=\left\lfloor T_{1} / 8\right\rfloor, Y=T_{3}-1, Z=T_{4}-2$. A point $P$ lies inside the triangle $A B C$ such that $P A=$ $X, P B=Y, P C=Z$. Find the largest possible area of the triangle.
+Answer: 1344
+$X=39, Y=33, Z=25$. Fix some position for $P, A$, and $B$, and we shall find the optimal position for $C$. Letting $\overline{A B}$ be the base of the triangle, we wish to maximize the height. The legal positions for $C$ are a subset of the circle with center $P$ and radius $P C$, so the height is maximized when $\overline{P C}$ is orthogonal to $\overline{A B}$. Symmetrically, we deduce that $P$ is the orthocenter of $A B C$ when the area is maximized (moreover, $P$ must be inside the triangle). If ray $B P$ intersects $A C$ at $E$, then since $A E B$ is similar to $P E C$, we have
+
+$$
+\frac{\sqrt{39^{2}-x^{2}}}{33+x}=\frac{\sqrt{25^{2}-x^{2}}}{x} \Rightarrow x^{2}(x+33)^{2}=\left(39^{2}-x^{2}\right)\left(25^{2}-x^{2}\right) \Rightarrow 66 x^{3}+3235 x^{2}-950625=0
+$$
+
+The LHS factors to $(x-15)\left(66 x^{2}+4225 x+63375\right)$, meaning that $x=15$ is the only positive solution, giving $A E=36, B E=20$, and therefore the maximum area of triangle $A B C$ is $(33+15)(36+20) / 2=$ 1344.
+$T_{3}$. How many ways can one tile a $2 \times 8$ board with $1 \times 1$ and $2 \times 2$ tiles? Rotations and reflections of the same configuration are considered distinct.
+Answer: 34
+Let $f(n)$ denote the number of ways to fill a $2 \times n$ board. One can fill the leftmost column with two $1 \times 1$ tiles, leaving $f(n-1)$ ways, or one can fill the leftmost two columns with one $2 \times 2$ tile, leaving $f(n-2)$ ways. Therefore, $f(n)=f(n-1)+f(n-2)$. One can also directly verify that $f(0)=f(1)=1$. Therefore, $f(n)=F_{n+1}$, where $F_{n}$ is the $n^{\text {th }}$ Fibonacci number. Easy calculation shows that the desired quantity is $f(8)=F_{9}=34$.
+$T_{4}$. Let $S=T_{5}$. Given real numbers $a, b, c$ such that $a^{2}+b^{2}+c^{2}+(a+b+c)^{2}=S$, find the maximum possible value of $(a+b)(b+c)(c+a)$.
+
+Answer: 27
+Notice that $S=27=a^{2}+b^{2}+c^{2}+(a+b+c)^{2}=(a+b)^{2}+(b+c)^{2}+(c+a)^{2}$. By AM-GM, $\frac{S}{3} \geq((a+b)(b+c)(c+a))^{2 / 3}$ with equality if and only if $a+b=b+c=c+a$, i.e. $a=b=c$. Thus, the maximum possible value is $\left(\frac{S}{3}\right)^{3 / 2}=27$, achieved at $a=b=c=\frac{3}{2}$.
+$T_{5}$. A regular tetrahedron has volume 8. What is the volume of the set of all the points in the space (not necessarily inside the tetrahedron) that are closer to the center of the tetrahedron than any of the four vertices?
+Answer: 27
+Let $h$ denote the height of the tetrahedron. The center of the tetrahedron is a distance $\frac{h}{4}$ from each face. Therefore, the perpendicular bisector plane of the segment connecting the center to a vertex lies a distance $\frac{3}{8} h$ away from both the vertex and the center. Symmetrical considerations with the other three vertices will thus show that the desired region is also a regular tetrahedron, with the center of the original tetrahedron a distance $\frac{3}{8} h$ away from each face. Based on the distance from the center to a face, one can see that the scale factor of this tetrahedron is $\frac{3 h}{8}: \frac{h}{4}=3: 2$ relative to the original tetrahedron, so its volume is $8 \cdot\left(\frac{3}{2}\right)^{3}=27$.
+33. [25] Determine the value of $H_{4}$.
+
+Proposed by: Yuan Yao
+Answer: 24
+34. [25] Determine the value of $M_{8}$.
+
+Proposed by: Yuan Yao
+Answer: 1156
+35. [25] Determine the value of $M_{9}$.
+
+Proposed by: Yuan Yao
+Answer: 3743
+36. [25] Determine the value of $T_{2}$.
+
+Proposed by: Yuan Yao
+Answer: 1344
+
diff --git a/HarvardMIT/md/en-222-2019-feb-team-solutions.md b/HarvardMIT/md/en-222-2019-feb-team-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..38257e60cf5e60c2d25d3baa78f0c681276c93c5
--- /dev/null
+++ b/HarvardMIT/md/en-222-2019-feb-team-solutions.md
@@ -0,0 +1,289 @@
+# HMMT February 2019
February 16, 2019
Team Round
+
+1. [20] Let $A B C D$ be a parallelogram. Points $X$ and $Y$ lie on segments $A B$ and $A D$ respectively, and $A C$ intersects $X Y$ at point $Z$. Prove that
+
+$$
+\frac{A B}{A X}+\frac{A D}{A Y}=\frac{A C}{A Z}
+$$
+
+Proposed by: Yuan Yao
+Solution 1. (Similar Triangles)
+Let $X^{\prime}$ and $Y^{\prime}$ lie on segments $A B$ and $A D$ respectively such that $Z X^{\prime} \| A D$ and $Z Y^{\prime} \| A B$. We note that triangles $A X Y$ and $Y^{\prime} Y Z$ are similar, and that triangles $A Y^{\prime} Z$ and $A D C$ are similar. Thus, we have
+
+$$
+\frac{A C}{A Z}=\frac{A D}{A Y^{\prime}} \text { and } \frac{A Y^{\prime}}{A Y}=\frac{X Z}{X Y}
+$$
+
+This means that
+
+$$
+\frac{A D}{A Y}=\frac{A D}{A Y^{\prime}} \cdot \frac{A Y^{\prime}}{A Y}=\frac{X Z}{X Y} \cdot \frac{A C}{A Z}
+$$
+
+and similarly,
+
+$$
+\frac{A B}{A X}=\frac{Z Y}{X Y} \cdot \frac{A C}{A Z}
+$$
+
+Therefore we have
+
+$$
+\frac{A B}{A X}+\frac{A D}{A Y}=\left(\frac{X Z}{X Y}+\frac{Z Y}{X Y}\right) \cdot \frac{A C}{A Z}=\frac{A C}{A Z}
+$$
+
+as desired.
+Solution 2. (Affine Transformations)
+We recall that affine transformations preserve both parallel lines and ratios between distances of collinear points. It thus suffices to show the desired result when $A B C D$ is a square. This can be done in a variety of ways. For instance, a coordinate bash can be applied by setting $A$ to be the origin. Let the length of the square be 1 and set $X$ and $Y$ as $(a, 0)$ and $(0, b)$ respectively, so the line $X Y$ has equation $b x+a y=a b$. Then, we note that $Z$ is the point $\left(\frac{a b}{a+b}, \frac{a b}{a+b}\right)$, so
+
+$$
+\frac{A B}{A X}+\frac{A D}{A Y}=\frac{1}{a}+\frac{1}{b}=\frac{a+b}{a b}=\frac{A C}{A Z}
+$$
+
+2. [20] Let $\mathbb{N}=\{1,2,3, \ldots\}$ be the set of all positive integers, and let $f$ be a bijection from $\mathbb{N}$ to $\mathbb{N}$. Must there exist some positive integer $n$ such that $(f(1), f(2), \ldots, f(n))$ is a permutation of $(1,2, \ldots, n)$ ?
+Proposed by: Michael Tang
+Answer: No
+Consider the bijection $f$ defined by
+
+$$
+(f(1), f(2), f(3), f(4), \ldots)=(2,4,6,1,8,3,10,5,12, \ldots)
+$$
+
+which alternates between even and odd numbers after the second entry. (More formally, we define $f(n)=2 n$ for $n=1,2, f(n)=n+3$ for odd $n \geq 3$ and $f(n)=n-3$ for even $n \geq 4$.) No such $n$ can exist for this $f$ as the largest number among $f(1), f(2), \ldots, f(n)$ is more than $n$ for all $n$ : for $k \geq 2$, the maximum of the first $2 k-1$ or $2 k$ values is achieved by $f(2 k-1)=2 k+2$. (Checking $n=1$ and $n=2$ is trivial.)
+3. [25] For any angle $0<\theta<\pi / 2$, show that
+
+$$
+0<\sin \theta+\cos \theta+\tan \theta+\cot \theta-\sec \theta-\csc \theta<1
+$$
+
+## Proposed by: Yuan Yao
+
+We use the following geometric construction, which follows from the geometric definition of the trigonometric functions: Let $Z$ be a point on the unit circle in the coordinate plane with origin $O$. Let $X_{1}, Y_{1}$ be the projections of $Z$ onto the $x$ - and $y$-axis respectively, and let $X_{2}, Y_{2}$ lie on $x$ - and $y$-axis respectively such that $X_{2} Y_{2}$ is tangent to the unit circle at $Z$. Then we have
+
+$$
+O Z=X_{1} Y_{1}=1, X_{1} Z=\sin \theta, Y_{1} Z=\cos \theta, X_{2} Z=\tan \theta, Y_{2} Z=\cot \theta, O X_{2}=\sec \theta, O Y_{2}=\csc \theta
+$$
+
+It then suffices to show that $0
November 9, 2019
Guts Round
+
+
Guts Round}
+
+1. [5] A polynomial $P$ with integer coefficients is called tricky if it has 4 as a root.
+
+A polynomial is called teeny if it has degree at most 1 and integer coefficients between -7 and 7 , inclusive.
+How many nonzero tricky teeny polynomials are there?
+Proposed by: Carl Schildkraut
+Answer: 2
+If a degree 0 polynomial has 4 as a root, then it must be the constant zero polynomial. Thus, we will only consider polynomials of degree 1 .
+If $P$ has degree 1, integer coefficients, and 4 as a root, then it must be of the form $P(x)=a(x-4)=$ $a x-4 a$ for some nonzero integer $a$. Since all integer coefficients are between -7 and 7 , inclusive, we require $-7 \leq 4 a \leq 7$, which gives us $a=-1,1$. Note that for both values, the coefficient of $x$ is also between -7 and 7 , so there are 2 tricky teeny polynomials.
+2. [5] You are trying to cross a 6 foot wide river. You can jump at most 4 feet, but you have one stone you can throw into the river; after it is placed, you may jump to that stone and, if possible, from there to the other side of the river. However, you are not very accurate and the stone ends up landing uniformly at random in the river. What is the probability that you can get across?
+Proposed by: Carl Schildkraut and Milan Haiman
+Answer: $\frac{1}{3}$
+To be able to cross, the stone must land between 2 and 4 feet from the river bank you are standing on. Therefore the probability is $\frac{2}{6}=\frac{1}{3}$.
+3. [5] For how many positive integers $a$ does the polynomial
+
+$$
+x^{2}-a x+a
+$$
+
+have an integer root?
+Proposed by: Krit Boonsiriseth
+Answer: 1
+Let $r, s$ be the roots of $x^{2}-a x+a=0$. By Vieta's, we have $r+s=r s=a$. Note that if one root is an integer, then both roots must be integers, as they sum to an integer $a$. Then,
+
+$$
+r s-(r+s)+1=1 \Longrightarrow(r-1)(s-1)=1
+$$
+
+Because we require $r, s$ to be both integers, we have $r-1=s-1= \pm 1$, which yields $r=s=0,2$. If $r=0$ or $s=0$, then $a=0$, but we want $a$ to be a positive integer. Therefore, our only possibility is when $r=s=2$, which yields $a=4$, so there is exactly 1 value of $a$ (namely, $a=4$ ) such that $x^{2}-a x-a$ has an integer root.
+4. [6] In 2019, a team, including professor Andrew Sutherland of MIT, found three cubes of integers which sum to 42 :
+
+$$
+42=\left(-8053873881207597 \_\right)^{3}+(80435758145817515)^{3}+(12602123297335631)^{3}
+$$
+
+One of the digits, labeled by an underscore, is missing. What is that digit?
+Proposed by: Andrew Gu
+Answer: 4
+Let the missing digit be $x$. Then, taking the equation modulo 10 , we see that $2 \equiv-x^{3}+5^{3}+1^{3}$. This simplifies to $x^{3} \equiv 4(\bmod 10)$, which gives a unique solution of $x=4$.
+5. [6] A point $P$ is chosen uniformly at random inside a square of side length 2 . If $P_{1}, P_{2}, P_{3}$, and $P_{4}$ are the reflections of $P$ over each of the four sides of the square, find the expected value of the area of quadrilateral $P_{1} P_{2} P_{3} P_{4}$.
+Proposed by: Carl Schildkraut
+Answer: 8
+Let $A B C D$ denote the square defined in the problem. We see that if $P_{1}$ is the reflection of $P$ over $\overline{A B}$, then the area of $P_{1} A B$ is the same as the area of $P A B$. Furthermore, if $P_{4}$ is the reflection of $P$ over $\overline{D A}, P_{1}, A$, and $P_{4}$ are collinear, as $A$ is the midpoint of $\overline{P_{1} P_{4}}$. Repeating this argument for the other points gives us that the desired area is
+$\left[P_{1} A B\right]+\left[P_{2} B C\right]+\left[P_{3} C D\right]+\left[P_{4} D A\right]+[A B C D]=[P A B]+[P B C]+[P C D]+[P D A]+[A B C D]=2[A B C D]=8$.
+6. [6] Compute the sum of all positive integers $n<2048$ such that $n$ has an even number of 1 's in its binary representation.
+Proposed by: Milan Haiman
+Answer: 1048064
+Note that the positive integers less than 2047 are those with at most 11 binary digits. Consider the contribution from any one of those digits. If we set that digit to 1 , then the remaining 10 digits can be set in $2^{9}=512$ ways so that the number of 1 's is even. Therefore the answer is
+
+$$
+512\left(2^{0}+\cdots+2^{10}\right)=512 \cdot 2047=1048064
+$$
+
+7. [7] Let $S$ be the set of all nondegenerate triangles formed from the vertices of a regular octagon with side length 1. Find the ratio of the largest area of any triangle in $S$ to the smallest area of any triangle in $S$.
+Proposed by: Carl Schildkraut
+Answer: $3+2 \sqrt{2}$
+By a smoothing argument, the largest triangle is that where the sides span 3, 3, and 2 sides of the octagon respectively (i.e. it has angles $45^{\circ}, 67.5^{\circ}$, and $67.5^{\circ}$ ), and the smallest triangle is that formed by three adjacent vertices of the octagon. Scaling so that the circumradius of the octagon is 1 , our answer is
+
+$$
+\frac{\sin \left(90^{\circ}\right)+2 \sin \left(135^{\circ}\right)}{2 \sin \left(45^{\circ}\right)-\sin \left(90^{\circ}\right)}=\frac{1+\sqrt{2}}{\sqrt{2}-1}=3+2 \sqrt{2}
+$$
+
+where the numerator is derived from splitting the large triangle by the circumradii, and the denominator is derived from adding the areas of the two triangles formed by the circumradii, then subtracting the area not in the small triangle.
+8. [7] There are 36 students at the Multiples Obfuscation Program, including a singleton, a pair of identical twins, a set of identical triplets, a set of identical quadruplets, and so on, up to a set of identical octuplets. Two students look the same if and only if they are from the same identical multiple. Nithya the teaching assistant encounters a random student in the morning and a random student in the afternoon (both chosen uniformly and independently), and the two look the same. What is the probability that they are actually the same person?
+Proposed by: Yuan Yao
+Answer: $\frac{3}{17}$
+Let $X$ and $Y$ be the students Nithya encounters during the day. The number of pairs $(X, Y)$ for which $X$ and $Y$ look the same is $1 \cdot 1+2 \cdot 2+\ldots+8 \cdot 8=204$, and these pairs include all the ones in which $X$ and $Y$ are identical. As $X$ and $Y$ are chosen uniformly and independently, all 204 pairs are equally likely to be chosen, thus the problem reduces to choosing one of the 36 pairs in 204, the probability for which is $\frac{3}{17}$.
+9. [7] Let $p$ be a real number between 0 and 1. Jocelin has a coin that lands heads with probability $p$ and tails with probability $1-p$; she also has a number written on a blackboard. Each minute, she flips the coin, and if it lands heads, she replaces the number $x$ on the blackboard with $3 x+1$; if it lands tails she replaces it with $x / 2$. Given that there are constants $a, b$ such that the expected value of the value written on the blackboard after $t$ minutes can be written as $a t+b$ for all positive integers $t$, compute $p$.
+Proposed by: Carl Schildkraut
+Answer: $\frac{1}{5}$
+If the blackboard has the value $x$ written on it, then the expected value of the value after one flip is
+
+$$
+f(x)=p(3 x-1)+(1-p) x / 2
+$$
+
+Because this expression is linear, we can say the same even if we only know the blackboard's initial expected value is $x$. Therefore, if the blackboard value is $x_{0}$ at time 0 , then after $t$ minutes, the expected blackboard value is $f^{t}\left(x_{0}\right)$. We are given that $x_{0}, f\left(x_{0}\right), f^{2}\left(x_{0}\right), \ldots$ is an arithmetic sequence, so for there to be a constant difference, we must have $f(x)=x+c$ for some $c$.
+This only occurs when $3 p+(1-p) / 2=1$, so $p=1 / 5$.
+10. [8] Let $A B C D$ be a square of side length 5 , and let $E$ be the midpoint of side $A B$. Let $P$ and $Q$ be the feet of perpendiculars from $B$ and $D$ to $C E$, respectively, and let $R$ be the foot of the perpendicular from $A$ to $D Q$. The segments $C E, B P, D Q$, and $A R$ partition $A B C D$ into five regions. What is the median of the areas of these five regions?
+Proposed by: Carl Schildkraut
+Answer: 5
+We have $D Q \perp C E$ and $A R \perp D Q$, so $A R \| C E$. Thus, we can show that $\triangle A R D \cong \triangle D Q C \cong \triangle C P B$, so the median of the areas of the five regions is equal to the area of one of the three triangles listed above.
+Now, note that $\triangle E B C \sim \triangle B P C$, so $\frac{B P}{B C}=\frac{E B}{E C}=\frac{1}{\sqrt{5}}$. This means that $B P=\sqrt{5}$, so $C P=2 \sqrt{5}$. Therefore, the area of $\triangle B P C$, the median area, is 5 .
+11. [8] Let $a, b, c, d$ be real numbers such that
+
+$$
+\min (20 x+19,19 x+20)=(a x+b)-|c x+d|
+$$
+
+for all real numbers $x$. Find $a b+c d$.
+Proposed by: Yuan Yao
+Answer: 380
+In general, $\min (p, q)=\frac{p+q}{2}-\left|\frac{p-q}{2}\right|$. Letting $p=20 x+19$ and $q=19 x+20$ gives $a=b=19.5$ and $c=d= \pm 0.5$. Then the answer is $19.5^{2}-0.5^{2}=19 \cdot 20=380$.
+12. [8] Four players stand at distinct vertices of a square. They each independently choose a vertex of the square (which might be the vertex they are standing on). Then, they each, at the same time, begin running in a straight line to their chosen vertex at 10 mph , stopping when they reach the vertex. If at any time two players, whether moving or not, occupy the same space (whether a vertex or a point inside the square), they collide and fall over. How many different ways are there for the players to choose vertices to go to so that none of them fall over?
+Proposed by: Carl Schildkraut
+Answer: 11
+Observe that no two players can choose the same vertex, and no two players can choose each others vertices. Thus, if two players choose their own vertices, then the remaining two also must choose their
+own vertices (because they cant choose each others vertices), thus all 4 players must choose their own vertices. There is 1 way to choose the vertices in this case.
+Name the players top left, top right, bottom left, and bottom right, based on their initial positions. Assume exactly one player (without loss of generality, say the top left) chooses their own vertex. Then, the remaining 3 players have to form a triangle (recall no two player can choose each others vertices). There are 4 ways to choose which player chooses their own vertex, and 2 ways to choose which direction the players move in the triangle, thus there are 8 ways to choose the vertices in this case.
+Lastly, assume no one chooses their own vertex. We will first prove that no player can choose the vertex across them. Assume the contrary, without loss of generality, let the top left player chooses the bottom right vertex. Then, neither of the bottom left and the top right players can choose the others vertex, because they would meet the top left player at the center of the square. As they cant choose bottom right (it is chosen by the top left player), and cant choose their own vertex (by assumption), they both have to choose the top left vertex, which is an immediate contradiction.
+Now, the top left player has to choose either the top right vertex or the bottom left. Without loss of generality, let the player choose the top right vertex. Then, the top right player has to choose the bottom right vertex (as they can neither go across nor back to top left), the bottom right player has to choose the bottom left vertex, and the bottom left player has to choose the top left vertex, and all the choices are determined by the first players choice. There are 2 ways to choose where the first player goes, thus there are 2 ways to choose the vertices in this case.
+
+In total, there are $1+8+2=11$ ways to choose the vertices.
+13. [9] In $\triangle A B C$, the incircle centered at $I$ touches sides $A B$ and $B C$ at $X$ and $Y$, respectively. Additionally, the area of quadrilateral $B X I Y$ is $\frac{2}{5}$ of the area of $A B C$. Let $p$ be the smallest possible perimeter of a $\triangle A B C$ that meets these conditions and has integer side lengths. Find the smallest possible area of such a triangle with perimeter $p$.
+Proposed by: Joey Heerens
+Answer: $2 \sqrt{5}$
+Note that $\angle B X I=\angle B Y I=90$, which means that $A B$ and $B C$ are tangent to the incircle of $A B C$ at $X$ and $Y$ respectively. So $B X=B Y=\frac{A B+B C-A C}{2}$, which means that $\frac{2}{5}=\frac{[B X I Y]}{[A B C]}=\frac{A B+B C-A C}{A B+B C+A C}$. The smallest perimeter is achieved when $A B=A C=3$ and $B C=4$. The area of this triangle $A B C$ is $2 \sqrt{5}$.
+14. [9] Compute the sum of all positive integers $n$ for which
+
+$$
+9 \sqrt{n}+4 \sqrt{n+2}-3 \sqrt{n+16}
+$$
+
+is an integer.
+Proposed by: Milan Haiman
+Answer: 18
+For the expression to be an integer at least one of $n$ and $n+2$ must be a perfect square. We also note that at most one of $n$ and $n+2$ can be a square, so exactly one of them is a square.
+Case 1: $n$ is a perfect square. By our previous observation, it must be that $4 \sqrt{n+2}=3 \sqrt{n+16} \Rightarrow$ $n=16$.
+
+Case 2: $n+2$ is a perfect square. By our previous observation, it must be that $9 \sqrt{n}=3 \sqrt{n+16} \Rightarrow$ $n=2$.
+Consequently, the answer is $16+2=18$.
+15. [9] Let $a, b, c$ be positive integers such that
+
+$$
+\frac{a}{77}+\frac{b}{91}+\frac{c}{143}=1
+$$
+
+What is the smallest possible value of $a+b+c$ ?
+Proposed by: James Lin
+Answer: 79
+We need $13 a+11 b+7 c=1001$, which implies $13(a+b+c-77)=2 b+6 c$. Then $2 b+6 c$ must be divisible by both 2 and 13 , so it is minimized at 26 (e.g. with $b=10, c=1$ ). This gives $a+b+c=79$.
+16. [10] Equilateral $\triangle A B C$ has side length 6 . Let $\omega$ be the circle through $A$ and $B$ such that $C A$ and $C B$ are both tangent to $\omega$. A point $D$ on $\omega$ satisfies $C D=4$. Let $E$ be the intersection of line $C D$ with segment $A B$. What is the length of segment $D E$ ?
+Proposed by: Benjamin Qi
+Answer: $\frac{20}{13}$
+Let $F$ be the second intersection of line $C D$ with $\omega$. By power of a point, we have $C F=9$, so $D F=5$. This means that $\frac{[A D B]}{[A F B]}=\frac{D E}{E F}=\frac{D E}{5-D E}$. Now, note that triangle $C A D$ is similar to triangle $C F A$, so $\frac{F A}{A D}=\frac{C A}{C D}=\frac{3}{2}$. Likewise, $\frac{F B}{B D}=\frac{C B}{C D}=\frac{3}{2}$. Also, note that $\angle A D B=180-\angle D A B-\angle D B A=$ $180-\angle C A B=120$, and $\angle A F B=180-\angle A D B=60$. This means that $\frac{[A D B]}{[A F B]}=\frac{A D \cdot B D \cdot \sin 120}{F A \cdot F B \cdot \sin 60}=\frac{4}{9}$. Therefore, we have that $\frac{D E}{5-D E}=\frac{4}{9}$. Solving yields $D E=\frac{20}{13}$.
+17. [10] Kelvin the frog lives in a pond with an infinite number of lily pads, numbered $0,1,2,3$, and so forth. Kelvin starts on lily pad 0 and jumps from pad to pad in the following manner: when on lily pad $i$, he will jump to lily pad $(i+k)$ with probability $\frac{1}{2^{k}}$ for $k>0$. What is the probability that Kelvin lands on lily pad 2019 at some point in his journey?
+
+Proposed by: Nikhil Reddy
+Answer: $\frac{1}{2}$
+Suppose we combine all of the lily pads with numbers greater than 2019 into one lily pad labeled $\infty$. Also, let Kelvin stop once he reaches one of these lily pads.
+Now at every leap, Kelvin has an equal chance of landing on 2019 as landing on $\infty$. Furthermore, Kelvin is guaranteed to reach 2019 or $\infty$ within 2020 leaps. Therefore the chance of landing on 2019 is the same as missing it, so our answer is just $\frac{1}{2}$.
+18. [10] The polynomial $x^{3}-3 x^{2}+1$ has three real roots $r_{1}, r_{2}$, and $r_{3}$. Compute
+
+$$
+\sqrt[3]{3 r_{1}-2}+\sqrt[3]{3 r_{2}-2}+\sqrt[3]{3 r_{3}-2}
+$$
+
+Proposed by: Milan Haiman
+Answer: 0
+Let $r$ be a root of the given polynomial. Then
+
+$$
+r^{3}-3 r^{2}+1=0 \Longrightarrow r^{3}-3 r^{2}+3 r-1=3 r-2 \Longrightarrow r-1=\sqrt[3]{3 r-2}
+$$
+
+Now by Vieta the desired value is $r_{1}+r_{2}+r_{3}-3=3-3=0$.
+19. [11] Let $A B C$ be a triangle with $A B=5, B C=8, C A=11$. The incircle $\omega$ and $A$-excircle ${ }^{1} \Gamma$ are centered at $I_{1}$ and $I_{2}$, respectively, and are tangent to $B C$ at $D_{1}$ and $D_{2}$, respectively. Find the ratio of the area of $\triangle A I_{1} D_{1}$ to the area of $\triangle A I_{2} D_{2}$.
+Proposed by: Carl Schildkraut
+Answer: $\frac{1}{9}$
+
+Let $D_{1}^{\prime}$ and $D_{2}^{\prime}$ be the points diametrically opposite $D_{1}$ and $D_{2}$ on the incircle and $A$-excircle, respectively. As $I_{x}$ is the midpoint of $D_{x}$ and $D_{x}^{\prime}$, we have
+
+$$
+\frac{\left[A I_{1} D_{1}\right]}{\left[A I_{2} D_{2}\right]}=\frac{\left[A D_{1} D_{1}^{\prime}\right]}{\left[A D_{2} D_{2}^{\prime}\right]}
+$$
+
+Now, $\triangle A D_{1} D_{1}^{\prime}$ and $\triangle A D_{2} D_{2}^{\prime}$ are homothetic with ratio $\frac{r}{r_{A}}=\frac{s-a}{s}$, where $r$ is the inradius, $r_{A}$ is the $A$-exradius, and $s$ is the semiperimeter. Our answer is thus
+
+$$
+\left(\frac{s-a}{s}\right)^{2}=\left(\frac{4}{12}\right)=\frac{1}{9}
+$$
+
+20. [11] Consider an equilateral triangle $T$ of side length 12 . Matthew cuts $T$ into $N$ smaller equilateral triangles, each of which has side length 1,3 , or 8 . Compute the minimum possible value of $N$.
+Proposed by: Matthew Cho
+Answer: 16
+Matthew can cut $T$ into 16 equilateral triangles with side length 3 . If he instead included a triangle of side 8 , then let him include $a$ triangles of side length 3 . He must include $12^{2}-8^{2}-3^{2} a=80-9 a$ triangles of side length 1 . Thus $a \leq 8$, giving that he includes at least
+
+$$
+(80-9 a)+(a)+1=81-8 a \geq 17
+$$
+
+total triangles, so 16 is minimal.
+21. [11] A positive integer $n$ is infallible if it is possible to select $n$ vertices of a regular 100-gon so that they form a convex, non-self-intersecting $n$-gon having all equal angles. Find the sum of all infallible integers $n$ between 3 and 100, inclusive.
+Proposed by: Benjamin Qi
+Answer: 262
+Suppose $A_{1} A_{2} \ldots A_{n}$ is an equiangular $n$-gon formed from the vertices of a regular 100-gon. Note that the angle $\angle A_{1} A_{2} A_{3}$ is determined only by the number of vertices of the 100 -gon between $A_{1}$ and $A_{3}$. Thus in order for $A_{1} A_{2} \ldots A_{n}$ to be equiangular, we require exactly that $A_{1}, A_{3}, \ldots$ are equally spaced and $A_{2}, A_{4}, \ldots$ are equally spaced. If $n$ is odd, then all the vertices must be equally spaced, meaning $n \mid 100$. If $n$ is even, we only need to be able to make a regular $\left(\frac{n}{2}\right)$-gon from the vertices of a 100 -gon, which we can do if $n \mid 200$. Thus the possible values of $n$ are $4,5,8,10,20,25,40,50$, and 100 , for a total of 262 .
+22. [12] Let $f(n)$ be the number of distinct digits of $n$ when written in base 10 . Compute the sum of $f(n)$ as $n$ ranges over all positive 2019-digit integers.
+Proposed by: Milan Haiman
+Answer: $9\left(10^{2019}-9^{2019}\right)$
+Write
+
+$$
+f(n)=f_{0}(n)+\cdots+f_{9}(n)
+$$
+
+where $f_{d}(n)=1$ if $n$ contains the digit $d$ and 0 otherwise. The sum of $f_{d}(n)$ over all 2019-digit positive integers $n$ is just the number of 2019-digit positive integers that contain the digit $d$. For $1 \leq d \leq 9$,
+
+$$
+\sum_{n} f_{d}(n)=9 \cdot 10^{2018}-8 \cdot 9^{2018}
+$$
+
+Also,
+
+$$
+\sum_{n} f_{0}(n)=9 \cdot 10^{2018}-9^{2019}
+$$
+
+Summing over all possible values of $d$, we compute
+
+$$
+\sum_{n} f(n)=\sum_{d=0}^{9} \sum_{n} f_{d}(n)=9\left(9 \cdot 10^{2018}-8 \cdot 9^{2018}\right)+9 \cdot 10^{2018}-9^{2019}=9\left(10^{2019}-9^{2019}\right)
+$$
+
+23. [12] For a positive integer $n$, let, $\tau(n)$ be the number of positive integer divisors of $n$. How many integers $1 \leq n \leq 50$ are there such that $\tau(\tau(n))$ is odd?
+Proposed by: Kevin Liu
+Answer: 17
+Note that $\tau(n)$ is odd if and only if $n$ is a perfect square. Thus, it suffices to find the number of integers $n$ in the given range such that $\tau(n)=k^{2}$ for some positive integer $k$.
+If $k=1$, then we obtain $n=1$ as our only solution. If $k=2$, we see that $n$ is either in the form $p q$ or $p^{3}$, where $p$ and $q$ are distinct primes. The first subcase gives $8+4+1=13$ solutions, while the second subcase gives 2 solutions. $k=3$ implies that $n$ is a perfect square, and it is easy to see that only $6^{2}=36$ works. Finally, $k \geq 4$ implies that $n$ is greater than 50 , so we've exhausted all possible cases. Our final answer is $1+13+2+1=17$.
+24. [12] Let $P$ be a point inside regular pentagon $A B C D E$ such that $\angle P A B=48^{\circ}$ and $\angle P D C=42^{\circ}$. Find $\angle B P C$, in degrees.
+Proposed by: Dylan Liu
+Answer: $84^{\circ}$
+Since a regular pentagon has interior angles $108^{\circ}$, we can compute $\angle P D E=66^{\circ}, \angle P A E=60^{\circ}$, and $\angle A P D=360^{\circ}-\angle A E D-\angle P D E-\angle P A E=126^{\circ}$. Now observe that drawing $P E$ divides quadrilateral $P A E D$ into equilateral triangle $P A E$ and isosceles triangle $P E D$, where $\angle D P E=\angle E D P=66^{\circ}$. That is, we get $P A=P E=s$, where $s$ is the side length of the pentagon.
+Now triangles $P A B$ and $P E D$ are congruent (with angles $48^{\circ}-66^{\circ}-66^{\circ}$ ), so $P D=P B$ and $\angle P D C=$ $\angle P B C=42^{\circ}$. This means that triangles $P D C$ and $P B C$ are congruent (side-angle-side), so $\angle B P C=$ $\angle D P C$.
+Finally, we compute $\angle B P C+\angle D P C=2 \angle B P C=360^{\circ}-\angle A P B-\angle E P A-\angle D P E=168^{\circ}$, meaning $\angle B P C=84^{\circ}$.
+25. [13] In acute $\triangle A B C$ with centroid $G, A B=22$ and $A C=19$. Let $E$ and $F$ be the feet of the altitudes from $B$ and $C$ to $A C$ and $A B$ respectively. Let $G^{\prime}$ be the reflection of $G$ over $B C$. If $E, F, G$, and $G^{\prime}$ lie on a circle, compute $B C$.
+Proposed by: Milan Haiman
+Answer: 13
+Note that $B, C, E, F$ lie on a circle. Moreover, since $B C$ bisects $G G^{\prime}$, the center of the circle that goes through $E, F, G, G^{\prime}$ must lie on $B C$. Therefore, $B, C, E, F, G, G^{\prime}$ lie on a circle. Specifically, the center of this circle is $M$, the midpoint of $B C$, as $M E=M F$ because $M$ is the center of the circumcircle of $B C E F$. So we have $G M=\frac{B C}{2}$, which gives $A M=\frac{3 B C}{2}$. Then, by Apollonius's theorem, we have $A B^{2}+A C^{2}=2\left(A M^{2}+B M^{2}\right)$. Thus $845=5 B C^{2}$ and $B C=13$.
+26. [13] Dan is walking down the left side of a street in New York City and must cross to the right side at one of 10 crosswalks he will pass. Each time he arrives at a crosswalk, however, he must wait $t$ seconds, where $t$ is selected uniformly at random from the real interval $[0,60]$ ( $t$ can be different at different crosswalks). Because the wait time is conveniently displayed on the signal across the street, Dan employs the following strategy: if the wait time when he arrives at the crosswalk is no more than $k$ seconds, he crosses. Otherwise, he immediately moves on to the next crosswalk. If he arrives at the last crosswalk and has not crossed yet, then he crosses regardless of the wait time. Find the value of $k$ which minimizes his expected wait time.
+
+Answer: $60\left(1-\left(\frac{1}{10}\right)^{\frac{1}{9}}\right)$
+With probability $\left(1-\frac{k}{60}\right)^{9}$, Dan reaches the last crosswalk without crossing at any previous site, in which case the expected value of his wait time is 30 seconds. Otherwise, with probability $1-\left(1-\frac{k}{60}\right)^{9}$, Dan crosses at an earlier crosswalk, in which case the expected value of his wait time is $\frac{k}{2}$. We want to find the $k$ that minimizes
+
+$$
+30\left(1-\frac{k}{60}\right)^{9}+\frac{k}{2}\left(1-\left(1-\frac{k}{60}\right)^{9}\right)=30-\left(30-\frac{k}{2}\right)\left(1-\left(1-\frac{k}{60}\right)^{9}\right)
+$$
+
+Letting $a=1-\frac{k}{60}$, we can use weighted AM-GM:
+
+$$
+9^{\frac{1}{10}}\left(a\left(1-a^{9}\right)\right)^{\frac{9}{10}}=\left(9 a^{9}\right)^{\frac{1}{10}}\left(1-a^{9}\right)^{\frac{9}{10}} \leq \frac{9}{10}
+$$
+
+where equality occurs when $9 a^{9}=1-a^{9}$, or $a=\left(\frac{1}{10}\right)^{\frac{1}{9}}$, meaning that $k=60\left(1-\left(\frac{1}{10}\right)^{\frac{1}{9}}\right)$. Because our original expression can be written as
+
+$$
+30-30 a\left(1-a^{9}\right),
+$$
+
+the minimum occurs at the same value, $k=60\left(1-\left(\frac{1}{10}\right)^{\frac{1}{9}}\right)$.
+27. [13] For a given positive integer $n$, we define $\varphi(n)$ to be the number of positive integers less than or equal to $n$ which share no common prime factors with $n$. Find all positive integers $n$ for which
+
+$$
+\varphi(2019 n)=\varphi\left(n^{2}\right)
+$$
+
+Proposed by: Carl Schildkraut
+Answer: 1346, 2016, 2019
+Let $p_{1}, p_{2}, \ldots, p_{k}$ be the prime divisors of $n$. Then it is known that $\varphi(n)=n \cdot \frac{p_{1}-1}{p_{1}} \ldots \frac{p_{k}-1}{p_{k}}$. As $n^{2}$ and $n$ has the same set of prime divisors, it also holds that $\varphi\left(n^{2}\right)=n^{2} \cdot \frac{p_{1}-1}{p_{1}} \ldots \frac{p_{k}-1}{p_{k}}$. We will examine the equality in four cases.
+
+- $\operatorname{gcd}(n, 2019)=1$ In this case, $2019 \cdot n$ has also 3 and 673 as prime divisors, thus $\varphi(2019 \cdot n)=$ $2019 \cdot n \cdot \frac{p_{1}-1}{p_{1}} \ldots \frac{p_{k}-1}{p_{k}} \cdot \frac{2}{3} \cdot \frac{672}{673}$, and the equality implies $n=1342$, however $\operatorname{gcd}(1342,3) \neq 1$, contradiction. Thus, there is no answer in this case.
+- $\operatorname{gcd}(n, 2019)=3$ In this case, $2019 \cdot n$ has also 673 as a prime divisor, thus $\varphi(2019 \cdot n)=$ $2019 \cdot n \cdot \frac{p_{1}-1}{p_{1}} \ldots \frac{p_{k}-1}{p_{k}} \cdot \frac{672}{673}$, and the equality implies $n=2016$, which satisfies the equation. Thus, the only answer in this case is $n=2016$.
+- $\operatorname{gcd}(n, 2019)=673$ In this case, $2019 \cdot n$ has also 3 as a prime divisor, thus $\varphi(2019 \cdot n)=$ $2019 \cdot n \cdot \frac{p_{1}-1}{p_{1}} \ldots \frac{p_{k}-1}{p_{k}} \cdot \frac{2}{3}$, and the equality implies $n=1346$, which satisfies the equation. Thus, the only answer in this case is $n=1346$.
+- $\operatorname{gcd}(n, 2019)=2019$ In this case, $2019 \cdot n$ has the same set of prime divisors, thus $\varphi(2019 \cdot n)=$ $2019 \cdot n \cdot \frac{p_{1}-1}{p_{1}} \ldots \frac{p_{k}-1}{p_{k}}$, and the equality implies $n=2019$, which satisfies the equation. Thus, the only answer in this case is $n=2019$.
+
+Thus, all the answers are $n=1346,2016,2019$.
+28. [15] A palindrome is a string that does not change when its characters are written in reverse order. Let $S$ be a 40 -digit string consisting only of 0 's and 1 's, chosen uniformly at random out of all such strings. Let $E$ be the expected number of nonempty contiguous substrings of $S$ which are palindromes. Compute the value of $\lfloor E\rfloor$.
+
+## Proposed by: Benjamin Qi
+
+Answer: 113
+Note that $S$ has $41-n$ contiguous substrings of length $n$, so we see that the expected number of palindromic substrings of length $n$ is just $(41-n) \cdot 2^{-\lfloor n / 2\rfloor}$. By linearity of expectation, $E$ is just the sum of this over all $n$ from 1 to 40 . However, it is much easier to just compute
+
+$$
+\sum_{n=1}^{\infty}(41-n) \cdot 2^{-\lfloor n / 2\rfloor}
+$$
+
+The only difference here is that we have added some insignificant negative terms in the cases where $n>41$, so $E$ is in fact slightly greater than this value (in fact, the difference between $E$ and this sum is $\frac{7}{1048576}$ ). To make our infinite sum easier to compute, we can remove the floor function by pairing up consecutive terms. Then our sum becomes
+
+$$
+40+\sum_{n=1}^{\infty} \frac{81-4 n}{2^{n}}
+$$
+
+which is just $40+81-8=113$. $E$ is only slightly larger than this value, so our final answer is $\lfloor E\rfloor=113$.
+29. [15] In isosceles $\triangle A B C, A B=A C$ and $P$ is a point on side $B C$. If $\angle B A P=2 \angle C A P, B P=\sqrt{3}$, and $C P=1$, compute $A P$.
+Proposed by: Milan Haiman
+Answer: $\sqrt{\sqrt{2}}$
+Let $\angle C A P=\alpha$, By the Law of Sines, $\frac{\sqrt{3}}{\sin 2 \alpha}=\frac{1}{\sin \alpha}$ which rearranges to $\cos \alpha=\frac{\sqrt{3}}{2} \Rightarrow \alpha=\frac{\pi}{6}$. This implies that $\angle B A C=\frac{\pi}{2}$. By the Pythagorean Theorem, $2 A B^{2}=(\sqrt{3}+1)^{2}$, so $A B^{2}=2+\sqrt{3}$. Applying Stewart's Theorem, it follows that $A P^{2}=\frac{(\sqrt{3}+1)(2+\sqrt{3})}{\sqrt{3}+1}-\sqrt{3} \Rightarrow A P=\sqrt{2}$.
+30. [15] A function $f: \mathbb{Z} \rightarrow \mathbb{Z}$ satisfies: $f(0)=0$ and
+
+$$
+\left|f\left((n+1) 2^{k}\right)-f\left(n 2^{k}\right)\right| \leq 1
+$$
+
+for all integers $k \geq 0$ and $n$. What is the maximum possible value of $f(2019)$ ?
+Proposed by: Krit Boonsiriseth
+Answer: 4
+Consider a graph on $\mathbb{Z}$ with an edge between $(n+1) 2^{k}$ and $n 2^{k}$ for all integers $k \geq 0$ and $n$. Each vertex $m$ is given the value $f(m)$. The inequality $\left|f\left((n+1) 2^{k}\right)-f\left(n 2^{k}\right)\right| \leq 1$ means that any two adjacent vertices of this graph must have values which differ by at most 1 . Then it follows that for all $m$,
+
+$$
+f(m) \leq \text { number of edges in shortest path from } 0 \text { to } m
+$$
+
+because if we follow a path from 0 to $m$, along each edge the value increases by at most 1 . Conversely, if we define $f(m)$ to be the number of edges in the shortest path between 0 and $m$, then this is a valid function because for any two adjacent vertices, the lengths of their respective shortest paths to 0 differ by at most 1 . Hence it suffices to compute the distance from 0 to 2019 in the graph.
+There exists a path with 4 edges, given by
+
+$$
+0 \rightarrow 2048 \rightarrow 2016 \rightarrow 2018 \rightarrow 2019
+$$
+
+Suppose there existed a path with three edges. In each step, the number changes by a power of 2 , so we have $2019= \pm 2^{k_{1}} \pm 2^{k_{2}} \pm 2^{k_{3}}$ for some nonnegative integers $k_{1}, k_{2}, k_{3}$ and choice of signs. Since 2019 is odd, we must have $2^{0}$ somewhere. Then we have $\pm 2^{k_{1}} \pm 2^{k_{2}} \in\{2018,2020\}$. Without loss of
+generality assume that $k_{1} \geq k_{2}$. Then we can write this as $\pm 2^{k_{2}}\left(2^{k_{1} k_{2}} \pm 1\right) \in\{2018,2020\}$. It is easy to check that $k_{1}=k_{2}$ is impossible, so the factorization $2^{k_{2}}\left(2^{k_{1} k_{2}} \pm 1\right)$ is a product of a power of two and an odd number. Now compute $2018=2 \times 1009$ and $2020=4 \times 505$. Neither of the odd parts are of the form $2^{k_{1}-k_{2}} \pm 1$, so there is no path of three steps.
+We conclude that the maximum value of $f(2019)$ is 4 .
+31. [17] James is standing at the point $(0,1)$ on the coordinate plane and wants to eat a hamburger. For each integer $n \geq 0$, the point $(n, 0)$ has a hamburger with $n$ patties. There is also a wall at $y=2.1$ which James cannot cross. In each move, James can go either up, right, or down 1 unit as long as he does not cross the wall or visit a point he has already visited.
+Every second, James chooses a valid move uniformly at random, until he reaches a point with a hamburger. Then he eats the hamburger and stops moving. Find the expected number of patties that James eats on his burger.
+Proposed by: Joey Heerens
+Answer: $\frac{7}{3}$
+Note that we desire to compute the number of times James moves to the right before moving down to the line $y=0$. Note also that we can describe James's current state based on whether his $y$-coordinate is 0 or 1 and whether or not the other vertically adjacent point has been visited. Let $E(1, N)$ be the expected number of times James will go right before stopping if he starts at a point with $y$-coordinate 1 and the other available point with the same $x$-coordinate has not been visited. Define $E(1, Y), E(2, N)$, and $E(2, Y)$ similarly. Then we can construct equations relating the four variables:
+
+$$
+E(1, N)=\frac{1}{3} E(2, Y)+\frac{1}{3}(E(1, N)+1)
+$$
+
+as James can either go up, right, or down with probability $1 / 3$ each if he starts in the state $(1, N)$. Similarly, we have
+
+$$
+E(2, N)=\frac{1}{2} E(1, Y)+\frac{1}{2}(E(2, N)+1), E(1, Y)=\frac{1}{2}(E(1, N)+1)
+$$
+
+and $E(2, Y)=E(2, N)+1$. Solving these equations, we get $E(1, N)=\frac{7}{3}$, which is our answer, as James starts in that state having gone left 0 times.
+32. [17] A sequence of real numbers $a_{0}, a_{1}, \ldots, a_{9}$ with $a_{0}=0, a_{1}=1$, and $a_{2}>0$ satisfies
+
+$$
+a_{n+2} a_{n} a_{n-1}=a_{n+2}+a_{n}+a_{n-1}
+$$
+
+for all $1 \leq n \leq 7$, but cannot be extended to $a_{10}$. In other words, no values of $a_{10} \in \mathbb{R}$ satisfy
+
+$$
+a_{10} a_{8} a_{7}=a_{10}+a_{8}+a_{7}
+$$
+
+Compute the smallest possible value of $a_{2}$.
+Proposed by: Dylan Liu
+Answer: $\sqrt{2}-1$
+Say $a_{2}=a$. Then using the recursion equation, we have $a_{3}=-1, a_{4}=\frac{a+1}{a-1}, a_{5}=\frac{-a+1}{a+1}, a_{6}=-\frac{1}{a}$, $a_{7}=-\frac{2 a}{a^{2}-1}$, and $a_{8}=1$.
+Now we have $a_{10} a_{8} a_{7}=a_{10}+a_{8}+a_{7}$. No value of $a_{10}$ can satisfy this equation iff $a_{8} a_{7}=1$ and $a_{8}+a_{7} \neq 0$. Since $a_{8}$ is 1 , we want $1=a_{7}=-\frac{2 a}{a^{2}-1}$, which gives $a^{2}+2 a-1=0$. The only positive root of this equation is $\sqrt{2}-1$.
+This problem can also be solved by a tangent substitution. Write $a_{n}=\tan \alpha_{n}$. The given condition becomes
+
+$$
+\alpha_{n+2}+\alpha_{n}+\alpha_{n-1}=0
+$$
+
+We are given $\alpha_{0}=0, \alpha_{1}=\pi / 4$, and $\alpha_{2} \in(0, \pi / 2)$. Using this, we can recursively compute $\alpha_{3}, \alpha_{4}, \ldots$ in terms of $\alpha_{2}$ until we get to $\alpha_{10}=\frac{3 \pi}{4}-2 \alpha_{2}$. For $a_{10}$ not to exist, we need $\alpha_{10} \equiv \pi / 2 \bmod \pi$. The only possible value of $\alpha_{2} \in(0, \pi / 2)$ is $\alpha_{2}=\pi / 8$, which gives $a_{2}=\tan \pi / 8=\sqrt{2}-1$.
+33. [17] A circle $\Gamma$ with center $O$ has radius 1. Consider pairs $(A, B)$ of points so that $A$ is inside the circle and $B$ is on its boundary. The circumcircle $\Omega$ of $O A B$ intersects $\Gamma$ again at $C \neq B$, and line $A C$ intersects $\Gamma$ again at $X \neq C$. The pair $(A, B)$ is called techy if line $O X$ is tangent to $\Omega$. Find the area of the region of points $A$ so that there exists a $B$ for which $(A, B)$ is techy.
+Proposed by: Carl Schildkraut and Milan Haiman
+Answer: $\frac{3 \pi}{4}$
+We claim that $(A, B)$ is techy if and only if $O A=A B$.
+Note that $O X$ is tangent to the circle $(O B C)$ if and only if $O X$ is perpendicular to the angle bisector of $\angle B O C$, since $O B=O C$. Thus $(A, B)$ is techy if and only if $O X$ is parallel to $B C$. Now since $O C=O X$,
+
+$$
+O X \| B C \Longleftrightarrow \angle B C A=\angle O X A \Longleftrightarrow \angle B C A=\angle A C O \Longleftrightarrow O A=A B
+$$
+
+From the claim, the desired region of points $A$ is an annulus between the circles centered at $O$ with radii $\frac{1}{2}$ and 1 . So the answer is $\frac{3 \pi}{4}$.
+34. [20] A polynomial $P$ with integer coefficients is called tricky if it has 4 as a root.
+
+A polynomial is called $k$-tiny if it has degree at most 7 and integer coefficients between $-k$ and $k$, inclusive.
+A polynomial is called nearly tricky if it is the sum of a tricky polynomial and a 1-tiny polynomial.
+Let $N$ be the number of nearly tricky 7 -tiny polynomials. Estimate $N$.
+An estimate of $E$ will earn $\left\lfloor 20 \min \left(\frac{N}{E}, \frac{E}{N}\right)^{4}\right\rfloor$ points.
+Proposed by: Carl Schildkraut
+Answer: 64912347
+A tricky 7-tiny polynomial takes the form
+
+$$
+\left(c_{6} x^{6}+\ldots+c_{1} x+c_{0}\right)(x-4)
+$$
+
+For each fixed value of $k, c_{k}-4 c_{k+1}$ should lie in $[-7,7]$, so if we fix $c_{k}$, there are around $15 / 4$ ways of choosing $c_{k+1}$. Therefore if we pick $c_{0}, \ldots, c_{6}$ in this order, there should be around $(15 / 4)^{7}$ tricky 7-tiny polynomials.
+A 1-tiny polynomial takes the form $\varepsilon_{6} x^{7}+\cdots+\varepsilon_{1} x+\varepsilon_{0}$ with $\varepsilon_{i} \in\{-1,0,+1\}$, so there are $3^{8} 1$-tiny polynomials.
+A nearly tricky 7 -tiny polynomial $P$ takes the form $Q+T$ where $Q$ is roughly a tricky 7 -tiny polynomial, and $T$ is 1-tiny. Furthermore, there is a unique decomposition $Q+T$ because $T(4)=P(4)$ and each integer $n$ can be written in the form $\sum \varepsilon_{k} 4^{k}$ in at most one way. Therefore the number of nearly tricky 7 -tiny is around $(15 / 4)^{7} \cdot 3^{8} \approx 68420920$, which is worth 16 points.
+The exact answer can be found by setting up recurrences. Let $t(d, \ell)$ be the number of polynomials of degree at most $i$ of the form
+
+$$
+\left(\ell x^{d-1}+c_{d-2} x^{d-2}+\cdots+c_{0}\right)(x-4)+\left(\varepsilon_{d-1} x^{d-1}+\cdots+\varepsilon_{1} x+\varepsilon_{0}\right)
+$$
+
+which has integer coefficients between -7 and 7 except the leading term $\ell x^{d}$. It follows that $t(0,0)=$ $1, t(0, k)=0$ for all $k \neq 0$, and $t(d+1, \ell)$ can be computed as follows: for each value of $c_{d-1}$, there are
+$t\left(d, c_{d-1}\right)$ ways to pick $c_{d-2}, \ldots, c_{0}, \varepsilon_{d-1}, \ldots, \varepsilon_{0}$, and exactly $w\left(c_{d-1}-4 \ell\right)$ ways of picking $\varepsilon_{d}$, where $w(k)=\min (9-|k|, 3)$ for $|k| \leq 8$ and 0 otherwise. Therefore setting $c=c_{d-1}-4 \ell$ we have
+
+$$
+t(d+1, \ell)=\sum_{c=-8}^{8} t(d, c+4 \ell) w(c)
+$$
+
+The number of nearly tricky 7 -tiny polynomials is simply $t(8,0)$, which can be computed to be 64912347 using the following C code.
+
+```
+int w(int a){
+ if(a<-9 || a > 9) return 0;
+ else if(a == -8 || a == 8) return 1;
+ else if(a == -7 || a == 7) return 2;
+ else return 3;
+}
+int main()
+{
+ int m=8,n=7,r=4,d,l,c,c4l;
+ int mid = 2 + n/r;
+ int b = 2*mid+1;
+ long int t[500] [500];
+ for(l=0; l= 0 && c4l <= 2*mid) ? t[d][c4l]*w(c) : 0;
+ }
+ }
+ }
+ printf("%ld",t[8][mid]);
+}
+```
+
+35. [20] You are trying to cross a 400 foot wide river. You can jump at most 4 feet, but you have many stones you can throw into the river. You will stop throwing stones and cross the river once you have placed enough stones to be able to do so. You can throw straight, but you can't judge distance very well, so each stone ends up being placed uniformly at random along the width of the river. Estimate the expected number $N$ of stones you must throw before you can get across the river.
+An estimate of $E$ will earn $\left\lfloor 20 \min \left(\frac{N}{E}, \frac{E}{N}\right)^{3}\right\rfloor$ points.
+Proposed by: Carl Schildkraut and Milan Haiman
+Answer: 712.811
+If we divide the river into 1004 -foot sections, then to be able to cross we need to get at least one stone into each section. On average, this takes
+
+$$
+\frac{100}{100}+\frac{100}{99}+\cdots+\frac{100}{1} \approx 100 \ln 100
+$$
+
+stone throws (it takes $\frac{100}{100-k}$ moves on average to get a stone into a new section if $k$ sections already have a stone). So the answer is at least $100 \ln 100 \approx 450$.
+
+On the other hand, if we divide the river into 2002 -foot sections, then once we have a stone in each section we are guaranteed to be able to cross. By a similar argument, we obtain that the answer is at most $200 \ln 200 \approx 1050$.
+
+Estimates near these bounds earn about 5 to 7 points. An estimate in between can earn close to 20 points.
+To compute the answer (almost) exactly, we use the following argument.
+Scale the problem so the river is of size 1, and the jumps are of size 0.01. Suppose that after $n$ throws, the stones thrown are located at positions $0
February 15, 2020
+
+## Algebra and Number Theory
+
+1. Let $P(x)=x^{3}+x^{2}-r^{2} x-2020$ be a polynomial with roots $r, s, t$. What is $P(1)$ ?
+
+Proposed by: James Lin
+Answer: -4038
+Solution 1: Plugging in $x=r$ gives $r^{2}=2020$. This means $P(1)=2-r^{2}-2020=-4038$.
+Solution 2: Vieta's formulas give the following equations:
+
+$$
+\begin{aligned}
+r+s+t & =-1 \\
+r s+s t+t r & =-r^{2} \\
+r s t & =2020 .
+\end{aligned}
+$$
+
+The second equation is $(r+t)(r+s)=0$. Without loss of generality, let $r+t=0$. Then $s=r+s+t=-1$. Finally $r^{2}=r s t=2020$, so $P(1)=-4038$.
+2. Find the unique pair of positive integers $(a, b)$ with $aa^{2}$ such that
+
+$$
+\log _{a} \log _{a} \log _{a} x=\log _{a^{2}} \log _{a^{2}} \log _{a^{2}} x
+$$
+
+Proposed by: James Lin
+Answer: $2^{32}$
+Solution: Let $y=\log _{a} x$ so $\log _{a} \log _{a} y=\log _{a^{2}} \log _{a^{2}} \frac{1}{2} y$. Setting $z=\log _{a} y$, we find $\log _{a} z=$ $\log _{a^{2}}\left(\frac{1}{2} z-\frac{1}{16}\right)$, or $z^{2}-\frac{1}{2} z+\frac{1}{16}=0$. Thus, we have $z=\frac{1}{4}$, so we can backsolve to get $y=4$ and $x=2^{32}$.
+4. For positive integers $n$ and $k$, let $\mho(n, k)$ be the number of distinct prime divisors of $n$ that are at least $k$. For example, $\mho(90,3)=2$, since the only prime factors of 90 that are at least 3 are 3 and 5 . Find the closest integer to
+
+$$
+\sum_{n=1}^{\infty} \sum_{k=1}^{\infty} \frac{\mho(n, k)}{3^{n+k-7}}
+$$
+
+Proposed by: Daniel Zhu
+
+## Answer: 167
+
+Solution: A prime $p$ is counted in $\mho(n, k)$ if $p \mid n$ and $k \leq p$. Thus, for a given prime $p$, the total contribution from $p$ in the sum is
+
+$$
+3^{7} \sum_{m=1}^{\infty} \sum_{k=1}^{p} \frac{1}{3^{p m+k}}=3^{7} \sum_{i \geq p+1} \frac{1}{3^{i}}=\frac{3^{7-p}}{2} .
+$$
+
+Therefore, if we consider $p \in\{2,3,5,7, \ldots\}$ we get
+
+$$
+\sum_{n=1}^{\infty} \sum_{k=1}^{\infty} \frac{\mho(n, k)}{3^{n+k-7}}=\frac{3^{5}}{2}+\frac{3^{4}}{2}+\frac{3^{2}}{2}+\frac{3^{0}}{2}+\varepsilon=167+\varepsilon
+$$
+
+where $\varepsilon<\sum_{i=11}^{\infty} \frac{3^{7-i}}{2}=\frac{1}{108} \ll \frac{1}{2}$. The closest integer to the sum is 167 .
+5. A positive integer $N$ is piquant if there exists a positive integer $m$ such that if $n_{i}$ denotes the number of digits in $m^{i}$ (in base 10), then $n_{1}+n_{2}+\cdots+n_{10}=N$. Let $p_{M}$ denote the fraction of the first $M$ positive integers that are piquant. Find $\lim _{M \rightarrow \infty} p_{M}$.
+Proposed by: James Lin
+Answer: $\frac{32}{55}$
+Solution: For notation, let $n_{i}(m)$ denote the number of digits of $m^{i}$ and $N(m)=n_{1}(m)+n_{2}(m)+$ $\cdots+n_{10}(m)$. Observe that $n_{i}(10 m)=n_{i}(m)+i$ so $N(10 m)=N(m)+55$. We will determine, for $k \rightarrow \infty$, how many of the integers from $N\left(10^{k}\right)$ to $N\left(10^{k+1}\right)-1$, inclusive, are piquant.
+Increment $m$ by 1 from $10^{k}$ to $10^{k+1}$. The number of digits of $m^{i}$ increases by one if $m^{i}<10^{h} \leq$ $(m+1)^{i}$, or $m<10^{\frac{h}{i}} \leq m+1$ for some integer $h$. This means that, as we increment $m$ by 1 , the sum $n_{1}+n_{2}+\cdots+n_{10}$ increases when $m$ "jumps over" $10^{\frac{h}{i}}$ for $i \leq 10$. Furthermore, when $m$ is big enough, all "jumps" are distinguishable, i.e. there does not exist two $\frac{h_{1}}{i_{1}} \neq \frac{h_{2}}{i_{2}}$ such that $m<10^{h_{1} / i_{1}}<10^{h_{2} / i_{2}} \leq m+1$.
+
+Thus, for large $k$, the number of times $n_{1}(m)+n_{2}(m)+\cdots+n_{10}(m)$ increases as $m$ increments by 1 from $10^{k}$ to $10^{k+1}$ is the number of different $10^{\frac{h}{i}}$ in the range $\left(10^{k}, 10^{k+1}\right.$ ]. If we take the fractional part of the exponent, this is equivalent to the number of distinct fractions $0<\frac{j}{i} \leq 1$ where $1 \leq i \leq 10$. The number of such fractions with denominator $i$ is $\varphi(i)$, so the total number of such fractions is $\varphi(1)+\varphi(2)+\cdots+\varphi(10)=32$.
+We have shown that for sufficiently large $k, N\left(10^{k+1}\right)-N\left(10^{k}\right)=55$ and exactly 32 integers in the range $\left[N\left(10^{k}\right), N\left(10^{k+1}\right)\right)$ are piquant. This implies that $\lim _{M \rightarrow \infty} p_{M}=\frac{32}{55}$.
+6. A polynomial $P(x)$ is a base-n polynomial if it is of the form $a_{d} x^{d}+a_{d-1} x^{d-1}+\cdots+a_{1} x+a_{0}$, where each $a_{i}$ is an integer between 0 and $n-1$ inclusive and $a_{d}>0$. Find the largest positive integer $n$ such that for any real number $c$, there exists at most one base- $n$ polynomial $P(x)$ for which $P(\sqrt{2}+\sqrt{3})=c$.
+Proposed by: James Lin
+
+Answer: 9
+Solution: It is equivalent to determine the largest $n$ such that we cannot find two distinct base$n$ polynomials $P_{1}$ and $P_{2}$ such that $P_{1}(\sqrt{2}+\sqrt{3})=P_{2}(\sqrt{2}+\sqrt{3})$. The difference of two base- $n$ polynomials is a polynomial with integer coefficients whose absolute values are less than $n$, and all such polynomials are the difference of two base- $n$ polynomials. We compute the minimal polynomial of $x=\sqrt{2}+\sqrt{3}$ first: since $x^{2}=5+2 \sqrt{6}$, we have $\left(x^{2}-5\right)^{2}=24$ so $x^{4}-10 x^{2}+1=0$. Therefore $\sqrt{2}+\sqrt{3}$ is a root of $\left(x^{2}+1\right)\left(x^{4}-10 x^{2}+1\right)=x^{6}-9 x^{4}-9 x^{2}+1$. The coefficients of this polynomial have magnitude at most 9 , so $n<10$.
+In the other direction, observe that $(\sqrt{2}+\sqrt{3})^{k}$ is of the form $a+b \sqrt{6}$ for integers $a$ and $b$ if $k$ is even, and $a \sqrt{2}+b \sqrt{3}$ if $k$ is odd. As no integer linear combination of the first expression can equal the second, we can treat these cases separately. Suppose $Q(x)=c_{d} x^{2 d}+c_{d-1} x^{2 d-2}+\cdots+c_{0}$ is an even polynomial with $\left|c_{i}\right|<9$ for all $i$ and $c_{d} \neq 0$. Let $y=(\sqrt{2}+\sqrt{3})^{2}=5+2 \sqrt{6}$ and observe that $y>9$. Then
+
+$$
+\begin{aligned}
+\left|c_{d} y^{d}\right| & \geq y^{d} \\
+& >\frac{8}{y-1}\left(y^{d}-1\right) \\
+& =8 y^{d-1}+8 y^{d-2}+\cdots+8 y+8 \\
+& \geq\left|c_{d-1} y^{d-1}+c_{d-2} y^{d-2}+\cdots+c_{0}\right|
+\end{aligned}
+$$
+
+Therefore $Q(\sqrt{2}+\sqrt{3})=c_{d} y^{d}+c_{d-1} y^{d-1}+\cdots+c_{0} \neq 0$, so no two distinct base-9 polynomials coincide at $x=\sqrt{2}+\sqrt{3}$.
+The same logic applies for the odd polynomial case after dividing out a factor of $\sqrt{2}+\sqrt{3}$, so $n=9$ works.
+7. Find the sum of all positive integers $n$ for which
+
+$$
+\frac{15 \cdot n!^{2}+1}{2 n-3}
+$$
+
+is an integer.
+Proposed by: Andrew Gu
+Answer: 90
+Solution: It is clear that $n=1$ and $n=2$ work so assume that $n>2$. If $2 n-3$ is composite then its smallest prime factor is at most $\frac{2 n-3}{2}
Guts Round
+
+
Guts Round}
+
+1. [4] Submit an integer $x$ as your answer to this problem. The number of points you receive will be $\max (0,8-|8 x-100|)$. (Non-integer answers will be given 0 points.)
+Proposed by: Andrew Gu, Andrew Lin
+Answer: 12 or 13
+Solution: We want to minimize $|8 x-100|$, so $x$ should equal either the floor or the ceiling of $\frac{100}{8}=12.5$. Note that no other answers receive any points, while both 12 and 13 receive 4 points.
+2. [4] Let $A B C$ be a triangle and $\omega$ be its circumcircle. The point $M$ is the midpoint of arc $B C$ not containing $A$ on $\omega$ and $D$ is chosen so that $D M$ is tangent to $\omega$ and is on the same side of $A M$ as $C$. It is given that $A M=A C$ and $\angle D M C=38^{\circ}$. Find the measure of angle $\angle A C B$.
+Proposed by: Joseph Heerens
+Answer: $33^{\circ}$
+Solution: By inscribed angles, we know that $\angle B A C=38^{\circ} \cdot 2=76^{\circ}$ which means that $\angle C=104^{\circ}-\angle B$. Since $A M=A C$, we have $\angle A C M=\angle A M C=90^{\circ}-\frac{\angle M A C}{2}=71^{\circ}$. Once again by inscribed angles, this means that $\angle B=71^{\circ}$ which gives $\angle C=33^{\circ}$.
+
+3. [4] Let $A B C$ be a triangle and $D, E$, and $F$ be the midpoints of sides $B C, C A$, and $A B$ respectively. What is the maximum number of circles which pass through at least 3 of these 6 points?
+Proposed by: Andrew Gu
+Answer: 17
+Solution: All $\binom{6}{3}=20$ triples of points can produce distinct circles aside from the case where the three points are collinear $(B D C, C E A, A F B)$.
+4. [4] Compute the value of $\sqrt{105^{3}-104^{3}}$, given that it is a positive integer.
+
+Proposed by: Andrew Gu
+Answer: 181
+Solution 1: First compute $105^{3}-104^{3}=105^{2}+105 \cdot 104+104^{2}=3 \cdot 105 \cdot 104+1=32761$. Note that $180^{2}=32400$, so $181^{2}=180^{2}+2 \cdot 180+1=32761$ as desired.
+
+Solution 2: We have $105^{3}-104^{3}=105^{2}+105 \cdot 104+104^{2}$. Thus
+
+$$
+104 \sqrt{3}<\sqrt{105^{3}-104^{3}}<105 \sqrt{3}
+$$
+
+Now estimating gives the bounds $180<104 \sqrt{3}$ and $105 \sqrt{3}<182$. So the answer is 181 .
+5. [5] Alice, Bob, and Charlie roll a 4,5 , and 6 -sided die, respectively. What is the probability that a number comes up exactly twice out of the three rolls?
+Proposed by: Andrew Lin
+Answer: $\frac{13}{30}$
+Solution 1: There are $4 \cdot 5 \cdot 6=120$ different ways that the dice can come up. The common number can be any of $1,2,3,4$, or 5 : there are $3+4+5=12$ ways for it to be each of $1,2,3$, or 4 , because we pick one of the three people's rolls to disagree, and there are 3,4 , and 5 ways that roll can come up (for Alice, Bob, and Charlie respectively). Finally, there are 4 ways for Bob and Charlie to both roll a 5 and Alice to roll any number. Thus there are 52 different ways to satisfy the problem condition, and our answer is $\frac{52}{120}=\frac{13}{30}$.
+
+Solution 2: If Bob rolls the same as Alice, Charlie must roll a different number. Otherwise Charlie must roll the same as either Alice or Bob. So the answer is
+
+$$
+\frac{1}{5} \cdot \frac{5}{6}+\frac{4}{5} \cdot \frac{2}{6}=\frac{13}{30}
+$$
+
+Solution 3: By complementary counting, the answer is
+
+$$
+1-\frac{1}{5} \cdot \frac{1}{6}-\frac{4}{5} \cdot \frac{4}{6}=\frac{13}{30}
+$$
+
+The first and second products correspond to rolling the same number three times and rolling three distinct numbers, respectively.
+6. [5] Two sides of a regular $n$-gon are extended to meet at a $28^{\circ}$ angle. What is the smallest possible value for $n$ ?
+
+Proposed by: James Lin
+Answer: 45
+Solution: We note that if we inscribe the $n$-gon in a circle, then according to the inscribed angle theorem, the angle between two sides is $\frac{1}{2}$ times some $x-y$, where $x$ and $y$ are integer multiples of the arc measure of one side of the $n$-gon. Thus, the angle is equal to $\frac{1}{2}$ times an integer multiple of $\frac{360}{n}$, so $\frac{1}{2} \cdot k \cdot \frac{360}{n}=28$ for some integer $k$. Simplifying gives $7 n=45 k$, and since all $k$ are clearly attainable, the smallest possible value of $n$ is 45 .
+7. [5] Ana and Banana are rolling a standard six-sided die. Ana rolls the die twice, obtaining $a_{1}$ and $a_{2}$, then Banana rolls the die twice, obtaining $b_{1}$ and $b_{2}$. After Ana's two rolls but before Banana's two rolls, they compute the probability $p$ that $a_{1} b_{1}+a_{2} b_{2}$ will be a multiple of 6 . What is the probability that $p=\frac{1}{6}$ ?
+Proposed by: James Lin
+Answer: $\frac{2}{3}$
+
+Solution: If either $a_{1}$ or $a_{2}$ is relatively prime to 6 , then $p=\frac{1}{6}$. If one of them is a multiple of 2 but not 6 , while the other is a multiple of 3 but not 6 , we also have $p=\frac{1}{6}$. In other words, $p=\frac{1}{6}$ if $\operatorname{gcd}\left(a_{1}, a_{2}\right)$ is coprime to 6 , and otherwise $p \neq \frac{1}{6}$. The probability that $p=\frac{1}{6}$ is $\frac{\left(3^{2}-1\right)\left(2^{2}-1\right)}{6^{2}}=\frac{2}{3}$ where $\frac{q^{2}-1}{q^{2}}$ corresponds to the probability that at least one of $a_{1}$ and $a_{2}$ is not divisible by $q$ for $q=2,3$.
+8. [5] Tessa picks three real numbers $x, y, z$ and computes the values of the eight expressions of the form $\pm x \pm y \pm z$. She notices that the eight values are all distinct, so she writes the expressions down in increasing order. For example, if $x=2, y=3, z=4$, then the order she writes them down is
+
+$$
+-x-y-z,+x-y-z,-x+y-z,-x-y+z,+x+y-z,+x-y+z,-x+y+z,+x+y+z
+$$
+
+How many possible orders are there?
+Proposed by: Yuan Yao
+Answer: 96
+Solution: There are $2^{3}=8$ ways to choose the sign for each of $x, y$, and $z$. Furthermore, we can order $|x|,|y|$, and $|z|$ in $3!=6$ different ways. Now assume without loss of generality that $0
February 15, 2020
Team Round
+
+1. [20] Let $n$ be a positive integer. Define a sequence by $a_{0}=1, a_{2 i+1}=a_{i}$, and $a_{2 i+2}=a_{i}+a_{i+1}$ for each $i \geq 0$. Determine, with proof, the value of $a_{0}+a_{1}+a_{2}+\cdots+a_{2^{n}-1}$.
+Proposed by: Kevin Ren
+Answer: $\frac{3^{n}+1}{2}$
+Solution 1: Note that $a_{2^{n}-1}=1$ for all $n$ by repeatedly applying $a_{2 i+1}=a_{i}$. Now let $b_{n}=$ $a_{0}+a_{1}+a_{2}+\cdots+a_{2^{n}-1}$. Applying the given recursion to every term of $b_{n}$ except $a_{0}$ gives
+
+$$
+\begin{aligned}
+b_{n}= & a_{0}+a_{1}+a_{2}+a_{3}+\cdots+a_{2^{n}-1} \\
+= & a_{0}+a_{2}+a_{4}+\cdots+a_{2^{n}-2}+a_{1}+a_{3}+\cdots+a_{2^{n}-1} \\
+= & a_{0}+\left(a_{0}+a_{1}\right)+\left(a_{1}+a_{2}\right)+\left(a_{2}+a_{3}\right)+\cdots+\left(a_{2^{n-1}-2}+a_{2^{n-1}-1}\right) \\
+& +a_{0}+a_{1}+a_{2}+\cdots+a_{2^{n-1}-1} \\
+= & 3 a_{0}+3 a_{1}+3 a_{2}+\cdots+3 a_{2^{n-1}-2}+3 a_{2^{n-1}-1}-a_{2^{n-1}-1} \\
+= & 3 b_{n-1}-1 .
+\end{aligned}
+$$
+
+Now we easily obtain $b_{n}=\frac{3^{n}+1}{2}$ by induction.
+Solution 2: Define a binary string to be good if it is the null string or of the form $101010 \ldots 10$. Let $c_{n}$ be the number of good subsequences of $n$ when written in binary form. We see $c_{0}=1$ and $c_{2 n+1}=c_{n}$ because the trailing 1 in $2 n+1$ cannot be part of a good subsequence. Furthermore, $c_{2 n+2}-c_{n+1}$ equals the number of good subsequences of $2 n+2$ that use the trailing 0 in $2 n+2$. We will show that this number is exactly $c_{n}$.
+Let $s$ be a good subsequence of $2 n+2$ that contains the trailing 0 . If $s$ uses the last 1 , remove both the last 1 and the trailing 0 from $s$; the result $s^{\prime}$ will be a good subsequence of $n$. If $s$ does not use the last 1 , consider the sequence $s^{\prime}$ where the trailing 0 in $2 n+2$ is replaced by the last 0 in $n$ (which is at the same position as the last 1 in $2 n+2$.) The map $s \mapsto s^{\prime}$ can be seen to be a bijection, and thus $c_{2 n+2}=c_{n}+c_{n+1}$.
+Now it is clear that $a_{n}=c_{n}$ for all $n$. Consider choosing each binary string between 0 and $2^{n}-1$ with equal probability. The probability that a given subsequence of length $2 k$ is good is $\frac{1}{2^{2 k}}$. There are $\binom{n}{2 k}$ subsequences of length $2 k$, so by linearity of expectation, the total expected number of good subsequences is
+
+$$
+\sum_{k=0}^{\lfloor n / 2\rfloor} \frac{\binom{n}{2 k}}{2^{2 k}}=\frac{(1+1 / 2)^{n}+(1-1 / 2)^{n}}{2}=\frac{3^{n}+1}{2^{n+1}}
+$$
+
+This is equal to the average of $a_{0}, \ldots, a_{2^{n}-1}$, therefore the sum $a_{0}+\cdots+a_{2^{n}-1}$ is $\frac{3^{n}+1}{2}$.
+2. [25] Let $n$ be a fixed positive integer. An $n$-staircase is a polyomino with $\frac{n(n+1)}{2}$ cells arranged in the shape of a staircase, with arbitrary size. Here are two examples of 5 -staircases:
+
+
+Prove that an $n$-staircase can be dissected into strictly smaller $n$-staircases.
+
+Solution 1: Viewing the problem in reverse, it is equivalent to show that we can use multiple $n$ staircases to make a single, larger $n$-staircase, because that larger $n$-staircase is made up of strictly smaller $n$-staircases, and is the example we need.
+For the construction, we first attach two $n$-staircases of the same size together to make an $n \times(n+1)$ rectangle. Then, we arrange $n(n+1)$ of these rectangles in a $(n+1) \times n$ grid, giving an $n(n+1) \times n(n+1)$ size square. Finally, we can use $\frac{n(n+1)}{2}$ of these squares to create a larger $n$-staircase of $n^{2}(n+1)^{2}$ smaller staircases, so we are done.
+
+Solution 2: An alternative construction using only $2 n+2$ staircases was submitted by team Yeah Knights A. We provide a diagram for $n=5$ and allow the interested reader to fill in the details.
+
+3. [25] Let $A B C$ be a triangle inscribed in a circle $\omega$ and $\ell$ be the tangent to $\omega$ at $A$. The line through $B$ parallel to $A C$ meets $\ell$ at $P$, and the line through $C$ parallel to $A B$ meets $\ell$ at $Q$. The circumcircles of $A B P$ and $A C Q$ meet at $S \neq A$. Show that $A S$ bisects $B C$.
+Proposed by: Andrew Gu
+Solution 1: In directed angles, we have
+
+$$
+\measuredangle C B P=\measuredangle B C A=\measuredangle B A P
+$$
+
+so $B C$ is tangent to the circumcircle of $A B P$. Likewise, $B C$ is tangent to the circumcircle of $A C Q$. Let $M$ be the midpoint of $B C$. Then $M$ has equal power $M B^{2}=M C^{2}$ with respect to the circumcircles of $A B P$ and $A C Q$, so the radical axis $A S$ passes through $M$.
+
+
+Solution 2: Since
+
+$$
+\measuredangle C B P=\measuredangle B C A=\measuredangle B A P=\measuredangle C Q P
+$$
+
+quadrilateral $B C Q P$ is cyclic. Then $A S, B P$, and $C Q$ concur at a point $A^{\prime}$. Since $A^{\prime} B \| A C$ and $A^{\prime} C \| A B$, quadrilateral $A B A^{\prime} C$ is a parallelogram so line $A S A^{\prime}$ bisects $B C$.
+4. [35] Alan draws a convex 2020-gon $\mathcal{A}=A_{1} A_{2} \cdots A_{2020}$ with vertices in clockwise order and chooses 2020 angles $\theta_{1}, \theta_{2}, \ldots, \theta_{2020} \in(0, \pi)$ in radians with sum $1010 \pi$. He then constructs isosceles triangles $\triangle A_{i} B_{i} A_{i+1}$ on the exterior of $\mathcal{A}$ with $B_{i} A_{i}=B_{i} A_{i+1}$ and $\angle A_{i} B_{i} A_{i+1}=\theta_{i}$. (Here, $A_{2021}=A_{1}$.) Finally, he erases $\mathcal{A}$ and the point $B_{1}$. He then tells Jason the angles $\theta_{1}, \theta_{2}, \ldots, \theta_{2020}$ he chose. Show that Jason can determine where $B_{1}$ was from the remaining 2019 points, i.e. show that $B_{1}$ is uniquely determined by the information Jason has.
+Proposed by: Andrew Gu, Colin Tang
+Solution 1: For each $i$, let $\tau_{i}$ be the transformation of the plane which is rotation by $\theta_{i}$ counterclockwise about $B_{i}$. Recall that a composition of rotations is a rotation or translation, and that the angles of rotation add. Consider the composition $\tau_{2020} \circ \tau_{2019} \circ \cdots \circ \tau_{1}$, with total rotation angle $1010 \pi$. This must be a translation because $1010 \pi=505(2 \pi)$. Also note that the composition sends $A_{1}$ to itself because $\tau_{i}\left(A_{i}\right)=A_{i+1}$. Therefore it is the identity. Now Jason can identify the map $\tau_{1}$ as $\tau_{2}^{-1} \circ \tau_{3}^{-1} \circ \cdots \circ \tau_{2020}^{-1}$, and $B_{1}$ is the unique fixed point of this map.
+
+Solution 2: Fix an arbitrary coordinate system. For $1 \leq k \leq 2020$, let $a_{k}, b_{k}$ be the complex numbers corresponding to $A_{k}, B_{k}$. The given condition translates to
+
+$$
+e^{i \theta_{k}}\left(b_{k}-a_{k}\right)=\left(b_{k}-a_{k+1}\right)
+$$
+
+In other words
+
+$$
+\left(e^{i \theta_{k}}-1\right) b_{k}=e^{i \theta_{k}} a_{k}-a_{k+1}
+$$
+
+or
+
+$$
+\left(e^{-i\left(\theta_{k-1}+\cdots+\theta_{1}\right)}-e^{-i\left(\theta_{k}+\cdots+\theta_{1}\right)}\right) b_{k}=e^{-i\left(\theta_{k-1}+\cdots+\theta_{1}\right)} a_{k}-e^{-i\left(\theta_{k}+\cdots+\theta_{1}\right)} a_{k+1} .
+$$
+
+Summing over all $k$, and using the fact that
+
+$$
+e^{-i\left(\theta_{1}+\cdots+\theta_{2020}\right)}=1,
+$$
+
+we see that the right hand side cancels to 0 , thus
+
+$$
+\sum_{k=1}^{2020}\left(e^{-i\left(\theta_{k-1}+\cdots+\theta_{1}\right)}-e^{-i\left(\theta_{k}+\cdots+\theta_{1}\right)}\right) b_{k}=0 .
+$$
+
+Jason knows $b_{2}, \ldots, b_{2020}$ and all the $\theta_{i}$, so the equation above is a linear equation in $b_{1}$. We finish by noting that the coefficient of $b_{1}$ is $1-e^{-i \theta_{1}}$ which is non-zero, as $\theta_{1} \in(0, \pi)$. Thus Jason can solve for $b_{1}$ uniquely.
+
+Solution 3: Let $A_{1} A_{2} \cdots A_{2020}$ and $\tilde{A}_{1} \tilde{A}_{2} \cdots \tilde{A}_{2020}$ be two 2020 -gons that satisfy the conditions in the problem statement, and let $B_{k}, \tilde{B}_{k}$ be the points Alan would construct with respect to these two polygons. It suffices to show that if $B_{k}=\tilde{B}_{k}$ for $k=2,3, \ldots, 2020$, then $B_{1}=\tilde{B}_{1}$.
+For $2 \leq k \leq 2020$, we note that
+
+$$
+A_{k} B_{k}=A_{k+1} B_{k}, \quad \tilde{A}_{k} B_{k}=\tilde{A}_{k+1} B_{k}
+$$
+
+Furthermore, we have the equality of directed angles $\angle A_{k} B_{k} A_{k+1}=\angle \tilde{A}_{k} B_{k} \tilde{A}_{k+1}=\theta_{k}$, therefore $\angle A_{k} B_{k} \tilde{A}_{k}=\angle A_{k+1} B_{k} \tilde{A}_{k+1}$. This implies the congruence $\triangle A_{k} B_{k} \tilde{A}_{k} \cong \triangle A_{k+1} B_{k} \tilde{A}_{k+1}$.
+The congruence shows that $A_{k} \tilde{A}_{k}=A_{k+1} \tilde{A}_{k+1}$; furthermore, the angle from the directed segment $\overrightarrow{A_{k} \tilde{A}_{k}}$ to $\overrightarrow{A_{k+1} \tilde{A}_{k+1}}$ is $\theta_{k}$ counterclockwise. This holds for $k=2,3, \ldots, 2020$; we conclude that $A_{1} \tilde{A}_{1}=A_{2} \tilde{A}_{2}$, and the angle from the directed segments $\overrightarrow{A_{1}} \tilde{A}_{1}$ to $\overrightarrow{A_{2}} \tilde{A}_{2}$ is
+
+$$
+-\sum_{k=2}^{2020} \theta_{k}=\theta_{1}-1010 \pi=\theta_{1}
+$$
+
+counterclockwise.
+Finally we observe that $A_{1} B_{1}=A_{2} B_{1}$, and the angle from the directed segment $\overrightarrow{A_{1} B_{1}}$ to $\overrightarrow{A_{2} B_{1}}$ is $\theta_{1}$ counterclockwise. This implies $\angle B_{1} A_{1} \tilde{A}_{1}=\angle B_{1} A_{2} \tilde{A}_{2}$, so $\triangle A_{1} B_{1} \tilde{A}_{1} \cong \triangle A_{2} B_{1} \tilde{A}_{2}$. Thus $\tilde{A}_{1} B_{1}=$ $\tilde{A}_{2} B_{1}$, and the angle from $\overrightarrow{\tilde{A}_{1} B_{1}}$ to $\overrightarrow{\tilde{A}_{2} B_{1}}$ is $\theta_{1}$ counterclockwise. We conclude that $B_{1}=\tilde{B}_{1}$.
+5. [40] Let $a_{0}, b_{0}, c_{0}, a, b, c$ be integers such that $\operatorname{gcd}\left(a_{0}, b_{0}, c_{0}\right)=\operatorname{gcd}(a, b, c)=1$. Prove that there exists a positive integer $n$ and integers $a_{1}, a_{2}, \ldots, a_{n}=a, b_{1}, b_{2}, \ldots, b_{n}=b, c_{1}, c_{2}, \ldots, c_{n}=c$ such that for all $1 \leq i \leq n, a_{i-1} a_{i}+b_{i-1} b_{i}+c_{i-1} c_{i}=1$.
+Proposed by: Michael Ren
+Solution: The problem statement is equivalent to showing that we can find a sequence of vectors, each with 3 integer components, such that the first vector is $\left(a_{0}, b_{0}, c_{0}\right)$, the last vector is $(a, b, c)$, and every pair of adjacent vectors has dot product equal to 1 .
+
+We will show that any vector $(a, b, c)$ can be sent to $(1,0,0)$. This is sufficient, because given vectors $\left(a_{0}, b_{0}, c_{0}\right)$ and $(a, b, c)$, we take the sequence from $\left(a_{0}, b_{0}, c_{0}\right)$ to $(1,0,0)$ and then add the reverse of the sequence from $(a, b, c)$ to $(1,0,0)$.
+First, suppose that some two of $a, b, c$ are relatively prime. Here we will suppose that $a$ and $b$ are relatively prime; the other cases are similar. If neither of $a$ or $b$ is 0 , then by Bezout's identity, there exist $p, q$ such that $|p|+|q|<|a|+|b|$ and $a p+b q=1$, so we can send ( $a, b, c$ ) to ( $p, q, 0$ ). (Finding such numbers can be done using the extended Euclidean algorithm.) Clearly $p$ and $q$ must also be relatively prime, so we can apply Bezout's identity repeatedly until we eventually have $(1,0,0),(-1,0,0),(0,1,0)$, or $(0,-1,0)$. Now, starting from $(0,-1,0)$, we can do $(0,-1,0) \rightarrow(1,-1,0) \rightarrow(1,0,0)$, and we can do something similar to convert $(-1,0,0)$ to $(0,1,0)$.
+Now suppose that no two of $a, b, c$ are relatively prime. Let $f=\operatorname{gcd}(a, b)$. We claim that we can find $x, y, z$ such that $a x y+b x+c z=1$. Notice that this is the same as $(a y+b) x+c z=1$. Since
+$\operatorname{gcd}(a, b, c)=1$, there exists $y$ such that $\operatorname{gcd}(a y+b, c)=1$. Then by Bezout's identity, there exist $x, z$ such that $(a y+b) x+c z=1$. Therefore, we can send $(a, b, c)$ to $(x y, x, z)$. Clearly $x$ and $z$ must be relatively prime, so we have reduced to the case above, and we can apply the process described above for that case.
+
+At the end of this process, we will have $(1,0,0),(0,1,0)$, or $(0,0,1)$. The second of these can be converted into $(1,0,0)$ by doing $(0,1,0) \rightarrow(1,1,0) \rightarrow(1,0,0)$, and a similar sequence shows the same for the third. Therefore, $(a, b, c)$ can be sent to $(1,0,0)$.
+6. [40] Let $n>1$ be a positive integer and $S$ be a collection of $\frac{1}{2}\binom{2 n}{n}$ distinct $n$-element subsets of $\{1,2, \ldots, 2 n\}$. Show that there exists $A, B \in S$ such that $|A \cap B| \leq 1$.
+Proposed by: Michael Ren
+Solution 1: Assume for the sake of contradiction that there exist no such $A, B$. Pair up each subset with its complement, like so:
+
+$$
+\begin{aligned}
+\{1,2,3, \ldots, n\} & \leftrightarrow\{n+1, n+2, \ldots, 2 n\} \\
+\{1,2,3, \ldots, n-1, n+1\} & \leftrightarrow\{n, n+2, \ldots, 2 n\} \\
+\{1,2,3, \ldots, n-1, n+2\} & \leftrightarrow\{n, n+1, n+3, \ldots, 2 n\} \\
+& \vdots
+\end{aligned}
+$$
+
+Note that for each pair, we can have at most one of the two in $S$. Since $S$ has $\frac{1}{2}$ of the total number of subsets with size $n$, it must be that we have exactly one element from each pair in $S$. For any $s_{0} \in S$, none of the subsets that share exactly one element with $s_{0}$ can be in $S$, so their complements must be in $S$. This means that every subset with $n-1$ shared elements with $s_{0}$ must be in $S$. Without loss of generality, assume $\{1,2,3, \ldots, n\} \in S$. Then, $\{2,3,4, \ldots, n+1\} \in S$, so $\{3,4,5, \ldots, n+2\} \in S$. Continuing on in this manner, we eventually reach $\{n+1, n+2, \ldots, 2 n\} \in S$, contradiction.
+
+Solution 2: Let $[2 n]=\{1,2, \ldots, 2 n\}$. Consider the following cycle of $2 n-1$ sets such that any two adjacent sets have an intersection of size 1 :
+
+$$
+\begin{aligned}
+& \{1,2,3, \ldots, n\} \\
+& \{1, n+1, n+2, \ldots, 2 n-1\} \\
+& \{1,2 n, 2,3, \ldots, n-1\} \\
+& \vdots \\
+& \{1, n+2, n+3, \ldots, 2 n\}
+\end{aligned}
+$$
+
+If $S$ contains two adjacent elements of the cycle then we are done. For each permutation $\sigma$ of [2n], we can consider the cycle $C_{\sigma}$ of sets obtained after applying $\sigma$, i.e. $\{\sigma(1), \sigma(2), \sigma(3), \ldots, \sigma(n)\}$ and so on. In total, each subset of $[2 n]$ with size $n$ appears $(2 n-1)(n!)^{2}$ times across all the cycles $C_{\sigma}$, so
+
+$$
+\sum_{\sigma}\left|C_{\sigma} \cap S\right|=|S|(2 n-1)(n!)^{2}=\frac{2 n-1}{2}(2 n)!
+$$
+
+where the sum is over all $(2 n)$ ! permutations of $[2 n]$. This means that on average across possible cycles, $\frac{2 n-1}{2}$ of its elements are in $S$. Thus, if we select a cycle $C_{\sigma}$ uniformly at random, with positive probability we will have $\left|C_{\sigma} \cap S\right| \geq n$, so two adjacent elements in this cycle will be in $S$. Therefore, there must exist some two subsets in $S$ that share at most one element.
+This proof will work under the weaker condition $|S|>\frac{n-1}{2 n-1}\binom{2 n}{n}$.
+Remark. A family of sets such that $|A \cap B| \geq t$ for every pair of distinct sets $A, B$ is called $t$-intersecting. Ahlswede and Khachatrian solved the problem of determining the largest $k$-uniform $t$ intersecting family. See "Katona's Intersection Theorem: Four Proofs" or "The Complete Intersection
+
+Theorem for Systems of Finite Sets" for exact results.
+7. [50] Positive real numbers $x$ and $y$ satisfy
+
+$$
+||\cdots|||x|-y|-x| \cdots-y|-x|=||\cdots|||y|-x|-y| \cdots-x|-y|
+$$
+
+where there are 2019 absolute value signs $|\cdot|$ on each side. Determine, with proof, all possible values of $\frac{x}{y}$.
+Proposed by: Krit Boonsiriseth
+Answer: $\frac{1}{3}, 1,3$
+Solution: Clearly $x=y$ works. Else WLOG $x0$ we have
+
+$$
+\begin{aligned}
+E_{a, b} & =\frac{a-1}{a+b-1}\left(E_{a-2, b}+1\right)+\frac{b}{a+b-1} E_{a-1, b-1} \\
+& =\frac{(a-1)\left(E_{a-2, b}+1\right)+b E_{a-1, b-1}}{a+b-1}
+\end{aligned}
+$$
+
+We claim that $E_{a, b}=\frac{a(a-1)}{2(a+b-1)}$, which will yield an answer of $\frac{45}{19}$. To prove this, we use induction. In the base case of $a=0$ we find $\frac{a(a-1)}{2(a+b-1)}=0$, as desired. Also, for $a>0$ we have that by the inductive hypothesis
+
+$$
+\begin{aligned}
+E_{a, b} & =\frac{(a-1)((a-2)(a-3)+2(a+b-3))+b(a-1)(a-2)}{2(a+b-1)(a+b-3)} \\
+& =\frac{(a-1)(a-2)(a+b-3)+2(a-1)(a+b-3)}{2(a+b-1)(a+b-3)} \\
+& =\frac{a(a-1)}{2(a+b-1)}
+\end{aligned}
+$$
+
+as desired.
+10. [60] Let $x$ and $y$ be non-negative real numbers that sum to 1 . Compute the number of ordered pairs $(a, b)$ with $a, b \in\{0,1,2,3,4\}$ such that the expression $x^{a} y^{b}+y^{a} x^{b}$ has maximum value $2^{1-a-b}$.
+Proposed by: Shengtong Zhang
+Answer: 17
+Solution: Let $f(x, y)=x^{a} y^{b}+y^{a} x^{b}$. Observe that $2^{1-a-b}$ is merely the value of $f\left(\frac{1}{2}, \frac{1}{2}\right)$, so this value is always achievable.
+
+We claim (call this result (*)) that if $(a, b)$ satisfies the condition, so does $(a+1, b+1)$. To see this, observe that if $f(x, y) \leq 2^{1-a-b}$, then multiplying by the inequality $x y \leq \frac{1}{4}$ yields $x^{a+1} y^{b+1}+$ $y^{a+1} x^{b+1} \leq 2^{-1-a-b}$, as desired.
+For the rest of the solution, without loss of generality we consider the $a \geq b$ case. If $a=b=0$, then $f(x, y)=2$, so $(0,0)$ works. If $a=1$ and $b=0$, then $f(x, y)=x+y=1$, so $(1,0)$ works. For $a \geq 2$, $(a, 0)$ fails since $f(1,0)=1>2^{1-a}$.
+If $a=3$ and $b=1, f(x, y)=x y\left(x^{2}+y^{2}\right)=x y(1-2 x y)$, which is maximized at $x y=\frac{1}{4} \Longleftrightarrow x=y=\frac{1}{2}$, so $(3,1)$ works. However, if $a=4$ and $b=1, f(x, y)=x y\left(x^{3}+y^{3}\right)=x y\left((x+y)^{3}-3 x y(x+y)\right)=$ $x y(1-3 x y)$, which is maximized at $x y=\frac{1}{6}$. Thus $(4,1)$ does not work.
+From these results and $(*)$, we are able to deduce all the pairs that do work ( $\swarrow$ represents those pairs that work by (*)):
+
+
diff --git a/HarvardMIT/md/en-241-2020-nov-thm-solutions.md b/HarvardMIT/md/en-241-2020-nov-thm-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..1333fca0670ffc79e2e7c075fae15d8a63ae1a3f
--- /dev/null
+++ b/HarvardMIT/md/en-241-2020-nov-thm-solutions.md
@@ -0,0 +1,145 @@
+## HMMO 2020
+
+November 14-21, 2020
+Theme Round
+
+1. Chelsea goes to La Verde's at MIT and buys 100 coconuts, each weighing 4 pounds, and 100 honeydews, each weighing 5 pounds. She wants to distribute them among $n$ bags, so that each bag contains at most 13 pounds of fruit. What is the minimum $n$ for which this is possible?
+Proposed by: Daniel Zhu
+Answer: 75
+Solution: The answer is $n=75$, given by 50 bags containing one honeydew and two coconuts (13 pounds), and 25 bags containing two honeydews (10 pounds).
+To show that this is optimal, assign each coconut 1 point and each honeydew 2 points, so that 300 points worth of fruit are bought in total. Then, we claim that each bag can contain at most 4 points of fruit, thus requiring $n \geq 300 / 4=75$. To see this, note that each bag containing greater than 4 points must contain either five coconuts ( 20 pounds), three coconuts and a honeydew (17 pounds), one coconut and two honeydews (14 pounds), or three honeydews (15 pounds).
+2. In the future, MIT has attracted so many students that its buildings have become skyscrapers. Ben and Jerry decide to go ziplining together. Ben starts at the top of the Green Building, and ziplines to the bottom of the Stata Center. After waiting $a$ seconds, Jerry starts at the top of the Stata Center, and ziplines to the bottom of the Green Building. The Green Building is 160 meters tall, the Stata Center is 90 meters tall, and the two buildings are 120 meters apart. Furthermore, both zipline at 10 meters per second. Given that Ben and Jerry meet at the point where the two ziplines cross, compute $100 a$.
+Proposed by: Esha Bhatia
+Answer: 740
+Solution: Define the following lengths:
+
+
+Note that due to all the 3-4-5 triangles, we find $\frac{x}{z}=\frac{z}{y}=\frac{4}{3}$, so $120=x+y=\frac{25}{12} z$. Then,
+
+$$
+u=\frac{5}{3} x=\frac{20}{9} z=\frac{16}{15} 120=128
+$$
+
+while
+
+$$
+v=\frac{5}{4} y=\frac{15}{16} z=\frac{9}{20} 120=54
+$$
+
+Thus $u-v=74$, implying that $a=7.4$.
+3. Harvard has recently built a new house for its students consisting of $n$ levels, where the $k$ th level from the top can be modeled as a 1-meter-tall cylinder with radius $k$ meters. Given that the area of all the lateral surfaces (i.e. the surfaces of the external vertical walls) of the building is 35 percent of the total surface area of the building (including the bottom), compute $n$.
+Proposed by: Daniel Zhu
+Answer: 13
+Solution: The $k$ th layer contributes a lateral surface area of $2 k \pi$, so the total lateral surface area is
+
+$$
+2(1+2+\cdots+n) \pi=n(n+1) \pi
+$$
+
+On the other hand, the vertical surface area is $2 n^{2} \pi$ (No need to sum layers, just look at the building from above and from below). Therefore,
+
+$$
+n+1=\frac{7}{20}(3 n+1)
+$$
+
+and $n=13$.
+4. Points $G$ and $N$ are chosen on the interiors of sides $E D$ and $D O$ of unit square $D O M E$, so that pentagon $G N O M E$ has only two distinct side lengths. The sum of all possible areas of quadrilateral $N O M E$ can be expressed as $\frac{a-b \sqrt{c}}{d}$, where $a, b, c, d$ are positive integers such that $\operatorname{gcd}(a, b, d)=1$ and $c$ is square-free (i.e. no perfect square greater than 1 divides $c$ ). Compute $1000 a+100 b+10 c+d$.
+Proposed by: Andrew Lin
+Answer: 10324
+
+## Solution:
+
+
+
+Since $M O=M E=1$, but $O N$ and $G E$ are both less than 1, we must have either $O N=N G=G E=x$ (call this case 1) or $O N=G E=x, N G=1$ (call this case 2 ).
+Either way, the area of $N O M E$ (a trapezoid) is $\frac{1+x}{2}$, and triangle $N G T$ is a 45-45-90 triangle. In case 1, we have $1=O N+N T=x\left(1+\frac{\sqrt{2}}{2}\right)$, so $x=2-\sqrt{2}$ and the area of the trapezoid is $\frac{3-\sqrt{2}}{2}$. In case 2 , we have $1=O N+N T=x+\frac{\sqrt{2}}{2}$, which yields an area of $\frac{4-\sqrt{2}}{4}$ as $x=\frac{2-\sqrt{2}}{2}$. The sum of these two answers is $\frac{10-3 \sqrt{2}}{4}$.
+5. The classrooms at MIT are each identified with a positive integer (with no leading zeroes). One day, as President Reif walks down the Infinite Corridor, he notices that a digit zero on a room sign has fallen off. Let $N$ be the original number of the room, and let $M$ be the room number as shown on the sign.
+
+The smallest interval containing all possible values of $\frac{M}{N}$ can be expressed as $\left[\frac{a}{b}, \frac{c}{d}\right)$ where $a, b, c, d$ are positive integers with $\operatorname{gcd}(a, b)=\operatorname{gcd}(c, d)=1$. Compute $1000 a+100 b+10 c+d$.
+Proposed by: Andrew Lin
+Answer: 2031
+Solution: Let $A$ represent the portion of $N$ to the right of the deleted zero, and $B$ represent the rest of $N$. For example, if the unique zero in $N=12034$ is removed, then $A=34$ and $B=12000$. Then, $\frac{M}{N}=\frac{A+B / 10}{A+B}=1-\frac{9}{10} \frac{B}{N}$.
+The maximum value for $B / N$ is 1 , which is achieved when $A=0$. Also, if the 0 removed is in the $10^{k}$ 's place ( $k=2$ in the example above), we find that $A<10^{k}$ and $B \geq 10^{k+1}$, meaning that $A / B<1 / 10$ and thus $B / N>10 / 11$. Also, $B / N$ can get arbitrarily close to $10 / 11$ via a number like $1099 \ldots 9$.
+Therefore the fraction $\frac{M}{N}$ achieves a minimum at $\frac{1}{10}$ and always stays below $\frac{2}{11}$, though it can get arbitrarily close. The desired interval is then $\left[\frac{1}{10}, \frac{2}{11}\right)$.
+6. The elevator buttons in Harvard's Science Center form a $3 \times 2$ grid of identical buttons, and each button lights up when pressed. One day, a student is in the elevator when all the other lights in the elevator malfunction, so that only the buttons which are lit can be seen, but one cannot see which floors they correspond to. Given that at least one of the buttons is lit, how many distinct arrangements can the student observe? (For example, if only one button is lit, then the student will observe the same arrangement regardless of which button it is.)
+Proposed by: Sheldon Kieren Tan
+Answer: 44
+Solution 1: We first note that there are $2^{6}-1=63$ possibilities for lights in total. We now count the number of duplicates we need to subtract by casework on the number of buttons lit. To do this, we do casework on the size of the minimal "bounding box" of the lights:
+
+- If the bounding box is $1 \times 1$, the only arrangement up to translation is a solitary light, which can be translated 6 ways. This means we must subtract 5 .
+- If the bounding box is $2 \times 1$, there is 1 arrangement and 4 translations, so we must subtract 3 .
+- If the bounding box is $1 \times 2$, there is 1 arrangement and 3 translations, so we must subtract 2 .
+- If the bounding box is $3 \times 1$, there are 2 arrangements and 2 translations, so we must subtract 2 .
+- If the bounding box is $2 \times 2$, there are 2 arrangements with 2 lights, 4 with 3 lights, and 1 with 4 lights -7 in total. Since there are two translations, we must subtract 7 .
+
+The final answer is $63-5-3-2-2-7=44$.
+Solution 2: We may also count duplicates by doing casework on buttons lit:
+
+- 1 buttons lit: There are 6 arrangements but all are the same, so we need to subtract 5 duplicates in this case.
+- 2 buttons lit: There are 4 indistinguishable ways for the buttons to be vertically adjacent, 3 to be horizontally adjacent, 2 ways for the buttons to be diagonally adjacent for each of 2 directions of diagonals, and 2 for when the lights are in the same vertical line but not adjacent. Since we need to count each of these cases only once, the number of duplicates we need to subtract is 3 (2 vertically adjacent), 2 ( 2 horizontally adjacent), $2 \times 1$ ( 2 diagonally adjacent), and 1 ( 2 in same vertical line but not adjacent) for a total of 8 duplicates.
+- 3 buttons lit: There are 2 indistinguishable ways for all the buttons in a column to be lit and 2 ways for the buttons to be lit in the shape of an L, given the rotation of the L . Thus, the number of duplicates we need to subtract is 1 ( 1 column), $1 \times 4$ (rotations of L ), for a total of 5 duplicates.
+- 4 buttons lit: There are 2 indistinguishable ways for the lights to be arranged in a square (and no other duplicates), so we need to subtract 1 duplicate in this case.
+- When there are 5 or 6 buttons lit, all of the arrangements of lights are distinct, so we do not subtract any duplicates for these cases.
+
+Thus, the total number of arrangements is $64-(1+5+8+5+1)=44$.
+7. While waiting for their food at a restaurant in Harvard Square, Ana and Banana draw 3 squares $\square_{1}, \square_{2}, \square_{3}$ on one of their napkins. Starting with Ana, they take turns filling in the squares with integers from the set $\{1,2,3,4,5\}$ such that no integer is used more than once. Ana's goal is to minimize the minimum value $M$ that the polynomial $a_{1} x^{2}+a_{2} x+a_{3}$ attains over all real $x$, where $a_{1}, a_{2}, a_{3}$ are the integers written in $\square_{1}, \square_{2}, \square_{3}$ respectively. Banana aims to maximize $M$. Assuming both play optimally, compute the final value of $100 a_{1}+10 a_{2}+a_{3}$.
+Proposed by: Sheldon Kieren Tan
+Answer: 451
+Solution: Relabel $a_{1}, a_{2}, a_{3}$ as $a, b, c$. This is minimized at $x=\frac{-b}{2 a}$, so $M=c-\frac{b^{2}}{4 a}$.
+If in the end $a=5$ or $b \in\{1,2\}$, then $\frac{b^{2}}{4 a} \leq 1$ and $M \geq 0$. The only way for Ana to block this is to set $b=5$, which will be optimal if we show that it allows Ana to force $M<0$, which we will now do. At this point, Banana has two choices:
+
+- If Banana fixes a value of $a$, Ana's best move is to pick $c=1$, or $c=2$ if it has not already been used. The latter case yields $M<-1$, while the optimal move in the latter case $(a=4)$ yields $M=1-\frac{25}{16}>-1$.
+- If Banana fixes a value of $c$, then if that a value is not 1 Ana can put $a=1$, yielding $M \leq 4-\frac{25}{4}<$ -1 . On the other hand, if Banana fixes $c=1$ then Ana's best move is to put $a=2$, yielding $M=1-\frac{25}{8}<-1$.
+
+Thus Banana's best move is to set $a=4$, eliciting a response of $c=1$. Since $1-\frac{25}{16}<0$, this validates our earlier claim that $b=5$ was the best first move.
+8. After viewing the John Harvard statue, a group of tourists decides to estimate the distances of nearby locations on a map by drawing a circle, centered at the statue, of radius $\sqrt{n}$ inches for each integer $2020 \leq n \leq 10000$, so that they draw 7981 circles altogether. Given that, on the map, the Johnston Gate is 10 -inch line segment which is entirely contained between the smallest and the largest circles, what is the minimum number of points on this line segment which lie on one of the drawn circles? (The endpoint of a segment is considered to be on the segment.)
+
+Proposed by: Daniel Zhu
+Answer: 49
+Solution: Consider a coordinate system on any line $\ell$ where 0 is placed at the foot from $(0,0)$ to $\ell$. Then, by the Pythagorean theorem, a point $(x, y)$ on $\ell$ is assigned a coordinate $u$ for which $x^{2}+y^{2}=u^{2}+a$ for some fixed $a$ (dependent only on $\ell$ ). Consider this assignment of coordinates for our segment.
+First, suppose that along the line segment $u$ never changes sign; without loss of generality, assume it is positive. Then, if $u_{0}$ is the minimum value of $u$, the length of the interval covered by $u^{2}$ is $\left(u_{0}+10\right)^{2}-u_{0}^{2}=100+20 u_{0} \geq 100$, meaning that at least 100 points lie on the given circles.
+Now suppose that $u$ is positive on a length of $k$ and negative on a length of $10-k$. Then, it must intersect the circles at least $\left\lfloor k^{2}\right\rfloor+\left\lfloor(10-k)^{2}\right\rfloor$ points, which can be achieved for any $k$ by setting $a=2020+\varepsilon$ for very small $\varepsilon$.
+
+To minimize this quantity note that $k^{2}+(10-k)^{2} \geq 50$, so $\left\lfloor k^{2}\right\rfloor+\left\lfloor(10-k)^{2}\right\rfloor>k^{2}+(10-k)^{2}-2 \geq 48$, proving the bound. For a construction, set $k=4.99999$.
+9. While waiting for their next class on Killian Court, Alesha and Belinda both write the same sequence $S$ on a piece of paper, where $S$ is a 2020-term strictly increasing geometric sequence with an integer common ratio $r$. Every second, Alesha erases the two smallest terms on her paper and replaces them with their geometric mean, while Belinda erases the two largest terms in her paper and replaces them with their geometric mean. They continue this process until Alesha is left with a single value $A$ and Belinda is left with a single value $B$. Let $r_{0}$ be the minimal value of $r$ such that $\frac{A}{B}$ is an integer. If $d$ is the number of positive factors of $r_{0}$, what is the closest integer to $\log _{2} d$ ?
+Proposed by: Hahn Lheem
+Answer: 2018
+Solution: Because we only care about when the ratio of $A$ to $B$ is an integer, the value of the first term in $S$ does not matter. Let the initial term in $S$ be 1 . Then, we can write $S$ as $1, r, r^{2}, \ldots, r^{2019}$. Because all terms are in terms of $r$, we can write $A=r^{a}$ and $B=r^{b}$. We will now solve for $a$ and $b$.
+Observe that the geometric mean of two terms $r^{m}$ and $r^{n}$ is simply $r^{\frac{m+n}{2}}$, or $r$ raised to the arithmetic mean of $m$ and $n$. Thus, to solve for $a$, we can simply consider the sequence $0,1,2, \ldots, 2019$, which comes from the exponents of the terms in $S$, and repeatedly replace the smallest two terms with their arithmetic mean. Likewise, to solve for $b$, we can consider the same sequence $0,1,2, \ldots, 2019$ and repeatedly replace the largest two terms with their arithmetic mean.
+We begin by computing $a$. If we start with the sequence $0,1, \ldots, 2019$ and repeatedly take the arithmetic mean of the two smallest terms, the final value will be
+
+$$
+a=\frac{\frac{\frac{0+1}{2}+2}{2}+3}{2}+\cdots+2019 \sum_{k=1}^{2019} \frac{k}{2} \frac{2^{2020-k}}{2}
+$$
+
+Then, we can compute
+
+$$
+\begin{aligned}
+2 a & =\sum_{k=1}^{2019} \frac{k}{2^{2019-k}} \\
+\Longrightarrow a & =2 a-a=\sum_{k=1}^{2019} \frac{k}{2^{2019-k}}-\sum_{k=1}^{2019} \frac{k}{2^{2020-k}} \\
+& =\sum_{k=1}^{2019} \frac{k}{2^{2019-k}}-\sum_{k=0}^{2018} \frac{k+1}{2^{2019-k}} \\
+& =2019-\sum_{j=1}^{2019} \frac{1}{2^{j}} \\
+& =2019-\left(1-\frac{1}{2^{2019}}\right)=2018+\frac{1}{2^{2019}}
+\end{aligned}
+$$
+
+Likewise, or by symmetry, we can find $b=1-\frac{1}{2^{2019}}$.
+Since we want $\frac{A}{B}=\frac{r^{a}}{r^{b}}=r^{a-b}$ to be a positive integer, and $a-b=\left(2018+\frac{1}{2^{2019}}\right)-\left(1-\frac{1}{2^{2019}}\right)=$ $2017+\frac{1}{2^{2018}}, r$ must be a perfect $\left(2^{2018}\right)^{\text {th }}$ power. Because $r>1$, the minimal possible value is $r=2^{2^{2018}}$. Thus, $d=2^{2018}+1$, and so $\log _{2} d$ is clearly closest to 2018 .
+10. Sean enters a classroom in the Memorial Hall and sees a 1 followed by 2020 0's on the blackboard. As he is early for class, he decides to go through the digits from right to left and independently erase the $n$th digit from the left with probability $\frac{n-1}{n}$. (In particular, the 1 is never erased.) Compute the expected value of the number formed from the remaining digits when viewed as a base- 3 number. (For example, if the remaining number on the board is 1000 , then its value is 27 .)
+Proposed by: Vincent Bian
+Answer: 681751
+Solution: Suppose Sean instead follows this equivalent procedure: he starts with $M=10 \ldots 0$, on the board, as before. Instead of erasing digits, he starts writing a new number on the board. He goes through the digits of $M$ one by one from left to right, and independently copies the $n$th digit from the left with probability $\frac{1}{n}$. Now, let $a_{n}$ be the expected value of Sean's new number after he has gone through the first $n$ digits of $M$. Note that the answer to this problem will be the expected value of $a_{2021}$, since $M$ has 2021 digits.
+Note that $a_{1}=1$, since the probability that Sean copies the first digit is 1 .
+For $n>1$, note that $a_{n}$ is $3 a_{n-1}$ with probability $\frac{1}{n}$, and is $a_{n-1}$ with probability $\frac{n-1}{n}$. Thus,
+
+$$
+\mathbb{E}\left[a_{n}\right]=\frac{1}{n} \mathbb{E}\left[3 a_{n-1}\right]+\frac{n-1}{n} \mathbb{E}\left[a_{n-1}\right]=\frac{n+2}{n} \mathbb{E}\left[a_{n-1}\right] .
+$$
+
+Therefore,
+
+$$
+\mathbb{E}\left[a_{2021}\right]=\frac{4}{2} \cdot \frac{5}{3} \cdots \frac{2023}{2021}=\frac{2022 \cdot 2023}{2 \cdot 3}=337 \cdot 2023=681751
+$$
+
diff --git a/HarvardMIT/md/en-242-2021-feb-algnt-solutions.md b/HarvardMIT/md/en-242-2021-feb-algnt-solutions.md
new file mode 100644
index 0000000000000000000000000000000000000000..847e567b543717939fc99bc6edd02ac64ce80870
--- /dev/null
+++ b/HarvardMIT/md/en-242-2021-feb-algnt-solutions.md
@@ -0,0 +1,239 @@
+# HMMT Spring 2021
March 06, 2021
Algebra and Number Theory Round
+
+
Algebra and Number Theory Round}
+
+1. Compute the sum of all positive integers $n$ for which the expression
+
+$$
+\frac{n+7}{\sqrt{n-1}}
+$$
+
+is an integer.
+Proposed by: Ryan Kim
+Answer: 89
+Solution: We know $\sqrt{n-1}$ must be a positive integer, because the numerator is a positive integer, and the square root of an integer cannot be a non-integer rational. From this,
+
+$$
+\frac{n+7}{\sqrt{n-1}}=\sqrt{n-1}+\frac{8}{\sqrt{n-1}}
+$$
+
+is a positive integer, so we $\sqrt{n-1}$ must be a positive integer that divides 8 . There are 4 such positive integers: $1,2,4,8$, which give $n=2,5,17,65$, so the answer is 89 .
+2. Compute the number of ordered pairs of integers $(a, b)$, with $2 \leq a, b \leq 2021$, that satisfy the equation
+
+$$
+a^{\log _{b}\left(a^{-4}\right)}=b^{\log _{a}\left(b a^{-3}\right)} .
+$$
+
+Proposed by: Vincent Bian
+Answer: 43
+Solution: Taking $\log _{a}$ of both sides and simplifying tives
+
+$$
+-4 \log _{b} a=\left(\log _{a} b\right)^{2}-3 \log _{a} b
+$$
+
+Plugging in $x=\log _{a} b$ and using $\log _{b} a=\frac{1}{\log _{a} b}$ gives
+
+$$
+x^{3}-3 x^{2}+4=0
+$$
+
+We can factor the polynomial as $(x-2)(x-2)(x+1)$, meaning $b=a^{2}$ or $b=a^{-1}$. The second case is impossible since both $a$ and $b$ are positive integers. So, we need only count the number of $10$ and a sequence $a_{1}, a_{2}, \ldots, a_{B}$ of nonnegative real numbers satisfies $a_{n} \leq B+\sum_{i
Combinatorics Round
+
+1. Leo the fox has a 5 by 5 checkerboard grid with alternating red and black squares. He fills in the grid with the numbers $1,2,3, \ldots, 25$ such that any two consecutive numbers are in adjacent squares (sharing a side) and each number is used exactly once. He then computes the sum of the numbers in the 13 squares that are the same color as the center square. Compute the maximum possible sum Leo can obtain.
+Proposed by: Milan Haiman
+Answer: 169
+Solution: Since consecutive numbers are in adjacent squares and the grid squares alternate in color, consecutive numbers must be in squares of opposite colors. Then the odd numbers $1,3,5, \ldots, 25$ all share the same color while the even numbers $2,4, \ldots, 24$ all share the opposite color. Since we have 13 odd numbers and 12 even numbers, the odd numbers must correspond to the color in the center square, so Leo's sum is always $1+3+5+\cdots+25=169$.
+2. Ava and Tiffany participate in a knockout tournament consisting of a total of 32 players. In each of 5 rounds, the remaining players are paired uniformly at random. In each pair, both players are equally likely to win, and the loser is knocked out of the tournament. The probability that Ava and Tiffany play each other during the tournament is $\frac{a}{b}$, where $a$ and $b$ are relatively prime positive integers. Compute $100 a+b$.
+Proposed by: Sheldon Kieren Tan
+Answer: 116
+Solution: Each match eliminates exactly one player, so exactly $32-1=31$ matches are played, each of which consists of a different pair of players. Among the $\binom{32}{2}=\frac{32 \cdot 31}{2}=496$ pairs of players, each pair is equally likely to play each other at some point during the tournament. Therefore, the probability that Ava and Tiffany form one of the 31 pairs of players that play each other is $\frac{31}{496}=\frac{1}{16}$, giving an answer of $100 \cdot 1+16=116$.
+3. Let $N$ be a positive integer. Brothers Michael and Kylo each select a positive integer less than or equal to $N$, independently and uniformly at random. Let $p_{N}$ denote the probability that the product of these two integers has a units digit of 0 . The maximum possible value of $p_{N}$ over all possible choices of $N$ can be written as $\frac{a}{b}$, where $a$ and $b$ are relatively prime positive integers. Compute $100 a+b$.
+Proposed by: James Lin
+Answer: 2800
+Solution: For $k \in\{2,5,10\}$, let $q_{k}=\frac{\lfloor N / k\rfloor}{N}$ be the probability that an integer chosen uniformly at random from $[N]$ is a multiple of $k$. Clearly, $q_{k} \leq \frac{1}{k}$, with equality iff $k$ divides $N$.
+The product of $p_{1}, p_{2} \in[N]$ can be a multiple of 10 in two ways:
+
+- one of them is a multiple of 10 ; this happens with probability $q_{10}\left(2-q_{10}\right)$;
+- one of them is a multiple of 2 (but not 5 ) and the other is a multiple of 5 (but not 2 ); this happens with probability $2\left(q_{2}-q_{10}\right)\left(q_{5}-q_{10}\right)$.
+
+This gives
+
+$$
+\begin{aligned}
+p_{N} & =q_{10} \cdot\left(2-q_{10}\right)+2\left(q_{2}-q_{10}\right)\left(q_{5}-q_{10}\right) \\
+& \leq q_{10} \cdot\left(2-q_{10}\right)+2\left(\frac{1}{2}-q_{10}\right)\left(\frac{1}{5}-q_{10}\right) \\
+& =\frac{1}{5}\left(1+3 q_{10}+5 q_{10}^{2}\right) \\
+& \leq \frac{1}{5}\left(1+\frac{3}{10}+\frac{5}{100}\right) \\
+& =\frac{27}{100}
+\end{aligned}
+$$
+
+and equality holds iff $N$ is a multiple of 10 .
+4. Let $S=\{1,2, \ldots, 9\}$. Compute the number of functions $f: S \rightarrow S$ such that, for all $s \in S, f(f(f(s)))=$ $s$ and $f(s)-s$ is not divisible by 3.
+Proposed by: James Lin
+Answer: 288
+Solution: Since $f(f(f(s)))=s$ for all $s \in S$, each cycle in the cycle decomposition of $f$ must have length 1 or 3 . Also, since $f(s) \not \equiv s \bmod 3$ for all $s \in S$, each cycle cannot contain two elements $a, b$ such that $a=b \bmod 3$. Hence each cycle has exactly three elements, one from each of residue classes mod 3 .
+In particular, $1,4,7$ belong to distinct cycles. There are $6 \cdot 3$ ways to choose two other numbers in the cycle containing 1 . Then, there are $4 \cdot 2$ ways to choose two other numbers in the cycle containing 4 . Finally, there are $2 \cdot 1$ ways to choose two other numbers in the cycle containing 7 . Hence the desired number of functions $f$ is $6 \cdot 3 \cdot 4 \cdot 2 \cdot 2 \cdot 1=288$.
+5. Teresa the bunny has a fair 8 -sided die. Seven of its sides have fixed labels $1,2, \ldots, 7$, and the label on the eighth side can be changed and begins as 1 . She rolls it several times, until each of $1,2, \ldots, 7$ appears at least once. After each roll, if $k$ is the smallest positive integer that she has not rolled so far, she relabels the eighth side with $k$. The probability that 7 is the last number she rolls is $\frac{a}{b}$, where $a$ and $b$ are relatively prime positive integers. Compute $100 a+b$.
+Proposed by: Milan Haiman
+Answer: 104
+Solution 1: Let $n=7$ and $p=\frac{1}{4}$.
+Let $q_{k}$ be the probability that $n$ is the last number rolled, if $k$ numbers less than $n$ have already been rolled. We want $q_{0}$ and we know $q_{n-1}=1$.
+We have the relation
+
+$$
+q_{k}=(1-p) \frac{k}{n-1} q_{k}+\left[1-(1-p) \frac{k+1}{n-1}\right] q_{k+1}
+$$
+
+This rearranges to
+
+$$
+\left[1-(1-p) \frac{k}{n-1}\right] q_{k}=\left[1-(1-p) \frac{k+1}{n-1}\right] q_{k+1}
+$$
+
+This means that the expression on the LHS does not depend on $k$, so
+
+$$
+[1-0] \cdot q_{0}=[1-(1-p)] \cdot q_{n-1}=p
+$$
+
+Solution 2: For a given sequence of Teresa's rolls, let $x_{i}$ be the $i$ th distinct number rolled. We want to compute the probability that $x_{7}=7$.
+For a given index $i$, we say that $x_{i}$ is correct if $x_{i}$ is the least positive integer not in $\left\{x_{1}, \ldots, x_{i-1}\right\}$. Note that the probability of a given sequence $x_{1}, \ldots, x_{7}$ depends only on the number of correct $x_{i}$, since the probability of rolling the correct number on a given roll is higher by a factor of 2 .
+Now, suppose $x_{7}=7$. Consider $x_{i}^{\prime}=x_{i-1}+1$ for $10$. To see this, let $s \in S$ and consider
+
+$$
+s, f(s), f(f(s)), \ldots, f^{2021}(s)
+$$
+
+This sequence has 2022 terms that are all in $S$, so we must have a repeat. Suppose $f^{m}(s)=f^{n}(s)$ with $0 \leq n
March 06, 2021
Geometry Round
+
+1. A circle contains the points $(0,11)$ and $(0,-11)$ on its circumference and contains all points $(x, y)$ with $x^{2}+y^{2}<1$ in its interior. Compute the largest possible radius of the circle.
+Proposed by: Carl Schildkraut
+Answer: 61
+Solution: Such a circle will be centered at $(t, 0)$ for some $t$; without loss of generality, let $t>0$. Our conditions are that
+
+$$
+t^{2}+11^{2}=r^{2}
+$$
+
+and
+
+$$
+r \geq t+1
+$$
+
+So, $t^{2} \leq(r-1)^{2}$, which means
+
+$$
+(r-1)^{2}+11^{2} \geq r^{2} \Longrightarrow 122 \geq 2 r
+$$
+
+so our answer is $61(r=61$ is attainable with $t=60)$.
+2. Let $X_{0}$ be the interior of a triangle with side lengths 3,4 , and 5 . For all positive integers $n$, define $X_{n}$ to be the set of points within 1 unit of some point in $X_{n-1}$. The area of the region outside $X_{20}$ but inside $X_{21}$ can be written as $a \pi+b$, for integers $a$ and $b$. Compute $100 a+b$.
+Proposed by: Hahn Lheem
+Answer: 4112
+Solution:
+
+$X_{n}$ is the set of points within $n$ units of some point in $X_{0}$. The diagram above shows $X_{0}, X_{1}, X_{2}$, and $X_{3}$. As seen above it can be verified that $X_{n}$ is the union of
+
+- $X_{0}$,
+- three rectangles of height $n$ with the sides of $X_{0}$ as bases, and
+- three sectors of radius $n$ centered at the vertices and joining the rectangles
+
+Therefore the total area of $X_{n}$ is
+
+$$
+\left[X_{0}\right]+n \cdot \operatorname{perimeter}\left(X_{0}\right)+n^{2} \pi
+$$
+
+Since $X_{n-1}$ is contained entirely within $X_{n}$, the area within $X_{n}$ but not within $X_{n-1}$ is
+
+$$
+\text { perimeter }\left(X_{0}\right)+(2 n-1) \pi
+$$
+
+Since $X_{0}$ is a $(3,4,5)$ triangle, and $n=21$, this is $12+41 \pi$.
+3. Triangle $A B C$ has a right angle at $C$, and $D$ is the foot of the altitude from $C$ to $A B$. Points $L$, $M$, and $N$ are the midpoints of segments $A D, D C$, and $C A$, respectively. If $C L=7$ and $B M=12$, compute $B N^{2}$.
+Proposed by: Hahn Lheem
+Answer: 193
+Solution: Note that $C L, B M$, and $B N$ are corresponding segments in the similar triangles $\triangle A C D \sim$ $\triangle C B D \sim \triangle A B C$. So, we have
+
+$$
+C L: B M: B N=A D: C D: A C
+$$
+
+Since $A D^{2}+C D^{2}=A C^{2}$, we also have $C L^{2}+B M^{2}=B N^{2}$, giving an answer of $49+144=193$.
+4. Let $A B C D$ be a trapezoid with $A B \| C D, A B=5, B C=9, C D=10$, and $D A=7$. Lines $B C$ and $D A$ intersect at point $E$. Let $M$ be the midpoint of $C D$, and let $N$ be the intersection of the circumcircles of $\triangle B M C$ and $\triangle D M A$ (other than $M$ ). If $E N^{2}=\frac{a}{b}$ for relatively prime positive integers $a$ and $b$, compute $100 a+b$.
+Proposed by: Milan Haiman
+Answer: 90011
+Solution: From $\triangle E A B \sim \triangle E D C$ with length ratio $1: 2$, we have $E A=7$ and $E B=9$. This means that $A, B, M$ are the midpoints of the sides of $\triangle E C D$. Let $N^{\prime}$ be the circumcenter of $\triangle E C D$. Since $N^{\prime}$ is on the perpendicular bisectors of $E C$ and $C D$, we have $\angle N^{\prime} M C=\angle N^{\prime} B C=90^{\circ}$. Thus $N^{\prime}$ is on the circumcircle of $\triangle B M C$. Similarly, $N^{\prime}$ is on the circumcircle of $\triangle D M A$. As $N^{\prime} \neq M$, we must have $N^{\prime}=N$. So it suffices to compute $R^{2}$, where $R$ is the circumradius of $\triangle E C D$.
+We can compute $K=[\triangle E C D]$ to be $21 \sqrt{11}$ from Heron's formula, giving
+
+$$
+R=\frac{10 \cdot 14 \cdot 18}{4 K}=\frac{30}{\sqrt{11}}
+$$
+
+So $R^{2}=\frac{900}{11}$, and the final answer is 90011 .
+5. Let $A E F$ be a triangle with $E F=20$ and $A E=A F=21$. Let $B$ and $D$ be points chosen on segments $A E$ and $A F$, respectively, such that $B D$ is parallel to $E F$. Point $C$ is chosen in the interior of triangle $A E F$ such that $A B C D$ is cyclic. If $B C=3$ and $C D=4$, then the ratio of areas $\frac{[A B C D]}{[A E F]}$ can be written as $\frac{a}{b}$ for relatively prime positive integers $a, b$. Compute $100 a+b$.
+Proposed by: Akash Das
+Answer: 5300
+Solution 1: Rotate $\triangle A B C$ around $A$ to $\triangle A B^{\prime} C^{\prime}$, such that $B^{\prime}$ is on segment $A F$. Note that as $B D \| E F, A B=A D$. From this, $A B^{\prime}=A B=A D$, and $B^{\prime}=D$. Note that
+
+$$
+\angle A D C^{\prime}=\angle A B C=180-\angle A D C
+$$
+
+because $A B C D$ is cyclic. Therefore, $C, D$, and $C^{\prime}$ are collinear. Also, $A C^{\prime}=A C$, and
+
+$$
+\angle C A C^{\prime}=\angle D A C+\angle C^{\prime} A D=\angle D A C+\angle C A B=\angle E A F .
+$$
+
+Thus, since $A E=A F, \triangle A C C^{\prime} \sim \triangle A E F$. Now, we have
+
+$$
+\left[A C C^{\prime}\right]=[A C D]+\left[A D C^{\prime}\right]=[A C D]+[A B C]=[A B C D]
+$$
+
+But, $\left[A C C^{\prime}\right]=\frac{C C^{\prime 2}}{E F^{2}} \cdot[A E F]$, and we know that $C C^{\prime}=C D+D C^{\prime}=4+3=7$. Thus,
+
+$$
+\frac{[A B C D]}{[A E F]}=\frac{\left[A C C^{\prime}\right]}{[A E F]}=\frac{7^{2}}{20^{2}}=\frac{49}{400} .
+$$
+
+The answer is $100 \cdot 49+400=5300$.
+
+## Solution 2:
+
+
+
+Since $B D$ is parallel to $E F$ and $A E=A F$, we have $A B=A D$. Since $A B C D$ is cyclic, $\angle A B C+$ $\angle A D C=180^{\circ}$. Thus we can glue $\triangle A B C$ and $\triangle A D C$ as shown in the diagram above to create a triangle that is similar to $\triangle A E F$ and has the same area as $A B C D$. The base of this triangle has length $B C+C D=3+4=7$, so the desired ratio is
+
+$$
+\frac{7^{2}}{20^{2}}=\frac{49}{400}
+$$
+
+6. In triangle $A B C$, let $M$ be the midpoint of $B C, H$ be the orthocenter, and $O$ be the circumcenter. Let $N$ be the reflection of $M$ over $H$. Suppose that $O A=O N=11$ and $O H=7$. Compute $B C^{2}$.
+Proposed by: Milan Haiman
+Answer: 288
+Solution: Let $\omega$ be the circumcircle of $\triangle A B C$. Note that because $O N=O A, N$ is on $\omega$. Let $P$ be the reflection of $H$ over $M$. Then, $P$ is also on $\omega$. If $Q$ is the midpoint of $N P$, note that because
+
+$$
+N H=H M=M P,
+$$
+
+$Q$ is also the midpoint of $H M$. Since $O Q \perp N P$, we know that $O Q \perp H M$. As $Q$ is also the midpoint of $H M$,
+
+$$
+O M=O H=7
+$$
+
+With this,
+
+$$
+B M=\sqrt{O B^{2}-B M^{2}}=6 \sqrt{2}
+$$
+
+and $B C=2 B M=12 \sqrt{2}$. Therefore, $B C^{2}=288$.
+7. Let $O$ and $A$ be two points in the plane with $O A=30$, and let $\Gamma$ be a circle with center $O$ and radius $r$. Suppose that there exist two points $B$ and $C$ on $\Gamma$ with $\angle A B C=90^{\circ}$ and $A B=B C$. Compute the minimum possible value of $\lfloor r\rfloor$.
+
+## Proposed by: Hahn Lheem, Milan Haiman
+
+Answer: 12
+Solution: Let $f_{1}$ denote a $45^{\circ}$ counterclockwise rotation about point $A$ followed by a dilation centered $A$ with scale factor $1 / \sqrt{2}$. Similarly, let $f_{2}$ denote a $45^{\circ}$ clockwise rotation about point $A$ followed by a dilation centered $A$ with scale factor $1 / \sqrt{2}$. For any point $B$ in the plane, there exists a point $C$ on $\Gamma$ such that $\angle A B C=90^{\circ}$ and $A B=B C$ if and only if $B$ lies on $f_{1}(\Gamma)$ or $f_{2}(\Gamma)$. Thus, such points $B$ and $C$ on $\Gamma$ exist if and only if $\Gamma$ intersects $f_{1}(\Gamma)$ or $f_{2}(\Gamma)$. So, the minimum possible value of $r$ occurs when $\Gamma$ is tangent to $f_{1}(\Gamma)$ and $f_{2}(\Gamma)$. This happens when $r / \sqrt{2}+r=30 / \sqrt{2}$, i.e., when $r=\frac{30}{\sqrt{2}+1}=30 \sqrt{2}-30$. Therefore, the minimum possible value of $\lfloor r\rfloor$ is $\lfloor 30 \sqrt{2}-30\rfloor=12$.
+8. Two circles with radii 71 and 100 are externally tangent. Compute the largest possible area of a right triangle whose vertices are each on at least one of the circles.
+Proposed by: David Vulakh
+Answer: 24200
+Solution:
+
+
+In general, let the radii of the circles be $r
Guts Round
+
+1. [8] Amelia wrote down a sequence of consecutive positive integers, erased one integer, and scrambled the rest, leaving the sequence below. What integer did she erase?
+
+$$
+6,12,1,3,11,10,8,15,13,9,7,4,14,5,2
+$$
+
+Proposed by: Andrew Gu
+Answer: 16
+Solution: The sequence of positive integers exactly contains every integer between 1 and 15 , inclusive. 16 is the only positive integer that could be added to this sequence such that the resulting sequence could be reordered to make a sequence of consecutive positive integers. Therefore, Amelia must have erased the integer 16 .
+2. [8] Suppose there exists a convex $n$-gon such that each of its angle measures, in degrees, is an odd prime number. Compute the difference between the largest and smallest possible values of $n$.
+Proposed by: Andrew Gu
+Answer: 356
+Solution: We can't have $n=3$ since the sum of the angles must be $180^{\circ}$ but the sum of three odd numbers is odd. On the other hand, for $n=4$ we can take a quadrilateral with angle measures $83^{\circ}, 83^{\circ}, 97^{\circ}, 97^{\circ}$.
+The largest possible value of $n$ is 360 . For larger $n$ we can't even have all angles have integer measure, and 179 happens to be prime.
+So, the answer is $360-4=356$.
+3. [8] A semicircle with radius 2021 has diameter $A B$ and center $O$. Points $C$ and $D$ lie on the semicircle such that $\angle A O C<\angle A O D=90^{\circ}$. A circle of radius $r$ is inscribed in the sector bounded by $O A$ and $O C$ and is tangent to the semicircle at $E$. If $C D=C E$, compute $\lfloor r\rfloor$.
+Proposed by: Hahn Lheem
+Answer: 673
+Solution: We are given
+
+$$
+m \angle E O C=m \angle C O D
+$$
+
+and
+
+$$
+m \angle A O C+m \angle C O D=2 m \angle E O C+m \angle C O D=90^{\circ} .
+$$
+
+So $m \angle E O C=30^{\circ}$ and $m \angle A O C=60^{\circ}$. Letting the radius of the semicircle be $R$, we have
+
+$$
+(R-r) \sin \angle A O C=r \Rightarrow r=\frac{1}{3} R
+$$
+
+so
+
+$$
+\lfloor r\rfloor=\left\lfloor\frac{2021}{3}\right\rfloor=673
+$$
+
+4. [8] In a 3 by 3 grid of unit squares, an up-right path is a path from the bottom left corner to the top right corner that travels only up and right in steps of 1 unit. For such a path $p$, let $A_{p}$ denote the number of unit squares under the path $p$. Compute the sum of $A_{p}$ over all up-right paths $p$.
+Proposed by: Freddie Zhao
+Answer: 90
+Solution: Each path consists of 3 steps up and 3 steps to the right, so there are $\binom{6}{3}=20$ total paths. Consider the sum of the areas of the regions above all of these paths. By symmetry, this is the same as the answer to the problem. For any path, the sum of the areas of the regions above and below it is $3^{2}=9$, so the sum of the areas of the regions above and below all paths is $9 \cdot 20=180$. Therefore, our final answer is $\frac{1}{2} \cdot 180=90$.
+5. [9] Let $m, n>2$ be integers. One of the angles of a regular $n$-gon is dissected into $m$ angles of equal size by $(m-1)$ rays. If each of these rays intersects the polygon again at one of its vertices, we say $n$ is $m$-cut. Compute the smallest positive integer $n$ that is both 3 -cut and 4 -cut.
+Proposed by: Carl Schildkraut
+Answer: 14
+Solution: For the sake of simplicity, inscribe the regular polygon in a circle. Note that each interior angle of the regular $n$-gon will subtend $n-2$ of the $n$ arcs on the circle. Thus, if we dissect an interior angle into $m$ equal angles, then each must be represented by a total of $\frac{n-2}{m}$ arcs. However, since each of the rays also passes through another vertex of the polygon, that means $\frac{n-2}{m}$ is an integer and thus our desired criteria is that $m$ divides $n-2$.
+That means we want the smallest integer $n>2$ such that $n-2$ is divisible by 3 and 4 which is just $12+2=14$.
+6. [9] In a group of 50 children, each of the children in the group have all of their siblings in the group. Each child with no older siblings announces how many siblings they have; however, each child with an older sibling is too embarrassed, and says they have 0 siblings.
+If the average of the numbers everyone says is $\frac{12}{25}$, compute the number of different sets of siblings represented in the group.
+Proposed by: Vincent Bian
+Answer: 26
+Solution: For $i \geq 1$, let $a_{i}$ be the number of families that have $i$ members in the group. Then, among each family with $i$ children in the group, the oldest child will say $i-1$, and the rest will say 0 . Thus, the sum of all the numbers said will be $a_{2}+2 a_{3}+3 a_{4}+4 a_{5}+\cdots=50 \times \frac{12}{25}=24$.
+Also because there are 50 children total, we know that $a_{1}+2 a_{2}+3 a_{3}+\cdots=50$. We can subtract these two equations to get $a_{1}+a_{2}+a_{3}+\cdots=50-24=26$.
+7. [9] Milan has a bag of 2020 red balls and 2021 green balls. He repeatedly draws 2 balls out of the bag uniformly at random. If they are the same color, he changes them both to the opposite color and returns them to the bag. If they are different colors, he discards them. Eventually the bag has 1 ball left. Let $p$ be the probability that it is green. Compute $\lfloor 2021 p\rfloor$.
+Proposed by: Milan Haiman
+Answer: 2021
+Solution: The difference between the number of green balls and red balls in the bag is always 1 modulo 4 . Thus the last ball must be green and $p=1$.
+8. [9] Compute the product of all positive integers $b \geq 2$ for which the base $b$ number $111111_{b}$ has exactly $b$ distinct prime divisors.
+Proposed by: Esha Bhatia
+Answer: 24
+Solution: Notice that this value, in base $b$, is
+
+$$
+\frac{b^{6}-1}{b-1}=(b+1)\left(b^{2}-b+1\right)\left(b^{2}+b+1\right)
+$$
+
+This means that, if $b$ satisfies the problem condition, $(b+1)\left(b^{2}-b+1\right)\left(b^{2}+b+1\right)>p_{1} \ldots p_{b}$, where $p_{i}$ is the $i$ th smallest prime.
+We claim that, if $b \geq 7$, then $p_{1} \ldots p_{b}>(b+1)\left(b^{2}-b+1\right)\left(b^{2}+b+1\right)$. This is true for $b=7$ by calculation, and can be proven for larger $b$ by induction and the estimate $p_{i} \geq i$.
+All we have to do is to check $b \in 2,3,4,5,6$. Notice that for $b=6$, the primes cannot include 2,3 and hence we want $\frac{6^{6}-1}{5}$ to be divisible product of 6 primes the smallest of which is 5 . However, $5 \cdot 7 \cdots 17>\frac{6^{6}-1}{5}$, and by checking we rule out 5 too. All that is left is $\{2,3,4\}$, all of which work, giving us an answer of 24 .
+9. [10] Let $A D, B E$, and $C F$ be segments sharing a common midpoint, with $A Ba_{j}+2$. Then, increasing $a_{j}$ by 1 and decreasing $a_{j+1}$ by 1 will increase the product
+$M$, contradicting the assumption that the sequence has the optimal product. Thus, any "gaps" in the $a_{i}$ can only have size 1 .
+Now, we show that there can only be one such gap. Suppose $a_{j+1}=a_{j}+2$, and $a_{k+1}=a_{k}+2$, for $j