問題一覧 > 通常問題

No.2864 String of yuusaan

レベル : / AI推定難易度 : 700 / 実行時間制限 : 1ケース 2.000秒 / メモリ制限 : 512 MB / 標準ジャッジ問題
タグ : (解説公開後に AC するまで非表示) / 解いたユーザー数 117
作問者 : yuusaan / テスター : 寝癖 👑 seekworser
お気に入りにしたユーザー ProblemId : 11102 / 自分の提出
問題文最終更新日: 2024-08-30 21:11:35
This statement was translated by AI (claude-opus-5-5, effort medium) and may contain errors or differ in nuance from the original. The original statement takes precedence. Back to the original
yukicoder contest 443 (順位表) の他の問題:

Story

Yu~san, a researcher, is explaining to you, his assistant, a string he says he found during his research.

"This string, yuusaan, looks like nothing more than my nickname at first glance, but... look, it has become yuusaanuusaayuusaan.

It seems that y and n are turning into yuusaan, and if left alone, it will probably grow longer at a terrifying rate. At this rate it will eventually grow long enough to cover the whole Earth, and we'll have no choice but to launch it into space on a rocket.

So, I'd like you to analyze it before it's too late. I'm counting on you."

Problem Statement

Let the level $1$ Yu~ string be yuusaan.

For each integer $i$ greater than or equal to $2$, the level $i$ Yu~ string is defined as follows.

  • The string obtained by replacing every y and every n in the level $(i-1)$ Yu~ string with yuusaan

Determine the $K$-th character of the level $N$ Yu~ string.

Input

$N\ K$

Constraints

  • $1\leq N,K\leq 10^{15}$
  • The level $N$ Yu~ string has length at least $K$

Output

Output the answer on one line, followed by a newline.

Sample

Sample 1
Input
2 8
Output
u

The level $2$ Yu~ string is yuusaanuusaayuusaan, so output its $8$-th character, u.

Sample 2
Input
1 1
Output
y

The level $1$ Yu~ string is yuusaan.

提出するには、Twitter 、GitHub、 Googleもしくは右上の雲マークをクリックしてアカウントを作成してください。