Navvye/Olympiad-Problems-CSV huggingface dataset:
Problem: A permutation of the set of positive integers $[n] = \{1, 2, \ldots, n\}$ is a sequence $(a_1, a_2, \ldots, a_n)$ such that each element of $[n]$ appears precisely one time as a term of the sequence. For example, $(3, 5, 1, 2, 4)$ is a permutation of $[5]$ . Let $P(n)$ be the number of permutations of $[n]$ for which $ka_k$ is a perfect square for all $1\leq k\leq n$ . Find with proof the smallest $n$ such that $P(n)$ is a multiple of $2010$

Solution: It's well known that there exists $f(n)$ and $g(n)$ such that $n = f(n) \cdot g(n)$ , no square divides $f(n)$ other than 1, and $g(n)$ is a perfect square.
We prove first: If $f(k) = f(a_k)$ $k \cdot a_k$ is a perfect square.
$k \cdot a_k = f(k) \cdot g(k) \cdot f(a_k) \cdot g(a_k) = f(k)^2 \cdot g(k) \cdot g(a_k)$ , which is a perfect square.
We will now prove: If $k \cdot a_k$ is a perfect square, $f(k) = f(a_k)$
We do proof by contrapositive: If $f(k) \neq f(a_k)$ $k \cdot a_k$ is not a perfect square.
$v_p(k)$ is the p-adic valuation of k. (Basically how many factors of p you can take out of k)
Note that if $f(k) \neq f(a_k)$ , By the Fundamental Theorem of Arithmetic, $f(k)$ and $f(a_k)$ 's prime factorization are different, and thus there exists a prime p, such that $v_p(f(k)) \neq v_p(f(a_k))$ . Also, since $f(k)$ and $f(a_k)$ is squarefree, $v_p(k), v_p(a_k) \leq 1$ . Thus, $v_p(k \cdot a_k) = 1$ , making $k \cdot a_k$ not a square.
Thus, we can only match k with $a_k$ if they have the same f value. Thus, to find P(k), we can do it by f value, permuting the $a_k$ with f value 1, then 2, ... Thus, our answer is:
$P(n) = \prod_{1 \leq i \leq n, g(i) = 1} \left\lfloor \sqrt{\frac{n}{i}} \right \rfloor !$
For all $n < 67^2$ $P(n)$ doesn't have a factor of 67. However, if $n = 67^2$ , the first term will be a multiple of 2010, and thus the answer is $67^2 = \boxed{4489}$

Answer:  4489
Problem: Cities $A$ and $B$ are $45$ miles apart. Alicia lives in $A$ and Beth lives in $B$ . Alicia bikes towards $B$ at 18 miles per hour. Leaving at the same time, Beth bikes toward $A$ at 12 miles per hour. How many miles from City $A$ will they be when they meet? $\textbf{(A) }20\qquad\textbf{(B) }24\qquad\textbf{(C) }25\qquad\textbf{(D) }26\qquad\textbf{(E) }27$

Solution: This is a $d=st$ problem, so let $x$ be the time it takes to meet. We can write the following equation: \[12x+18x=45\] Solving gives us $x=1.5$ . The $18x$ is Alicia so $18\times1.5=\boxed{27}$

Answer: E 27
Problem: Cities $A$ and $B$ are $45$ miles apart. Alicia lives in $A$ and Beth lives in $B$ . Alicia bikes towards $B$ at 18 miles per hour. Leaving at the same time, Beth bikes toward $A$ at 12 miles per hour. How many miles from City $A$ will they be when they meet? $\textbf{(A) }20\qquad\textbf{(B) }24\qquad\textbf{(C) }25\qquad\textbf{(D) }26\qquad\textbf{(E) }27$

Solution: The relative speed of the two is $18+12=30$ , so $\frac{3}{2}$ hours would be required to travel $45$ miles. $d=st$ , so $x=18\cdot\frac{3}{2}=\boxed{27}$

