For a positive integer $m$, let $S(m)$ and $P(m)$ be the sum and product of its digits. Show that for every positive integer $n$ there exist positive integers $a_1,\ldots,a_n$ such that
$$S(a_1)\lt S(a_2)\lt \cdots\lt S(a_n),\qquad S(a_i)=P(a_{i+1})\quad(1\le i\le n),$$
where $a_{n+1}=a_1$.
Proposed by the Problem Committee of the Japan Mathematical Olympiad Foundation.
Let $S=\{1,2,\ldots,2014\}$. Choose one member of each nonempty subset $T\subseteq S$ as its representative. Count the assignments such that whenever $D$ is a disjoint union of three nonempty subsets $A,B,C$, the representative of $D$ is also the representative of at least one of $A,B,C$.
For positive integers $n,b$, say that $n$ is $b$-discerning if there is a set of $n$ distinct positive integers less than $b$ whose different subsets always have different sums.
(a) Prove that 8 is 100-discerning.
(b) Prove that 9 is not 100-discerning.
Proposed by the Senior Problems Committee of the Australian Mathematical Olympiad Committee.
Circles $\omega$ and $\Omega$ meet at $A,B$. Let $M$ be the midpoint of the arc $AB$ of $\omega$ lying inside $\Omega$. A chord $MP$ of $\omega$ intersects $\Omega$ at $Q$ inside $\omega$. Let $\ell_P$ be the tangent to $\omega$ at $P$ and $\ell_Q$ the tangent to $\Omega$ at $Q$. Prove that the circumcircle of the triangle formed by $\ell_P,\ell_Q,AB$ is tangent to $\Omega$.
Proposed by Ilya Bogdanov, Russia, and Medeubek Kungozhin, Kazakhstan.