No.1934 Four Fruits
タグ : / 解いたユーザー数 303
作問者 :
noya2
/ テスター :
tatyam
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. Show the original
Problem Statement
Noya came to a shop that sells plenty of each of $4$ types of fruit $0,1,2,3$, and bought $4$ fruits so as to satisfy at least one of the following conditions.
Given that $3$ of the $4$ fruits Noya bought are $a,b,c$, find the remaining $1$ fruit.
It can be shown that the answer is uniquely determined for any input under these constraints.
Constraints
Input
$a\ b\ c$
Output
Determine which of $0,1,2,3$ the remaining $1$ fruit is, and print it.
Sample
Sample 1
Input
1 1 1
Output
1
Noya bought the fruits so as to satisfy the $1$st condition.
Sample 2
Input
3 2 3
Output
2
Noya bought the fruits so as to satisfy the $2$nd condition.
Sample 3
Input
1 3 2
Output
0
Noya bought the fruits so as to satisfy the $3$rd condition.
提出するには、Twitter 、GitHub、 Googleもしくは右上の雲マークをクリックしてアカウントを作成してください。