Answer: E 27
Problem: Cities $A$ and $B$ are $45$ miles apart. Alicia lives in $A$ and Beth lives in $B$ . Alicia bikes towards $B$ at 18 miles per hour. Leaving at the same time, Beth bikes toward $A$ at 12 miles per hour. How many miles from City $A$ will they be when they meet? $\textbf{(A) }20\qquad\textbf{(B) }24\qquad\textbf{(C) }25\qquad\textbf{(D) }26\qquad\textbf{(E) }27$

Solution: Since $18$ mph is $\frac{3}{2}$ times $12$ mph, Alicia will travel $\frac{3}{2}$ times as far as Beth. If $x$ is the distance Beth travels, \[\frac{3}{2}x+x=45\] \[\frac{5}{2}x=45\] \[x=18\] Since this is the amount Beth traveled, the amount that Alicia traveled was \[45-18=\boxed{27}\]

Answer: E 27
Problem: Cities $A$ and $B$ are $45$ miles apart. Alicia lives in $A$ and Beth lives in $B$ . Alicia bikes towards $B$ at 18 miles per hour. Leaving at the same time, Beth bikes toward $A$ at 12 miles per hour. How many miles from City $A$ will they be when they meet? $\textbf{(A) }20\qquad\textbf{(B) }24\qquad\textbf{(C) }25\qquad\textbf{(D) }26\qquad\textbf{(E) }27$

Solution: Alice and Barbara close in on each other at 30mph. Since they are 45 miles apart, they will meet in t = d/s = 45miles / 30mph = 3/2 hours. We can either calculate the distance Alice travels at 18mph or the distance Barbara travels at 12mph; since we want the distance from Alice, we go with the former. Alice (and Barbara) will meet in 1 1/2 hours at 18mph x 3/2 hours = 27 miles from A. $\boxed{27}$

Answer: E 27
Problem: Cities $A$ and $B$ are $45$ miles apart. Alicia lives in $A$ and Beth lives in $B$ . Alicia bikes towards $B$ at 18 miles per hour. Leaving at the same time, Beth bikes toward $A$ at 12 miles per hour. How many miles from City $A$ will they be when they meet? $\textbf{(A) }20\qquad\textbf{(B) }24\qquad\textbf{(C) }25\qquad\textbf{(D) }26\qquad\textbf{(E) }27$

Solution: We know that Beth starts 45 miles away from City A, let’s create two equations:
Alice-> $18t=d$ Beth-> $-12t+45=d$ [-12 is the slope; 45 is the y-intercept]
Solve the system:
$18t=-12t+45 30t=45 t=1.5$
So, $18(1.5)=$ $\boxed{27}$

Answer: E 27
Problem: Cities $A$ and $B$ are $45$ miles apart. Alicia lives in $A$ and Beth lives in $B$ . Alicia bikes towards $B$ at 18 miles per hour. Leaving at the same time, Beth bikes toward $A$ at 12 miles per hour. How many miles from City $A$ will they be when they meet? $\textbf{(A) }20\qquad\textbf{(B) }24\qquad\textbf{(C) }25\qquad\textbf{(D) }26\qquad\textbf{(E) }27$

Solution: Since Alicia and Beth's speeds are constant, they are directly proportional to their distances covered, so the ratio of their speeds is equal to the ratio of their covered distances. Since Alicia travels $\frac{18}{30} = \frac{3}{5}$ of their combined speed, she travels $\frac{3}{5}\cdot 45 = \boxed{27}$ of the total distance.

Answer: E 27
Problem: How many positive perfect squares less than $2023$ are divisible by $5$
$\textbf{(A) } 8 \qquad\textbf{(B) }9 \qquad\textbf{(C) }10 \qquad\textbf{(D) }11 \qquad\textbf{(E) } 12$

Solution: Note that $40^2=1600$ but $45^{2}=2025$ (which is over our limit of $2023$ ). Therefore, the list is $5^2,10^2,15^2,20^2,25^2,30^2,35^2,40^2$ . There are $8$ elements, so the answer is $\boxed{8}$

