随笔分类 - Atcoder
摘要:Problem StatementThere is an $N \times M$ grid, where the square at the $i$-th row from the top and $j$-th column from the left has a non-negative int
阅读全文
摘要:Problem StatementThere are $N$ Takahashi. The $i$-th Takahashi has an integer $A_i$ and $B_i$ balls. An integer $x$ between $1$ and $K$, inclusive, wi
阅读全文
摘要:Problem StatementWe define the density of a non-empty simple undirected graph as $\displaystyle\frac{(\text{number of edges})}{(\text{number of vertic
阅读全文
摘要:Problem StatementYou are given a tuple of $N$ non-negative integers $A=(A_1,A_2,\ldots,A_N)$ such that $A_1=0$ and $A_N>0$. Takahashi has $N$ counters
阅读全文
摘要:Problem StatementSnuke found a random number generator. It generates an integer between $0$ and $N-1$ (inclusive). An integer sequence $A_0, A_1, \cdo
阅读全文
摘要:Problem StatementYou are given a positive integer $n$, and a prime number $p$ at least $5$. Find a triple of integers $(x,y,z)$ that satisfies all of
阅读全文
摘要:Problem StatementThere are an integer $N$ and $M$ pairs of integers: $(a_1, b_1), (a_2, b_2), \dots, (a_M, b_M)$. Each pair $(a_i, b_i)$ satisfies $1
阅读全文
摘要:Problem StatementYou are given positive integers $N$ and $K$. Find the number, modulo $998244353$, of integer sequences $\bigl(f(0), f(1), \ldots, f(2
阅读全文
摘要:Problem StatementYou are given a string $S$ consisting of lowercase English letters. Print the number of non-empty strings $T$ that satisfy the follow
阅读全文
摘要:Problem StatementYou are given a sequence of $N$ non-negative integers $A=(A_1,A_2,\dots,A_N)$ and a positive integer $K$. Find the bitwise $\mathrm{X
阅读全文
摘要:h3>Problem StatementJoisino is about to compete in the final round of a certain programming competition. In this contest, there are $N$ problems, numb
阅读全文
摘要:Problem StatementWe have a tree $T$ with vertices numbered $1$ to $N$. The $i$-th edge of $T$ connects vertex $u_i$ and vertex $v_i$. Let us use $T$ t
阅读全文
摘要:Problem StatementA museum exhibits $N$ jewels, Jewel $1, 2, ..., N$. The coordinates of Jewel $i$ are $(x_i, y_i)$ (the museum can be regarded as a tw
阅读全文
摘要:Problem StatementYou are given a directed graph $G$ with $N$ vertices and $M$ edges. The vertices are numbered $1, 2, \ldots, N$. The $i$-th edge is d
阅读全文
摘要:Problem StatementSnuke is playing with red and blue balls, placing them on a two-dimensional plane. First, he performed $N$ operations to place red ba
阅读全文
摘要:Problem StatementSnuke is having another barbeque party. This time, he will make one serving of Skewer Meal. He has a stock of $N$ Skewer Meal Packs.
阅读全文
摘要:Problem StatementYou are given a simple connected undirected graph with $N$ vertices and $M$ edges. (A graph is said to be simple if it has no multi-e
阅读全文
摘要:Problem StatementThere are $N$ people and $K$ nations, labeled as Person $1$, Person $2$, $\ldots$, Person $N$ and Nation $1$, Nation $2$, $\ldots$, N
阅读全文
摘要:Problem StatementGiven a sequence $A$ of $N$ numbers, answer the following $Q$ questions. In the $i$-th question, you are given integers $L_i$ and $R_
阅读全文