Fib3 Queue
该比赛已结束,您无法在比赛模式下递交该题目。您可以点击“在题库中打开”以普通模式查看和递交本题。
P1001 Fib3 Queue
Difficulty:
Problem Statement
You need to create a Fib3 Queue. (A Fib3 Queue is a queue that from the 4th element on, its value equals the sum of the three consecutive elements before.) We will give you the , the and the element and you need to work out the 1st element.
Constraints
Input
Note that , , may be not in order.
Output
Output the queue's 1st element.
Samples
Input 1
Output 1
We can get the answer by calculating .
Input 2
Output 2
We can get the answer immediately from the input.
Input 3
Output 3
Input 4
Output 4
Note that the result may not fits in a bit integer.
AOCode Round #2 (Div. 2) - Rematch - AOCR #1 - With Additionals
- 状态
- 已结束
- 规则
- ACM/ICPC
- 题目
- 7
- 开始于
- 2021-10-02 13:30
- 结束于
- 2021-10-02 16:30
- 持续时间
- 3.0 小时
- 主持人
- 参赛人数
- 9