Answer: A 8
Problem: How many positive perfect squares less than $2023$ are divisible by $5$
$\textbf{(A) } 8 \qquad\textbf{(B) }9 \qquad\textbf{(C) }10 \qquad\textbf{(D) }11 \qquad\textbf{(E) } 12$

Solution: Since $\left \lfloor{\sqrt{2023}}\right \rfloor = 44$ , there are $\left \lfloor{\frac{44}{5}}\right \rfloor = \boxed{8}$ perfect squares less than 2023.

Answer: A 8
Problem: How many positive perfect squares less than $2023$ are divisible by $5$
$\textbf{(A) } 8 \qquad\textbf{(B) }9 \qquad\textbf{(C) }10 \qquad\textbf{(D) }11 \qquad\textbf{(E) } 12$

Solution: Since $5$ is prime, each solution must be divisible by $5^2=25$ . We take $\left \lfloor{\frac{2023}{25}}\right \rfloor = 80$ and see that there are $\boxed{8}$ positive perfect squares no greater than $80$

Answer: A 8
Problem: How many positive perfect squares less than $2023$ are divisible by $5$
$\textbf{(A) } 8 \qquad\textbf{(B) }9 \qquad\textbf{(C) }10 \qquad\textbf{(D) }11 \qquad\textbf{(E) } 12$

Solution: We know the highest value would be at least $40$ but less than $50$ so we check $45$ , prime factorizing 45. We get $3^2 \cdot 5$ . We square this and get $81 \cdot 25$ . We know that $80 \cdot 25 = 2000$ , then we add 25 and get $2025$ , which does not satisfy our requirement of having the square less than $2023$ . The largest multiple of $5$ that satisfies this is $40$ and the smallest multiple of $5$ that works is $5$ so all multiples of $5$ from $5$ to $40$ satisfy the requirements. Now we divide each element of the set by $5$ and get $1-8$ so there are $\boxed{8}$ solutions.

Answer: A 8
Problem: A quadrilateral has all integer sides lengths, a perimeter of $26$ , and one side of length $4$ . What is the greatest possible length of one side of this quadrilateral?
$\textbf{(A) }9\qquad\textbf{(B) }10\qquad\textbf{(C) }11\qquad\textbf{(D) }12\qquad\textbf{(E) }13$

Solution: Let's use the triangle inequality. We know that for a triangle, the sum of the 2 shorter sides must always be longer than the longest side. This is because if the longest side were to be as long as the sum of the other sides, or longer, we would only have a line.
Similarly, for a convex quadrilateral, the sum of the shortest 3 sides must always be longer than the longest side. Thus, the answer is $\frac{26}{2}-1=13-1=\boxed{12}$

Answer: D 12
Problem: A quadrilateral has all integer sides lengths, a perimeter of $26$ , and one side of length $4$ . What is the greatest possible length of one side of this quadrilateral?
$\textbf{(A) }9\qquad\textbf{(B) }10\qquad\textbf{(C) }11\qquad\textbf{(D) }12\qquad\textbf{(E) }13$

Solution: Say the chosen side is $a$ and the other sides are $b,c,d$
By the Generalised Polygon Inequality, $a<b+c+d$ . We also have $a+b+c+d=26\Rightarrow b+c+d=26-a$
Combining these two, we get $a<26-a\Rightarrow a<13$
The largest length that satisfies this is $a=\boxed{12}$

Answer: D 12
Problem: A quadrilateral has all integer sides lengths, a perimeter of $26$ , and one side of length $4$ . What is the greatest possible length of one side of this quadrilateral?
$\textbf{(A) }9\qquad\textbf{(B) }10\qquad\textbf{(C) }11\qquad\textbf{(D) }12\qquad\textbf{(E) }13$

