MathDB
Problems
Contests
National and Regional Contests
Moldova Contests
Moldova Team Selection Test
2023 Moldova Team Selection Test
3
3
Part of
2023 Moldova Team Selection Test
Problems
(1)
A sequence $(a_1,a_2,\ldots,a_n)$ of length is called $balanced$
Source: Moldova TST 2023
4/7/2023
Let
n
n
n
be a positive integer. A sequence
(
a
1
,
a
2
,
…
,
a
n
)
(a_1,a_2,\ldots,a_n)
(
a
1
,
a
2
,
…
,
a
n
)
of length is called
b
a
l
a
n
c
e
d
balanced
ba
l
an
ce
d
if for every
k
k
k
(
1
≤
k
≤
n
)
(1\leq k\leq n)
(
1
≤
k
≤
n
)
the term
a
k
a_k
a
k
is equal with the number of distinct numbers from the subsequence
(
a
1
,
a
2
,
…
,
a
k
)
.
(a_1,a_2,\ldots,a_k).
(
a
1
,
a
2
,
…
,
a
k
)
.
a) How many balanced sequences
(
a
1
,
a
2
,
…
,
a
n
)
(a_1,a_2,\ldots,a_n)
(
a
1
,
a
2
,
…
,
a
n
)
of length
n
n
n
do exist? b) For every positive integer
m
m
m
find how many balanced sequences
(
a
1
,
a
2
,
…
,
a
n
)
(a_1,a_2,\ldots,a_n)
(
a
1
,
a
2
,
…
,
a
n
)
of length
n
n
n
exist such that
a
n
=
m
.
a_n=m.
a
n
=
m
.
combinatorics