問題一覧 > 通常問題

No.234 Meguru Meguru (4)

レベル : / AI推定難易度 : 2500 / 実行時間制限 : 1ケース 1.000秒 / メモリ制限 : 128 MB / 標準ジャッジ問題
タグ : (AC するまで非表示) / 解いたユーザー数 19
作問者 : LayCurse
お気に入りにしたユーザー ProblemId : 536 / 自分の提出
問題文最終更新日: 2026-06-25 18:33:28
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 112 (順位表) の他の問題:

Problem Statement

Charo, Senpai.
Right now, Meguru is playing a doujin game called Chota Quest, but the extra dungeon you get after clearing it is awful...
The story is that, to cure a friend's illness, you ask an adorable character named cucumber to make you a magical girl, and then you complete assignments, but these assignments are such a pain!

Floor $N$ of the Labyrinth of Assignments is shaped like it's made of a triangle with $N$ tiers, but... saying that doesn't really tell you anything, does it?
Drawn simply, it looks like this.

On floor $N$ of this labyrinth, if you walk along the designated route, the stairs to the next floor appear, but there are no hints at all about what the designated route is, so you have to try every single one...
Judging from the pattern so far, the designated route is a route that forms a simple polygon, but even so, there are just too many routes...
Oh, a simple polygon is a polygon whose edges don't cross. If you look at ARC037D, I think even you will get it, Senpai!
Ahh, jeez, just how many routes do I have to try...!?

Input

$N$

$1 \leq N \leq 12$

Output

Please output the number of routes on floor $N$, Senpai!
A route can start anywhere as long as it comes back to where it started, so it's the same as the number of simple polygons.

Sample

Sample 1
Input
1
Output
1
Sample 2
Input
2
Output
11

Is this the same problem as the first sample of ARC037D?

Sample 3
Input
5
Output
128967

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