Solution: The quadrilateral can by cyclic only when it is an isosceles triangle. Without Loss of Generality, lets assume that this quadrilateral is a trapezoid. We can assume this as if we inscribe a trapezoid in a triangle, the base can be the diameter of the circle which is the longest chord in the circle, therefore maximizing the side length. By Brahmagupta's Formula, the area of the quadrilateral is defined by $\sqrt{(s-a)(s-b)(s-c)(s-d)}$ where $s$ is the semi-perimeter. If the perimeter of the quadrilateral is $26$ , then the semi-perimeter will be $13$ . The area of the quadrilateral must be positive so the difference between the semi-perimeter and a side length must be greater than $0$ as otherwise, the area will be $0$ or negative. Therefore, the longest a side can be in this quadrilateral is $\boxed{12}$

Answer: D 12
Problem: A quadrilateral has all integer sides lengths, a perimeter of $26$ , and one side of length $4$ . What is the greatest possible length of one side of this quadrilateral?
$\textbf{(A) }9\qquad\textbf{(B) }10\qquad\textbf{(C) }11\qquad\textbf{(D) }12\qquad\textbf{(E) }13$

Solution: This is an AMC 10 problem 4, so there is no need for any complex formulas. The largest singular side length from a quadrilateral comes from a trapezoid. So we can set the $2$ sides of the trapezoid equal to $4$ . Next we can split the trapezoid into $5$ triangles, where each base length of the triangle equals $4$ . So the top side equals $8$ , and the bottom side length equals $4+4+4$ $=$ $\boxed{12}$ ~ kabbybear

Answer: D 12
Problem: How many digits are in the base-ten representation of $8^5 \cdot 5^{10} \cdot 15^5$
$\textbf{(A)}~14\qquad\textbf{(B)}~15\qquad\textbf{(C)}~16\qquad\textbf{(D)}~17\qquad\textbf{(E)}~18\qquad$

