No.8022 Restricted FizzBuzz (Easy)
レベル :
/ 実行時間制限 : 1ケース 2.000秒 / メモリ制限
: 512 MB / スペシャルジャッジ問題 (複数の解が存在する可能性があります)
タグ : / 解いたユーザー数 220
作問者 :
くれちー
タグ : / 解いたユーザー数 220
作問者 :
くれちー
問題文最終更新日: 2020-04-01 19:11:27
English (AI translation)
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 April fool contest 2017
(順位表)
の他の問題:
Note
Please also refer to No.9002 FizzBuzz (for testing).
The test cases are identical to those of the above problem.
Problem Statement
For each integer $i$ from $1$ to $N$ in order,
print Fizz if $i$ is a multiple of $3$, Buzz if it is a multiple of $5$,
and $i$ otherwise.
However, if $i$ is both a multiple of $3$ and a multiple of $5$, print FizzBuzz.
If your source code contains any of the characters 0, 1, 2, 3, 4, 5, 6, 7, 8, 9,
it will be judged as incorrect.
Input
$N$
- $N$ is an integer
- $1 \le N \le 100$
Output
Print $N$ lines in total, one of Fizz, Buzz, FizzBuzz, or $i$ for each integer $i$.
Print a newline after each output.
Sample
Sample 1
Input
16
Output
1 2 Fizz 4 Buzz Fizz 7 8 Fizz Buzz 11 Fizz 13 14 FizzBuzz 16
提出するには、Twitter 、GitHub、 Googleもしくは右上の雲マークをクリックしてアカウントを作成してください。