問題一覧 > 通常問題

No.969 Rock Paper Scissors

レベル : / AI推定難易度 : 101 / 実行時間制限 : 1ケース 2.000秒 / メモリ制限 : 512 MB / 標準ジャッジ問題
タグ : (AC するまで非表示) / 解いたユーザー数 513
作問者 : 沙耶花 / テスター : shibh308
お気に入りにしたユーザー ProblemId : 3632 / 自分の提出
問題文最終更新日: 2020-05-07 19:55:41
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 234 (順位表) の他の問題:

Problem Statement

Sayaka decided to play rock paper scissors using both hands.

At the call of "Rock, paper, scissors, go!", she made each of her right hand and left hand into one of "Rock", "Scissors", or "Paper",
and the sum of the number of fingers raised on her right hand and the number of fingers raised on her left hand turned out to be $X$.

Here, it is considered that

  • a "Rock" hand has 0 fingers raised
  • a "Scissors" hand has 2 fingers raised
  • a "Paper" hand has 5 fingers raised
.

Determine whether it is possible that the game ended in a draw.

Input

$X$

  • $X$ is a non-negative integer consistent with the problem statement

Output

Print "Yes" if it is possible that the game ended in a draw, and "No" otherwise.
Print a newline at the end.

Sample

Sample 1
Input
0
Output
Yes

The only possibility is that both the right hand and the left hand are Rock, so the game is a draw.

Sample 2
Input
7
Output
No

There are two possibilities: "the right hand is Scissors and the left hand is Paper" and "the right hand is Paper and the left hand is Scissors".
In the former the right hand wins, and in the latter the left hand wins, so in either case it is not a draw.

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