Solution: Prime factorizing this gives us $2^{15}\cdot3^{5}\cdot5^{15}=10^{15}\cdot3^5=243\cdot10^{15}$
$10^{15}$ gives us $15$ digits and $243$ gives us $3$ digits. $15+3=\text{\boxed{18}$

Answer: E 18
Problem: How many digits are in the base-ten representation of $8^5 \cdot 5^{10} \cdot 15^5$
$\textbf{(A)}~14\qquad\textbf{(B)}~15\qquad\textbf{(C)}~16\qquad\textbf{(D)}~17\qquad\textbf{(E)}~18\qquad$

Solution: Multiplying it out, we get that $8^5 \cdot 5^{10} \cdot 15^5 = 243000000000000000$ . Counting, we have the answer is $\text{\boxed{18}$ ~andliu766

Answer: E 18
Problem: An integer is assigned to each vertex of a cube. The value of an edge is defined to be the sum of the values of the two vertices it touches, and the value of a face is defined to be the sum of the values of the four edges surrounding it. The value of the cube is defined as the sum of the values of its six faces. Suppose the sum of the integers assigned to the vertices is $21$ . What is the value of the cube? $\textbf{(A) } 42 \qquad \textbf{(B) } 63 \qquad \textbf{(C) } 84 \qquad \textbf{(D) } 126 \qquad \textbf{(E) } 252$

Solution: Each of the vertices is counted $3$ times because each vertex is shared by three different edges. 
Each of the edges is counted $2$ times because each edge is shared by two different faces. 
Since the sum of the integers assigned to all vertices is $21$ , the final answer is $21\times3\times2=\boxed{126}$

Answer: D 126
Problem: An integer is assigned to each vertex of a cube. The value of an edge is defined to be the sum of the values of the two vertices it touches, and the value of a face is defined to be the sum of the values of the four edges surrounding it. The value of the cube is defined as the sum of the values of its six faces. Suppose the sum of the integers assigned to the vertices is $21$ . What is the value of the cube? $\textbf{(A) } 42 \qquad \textbf{(B) } 63 \qquad \textbf{(C) } 84 \qquad \textbf{(D) } 126 \qquad \textbf{(E) } 252$

Solution: Note that each vertex is counted $2\times 3=6$ times. Thus, the answer is $21\times6=\boxed{126}$

Answer: D 126
Problem: An integer is assigned to each vertex of a cube. The value of an edge is defined to be the sum of the values of the two vertices it touches, and the value of a face is defined to be the sum of the values of the four edges surrounding it. The value of the cube is defined as the sum of the values of its six faces. Suppose the sum of the integers assigned to the vertices is $21$ . What is the value of the cube? $\textbf{(A) } 42 \qquad \textbf{(B) } 63 \qquad \textbf{(C) } 84 \qquad \textbf{(D) } 126 \qquad \textbf{(E) } 252$

Solution: Just set one vertice equal to $21$ , it is trivial to see that there are $3$ faces with value $42$ , and $42 \cdot 3=\boxed{126}$

Answer: D 126
Problem: An integer is assigned to each vertex of a cube. The value of an edge is defined to be the sum of the values of the two vertices it touches, and the value of a face is defined to be the sum of the values of the four edges surrounding it. The value of the cube is defined as the sum of the values of its six faces. Suppose the sum of the integers assigned to the vertices is $21$ . What is the value of the cube? $\textbf{(A) } 42 \qquad \textbf{(B) } 63 \qquad \textbf{(C) } 84 \qquad \textbf{(D) } 126 \qquad \textbf{(E) } 252$

Solution: Since there are 8 vertices in a cube, there are $\dfrac{21}4$ vertices for two edges. There are $4$ edges per face, and $6$ faces in a cube, so the value of the cube is $\dfrac{21}4 \cdot 24 = \boxed{126}$

Answer: D 126
Problem: An integer is assigned to each vertex of a cube. The value of an edge is defined to be the sum of the values of the two vertices it touches, and the value of a face is defined to be the sum of the values of the four edges surrounding it. The value of the cube is defined as the sum of the values of its six faces. Suppose the sum of the integers assigned to the vertices is $21$ . What is the value of the cube? $\textbf{(A) } 42 \qquad \textbf{(B) } 63 \qquad \textbf{(C) } 84 \qquad \textbf{(D) } 126 \qquad \textbf{(E) } 252$

Solution: Set each vertex to value 1, so the sum of the vertices is 8. We find that the value of the cube, if all vertices are 1, is 48. We conclude that the value of the cube is 6 times the value of the sum of the vertices. Therefore, we choose $21\times6=\boxed{126}$

Answer: D 126
Problem: An integer is assigned to each vertex of a cube. The value of an edge is defined to be the sum of the values of the two vertices it touches, and the value of a face is defined to be the sum of the values of the four edges surrounding it. The value of the cube is defined as the sum of the values of its six faces. Suppose the sum of the integers assigned to the vertices is $21$ . What is the value of the cube? $\textbf{(A) } 42 \qquad \textbf{(B) } 63 \qquad \textbf{(C) } 84 \qquad \textbf{(D) } 126 \qquad \textbf{(E) } 252$

Solution: The wording of the problem implies that the answer should hold for any valid combination of integers. Thus, we choose the numbers $21, 0, 0, 0, 0, 0, 0, 0$ , which are indeed $8$ integers that add to $21$ . Doing this, we find three edges that have a value of $21$ , and from there, we get three faces with a value of $42$ (while the other three faces have a value of $0$ ). Adding the three faces together, we get $42+42+42 = \boxed{126}$

Answer: D 126
Problem: Barb the baker has developed a new temperature scale for her bakery called the Breadus scale, which is a linear function of the Fahrenheit scale. Bread rises at $110$ degrees Fahrenheit, which is $0$ degrees on the Breadus scale. Bread is baked at $350$ degrees Fahrenheit, which is $100$ degrees on the Breadus scale. Bread is done when its internal temperature is $200$ degrees Fahrenheit. What is this in degrees on the Breadus scale?
$\textbf{(A) }33\qquad\textbf{(B) }34.5\qquad\textbf{(C) }36\qquad\textbf{(D) }37.5\qquad\textbf{(E) }39$

Solution: To solve this question, you can use $y = mx + b$ where the $x$ is Fahrenheit and the $y$ is Breadus. We have $(110,0)$ and $(350,100)$ . We want to find the value of $y$ in $(200,y)$ that falls on this line. The slope for these two points is $\frac{5}{12}$ $y = \frac{5}{12}x + b$ . Solving for $b$ using $(110, 0)$ $\frac{550}{12} = -b$ . We get $b = \frac{-275}{6}$ . Plugging in $(200, y), \frac{1000}{12}-\frac{550}{12}=y$ . Simplifying, $\frac{450}{12} = \boxed{37.5}$

Answer: D 37.5
Problem: Barb the baker has developed a new temperature scale for her bakery called the Breadus scale, which is a linear function of the Fahrenheit scale. Bread rises at $110$ degrees Fahrenheit, which is $0$ degrees on the Breadus scale. Bread is baked at $350$ degrees Fahrenheit, which is $100$ degrees on the Breadus scale. Bread is done when its internal temperature is $200$ degrees Fahrenheit. What is this in degrees on the Breadus scale?
$\textbf{(A) }33\qquad\textbf{(B) }34.5\qquad\textbf{(C) }36\qquad\textbf{(D) }37.5\qquad\textbf{(E) }39$

Solution: Let $^\circ B$ denote degrees Breadus. We notice that $200^\circ F$ is $90^\circ F$ degrees to $0^\circ B$ , and $150^\circ F$ to $100^\circ B$ . This ratio is $90:150=3:5$ ; therefore, $200^\circ F$ will be $\dfrac3{3+5}=\dfrac38$ of the way from $0$ to $100$ , which is $\boxed{37.5.}$

Answer: D 37.5.
Problem: Barb the baker has developed a new temperature scale for her bakery called the Breadus scale, which is a linear function of the Fahrenheit scale. Bread rises at $110$ degrees Fahrenheit, which is $0$ degrees on the Breadus scale. Bread is baked at $350$ degrees Fahrenheit, which is $100$ degrees on the Breadus scale. Bread is done when its internal temperature is $200$ degrees Fahrenheit. What is this in degrees on the Breadus scale?
$\textbf{(A) }33\qquad\textbf{(B) }34.5\qquad\textbf{(C) }36\qquad\textbf{(D) }37.5\qquad\textbf{(E) }39$

Solution: From $110$ to $350$ degrees Fahrenheit, the Breadus scale goes from $1$ to $100$ $110$ to $350$ degrees is a span of $240$ , and we can use this to determine how many Fahrenheit each Breadus unit is worth. $240$ divided by $100$ is $2.4$ , so each Breadus unit is $2.4$ Fahrenheit, starting at $110$ Fahrenheit. For example, $1$ degree on the Breadus scale is $110 + 2.4$ , or $112.4$ Fahrenheit. Using this information, we can figure out how many Breadus degrees $200$ Fahrenheit is. $200-110$ is $90$ , so we divide $90$ by $2.4$ to find the answer, which is $\boxed{37.5}$

Answer: D 37.5
Problem: Barb the baker has developed a new temperature scale for her bakery called the Breadus scale, which is a linear function of the Fahrenheit scale. Bread rises at $110$ degrees Fahrenheit, which is $0$ degrees on the Breadus scale. Bread is baked at $350$ degrees Fahrenheit, which is $100$ degrees on the Breadus scale. Bread is done when its internal temperature is $200$ degrees Fahrenheit. What is this in degrees on the Breadus scale?
$\textbf{(A) }33\qquad\textbf{(B) }34.5\qquad\textbf{(C) }36\qquad\textbf{(D) }37.5\qquad\textbf{(E) }39$

Solution: We note that the range of F temperatures that $0-100$ $\text{Br}^\circ$ represents is $350-110 = 240$ $\text{F}^\circ$ $200$ $\text{F}^\circ$ is $(200-110) = 90$ $\text{F}^\circ$ along the way to getting to $240$ $\text{F}^\circ$ , the end of this range, or $90/240 = 9/24 = 3/8 = 0.375$ of the way. Therefore if we switch to the Br scale, we are $0.375$ of the way to $100$ from $0$ , or at $\boxed{37.5}^\circ$

Answer: D 37.5
Problem: Barb the baker has developed a new temperature scale for her bakery called the Breadus scale, which is a linear function of the Fahrenheit scale. Bread rises at $110$ degrees Fahrenheit, which is $0$ degrees on the Breadus scale. Bread is baked at $350$ degrees Fahrenheit, which is $100$ degrees on the Breadus scale. Bread is done when its internal temperature is $200$ degrees Fahrenheit. What is this in degrees on the Breadus scale?
$\textbf{(A) }33\qquad\textbf{(B) }34.5\qquad\textbf{(C) }36\qquad\textbf{(D) }37.5\qquad\textbf{(E) }39$

Solution: We have the points $(0, 110)$ and $(100, 350)$ . We want to find $(x, 200)$ . The equation of the line is $y=\frac{12}{5}x+110$ . We use this to find $x=\frac{75}{2}=37.5$ , or $\boxed{37.5}$ .
~MC413551

Answer: D 37.5
Problem: A digital display shows the current date as an $8$ -digit integer consisting of a $4$ -digit year, followed by a $2$ -digit month, followed by a $2$ -digit date within the month. For example, Arbor Day this year is displayed as 20230428. For how many dates in $2023$ will each digit appear an even number of times in the 8-digital display for that date?
$\textbf{(A)}~5\qquad\textbf{(B)}~6\qquad\textbf{(C)}~7\qquad\textbf{(D)}~8\qquad\textbf{(E)}~9$

Solution: Do careful casework by each month. In the month and the date, we need a $0$ , a $3$ , and two digits repeated (which has to be $1$ and $2$ after consideration). After the casework, we get $\boxed{9}$ .
For curious readers, the numbers (in chronological order) are:

Answer: E 9
Problem: A digital display shows the current date as an $8$ -digit integer consisting of a $4$ -digit year, followed by a $2$ -digit month, followed by a $2$ -digit date within the month. For example, Arbor Day this year is displayed as 20230428. For how many dates in $2023$ will each digit appear an even number of times in the 8-digital display for that date?
$\textbf{(A)}~5\qquad\textbf{(B)}~6\qquad\textbf{(C)}~7\qquad\textbf{(D)}~8\qquad\textbf{(E)}~9$

Solution: There is one $3$ , so we need one more (three more means that either the month or units digit of the day is $3$ ). For the same reason, we need one more $0$
If $3$ is the units digit of the month, then the $0$ can be in either of the three remaining slots. For the first case (tens digit of the month), then the last two digits must match ( $11, 22$ ). For the second (tens digit of the day), we must have the other two be $1$ , as a month can't start with $2$ or $0$ . There are $3$ successes this way.
If $3$ is the tens digit of the day, then $0$ can be either the tens digit of the month or the units digit of the day. For the first case, $1$ must go in the other slots. For the second, the other two slots must be $1$ as well. There are $2$ successes here.
If $3$ is the units digit of the day, then $0$ could go in any of the $3$ remaining slots again. If it's the tens digit of the day, then the other digits must be $1$ . If $0$ is the units digit of the day, then the other two slots must both be $1$ . If $0$ is the tens digit of the month, then the other two slots can be either both $1$ or both $2$ . In total, there are $4$ successes here.
Summing through all cases, there are $3 + 2 + 4 = \boxed{9}$ dates.

Answer: E 9