Submission

Status:

PPPPPPPPPP

Subtask/Task Score:

100/100

Score: 100

User: Hax

Problemset: อนุกรม

Language: cpp

Time: 0.004 second

Submitted On: 2026-10-12 09:07:50

#include <iostream>

using namespace std;

int main() {
	long long f0 = 0;
	long long f1 = 1;
	long long fn;
	long long n;
	cin >> n;
	for (int i = 0; i < n; i ++) {
		fn = f1 + f0;
		f0 = f1;
		f1 = fn;
	}
	cout << f0;
}