Submission

Status:

PPPPPPPPPP

Subtask/Task Score:

100/100

Score: 100

User: emipp

Problemset: อนุกรม

Language: cpp

Time: 0.002 second

Submitted On: 2025-10-10 00:47:48

#include<iostream>
using namespace std ;
long long int a [9999] ;
int main () {
   int n ;
   cin >> n ;
   
    a[0] = 1 ;
    a [1] = 1 ;
    for (int i = 2 ; i <= 90 ; i++){
    a[i] = a[i-1] + a[i-2] ; 
    } 

    cout << a[n-1] ;
  }