Preparando MOJI

Fibonacci army

2000ms 262144K

Description:

King Cambyses loves Fibonacci numbers. He has several armies. Today he wants to make a new army for himself and he wants the number of men in this army to be the n-th Fibonacci number.

Given n you should find n-th Fibonacci number. The set of Fibonacci numbers start with f0 = f1 = 1 and for each i ≥ 2, fi = fi - 1 + fi - 2.

Input:

Input contains a single integer n (1 ≤ n ≤ 20).

Output:

Write a single integer. The n-th Fibonacci number.

Sample Input:

2

Sample Output:

2

Sample Input:

1

Sample Output:

1

Informação

Codeforces

Provedor Codeforces

Código CF72G

Tags

*specialdp

Submetido 0

BOUA! 0

Taxa de BOUA's 0%

Datas 09/05/2023 08:30:31

Relacionados

Nada ainda