B1. We call a sequence of consecutive positive integers balanced if the number of multiples of three in that sequence is equal to the number of multiples of five. For example, the sequence 30, 31, 32, 33, 34, 35, 36 is not balanced, because out of these 7 numbers, 3 are multiples of three (namely 30, 33, and 36) and only 2 are multiples of five (namely 30 and 35).

How many numbers can a balanced sequence of consecutive positive integers contain at most?
B1. 11 Of every three consecutive integers, there is always exactly one that is a multiple of three. Now consider a sequence of $k$ consecutive integers. If $k$ itself is a multiple of three, say $k=3 \ell$, then exactly $\ell$ numbers in the sequence are multiples of three: one in each consecutive group of three numbers. If $k$ is not a multiple of three, say $k=3 \ell+1$ or $k=3 \ell+2$, then at least $\ell$ of the numbers in the sequence are multiples of three, because $k \geqslant 3 \ell$. In all cases, $3 \ell \geqslant k-2$ and the number of multiples of three is thus at least $\ell \geqslant \frac{k-2}{3}$.

Of every five consecutive integers, there is always exactly one that is a multiple of five. Now consider a sequence of $k$ consecutive integers. If $k$ is a multiple of five, say $k=5 m$, then the number of multiples of five in the sequence is exactly $m$. If $k$ is not a multiple of five, say $k=5 m-1$, $k=5 m-2$, $k=5 m-3$, or $k=5 m-4$, then at most $m$ numbers in the sequence are multiples of five. In all cases, $5 m \leqslant k+4$ and the number of multiples of five is thus at most $m \leqslant \frac{k+4}{5}$.

If a balanced sequence has length $k$, then it must hold that $\frac{k-2}{3} \leqslant \frac{k+4}{5}$. Multiplying both sides by 15 gives $5 k-10 \leqslant 3 k+12$. From this, it follows that $2 k \leqslant 22$ and thus that $k \leqslant 11$.

The sequence $10,11, \ldots, 20$ has length 11 and is balanced. Indeed, it contains 3 multiples of three and 3 multiples of five. We therefore conclude that $k=11$ is the maximum length of a balanced sequence.