UOJ Logo

NOI.AC

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#212923#4. 爬楼梯fzm1o00ms1200kbC++11172b2024-10-21 19:51:482024-10-21 19:51:49

answer

#include<bits/stdc++.h>
using namespace std;
int main(){
	int n,a[50];
	cin>>n;
	a[1]=1;
	a[2]=2;
	for(int i=1;i<=n;i++){
		a[i]=a[i-1]+a[i-2];
	}
	cout<<a[n];
}

详细

小提示:点击横条可展开更详细的信息

Test #1:

score: 0
Wrong Answer
time: 0ms
memory: 1200kb

input:

36

output:

585808306

result:

wrong answer 1st numbers differ - expected: '24157817', found: '585808306'

Test #2:

score: 0
Wrong Answer
time: 0ms
memory: 1200kb

input:

30

output:

27653738

result:

wrong answer 1st numbers differ - expected: '1346269', found: '27653738'

Test #3:

score: 0
Wrong Answer
time: 0ms
memory: 1196kb

input:

29

output:

16576721

result:

wrong answer 1st numbers differ - expected: '832040', found: '16576721'

Test #4:

score: 0
Wrong Answer
time: 0ms
memory: 1196kb

input:

21

output:

265288

result:

wrong answer 1st numbers differ - expected: '17711', found: '265288'

Test #5:

score: 0
Wrong Answer
time: 0ms
memory: 1196kb

input:

16

output:

18986

result:

wrong answer 1st numbers differ - expected: '1597', found: '18986'

Test #6:

score: 0
Wrong Answer
time: 0ms
memory: 1196kb

input:

12

output:

2194

result:

wrong answer 1st numbers differ - expected: '233', found: '2194'

Test #7:

score: 0
Wrong Answer
time: 0ms
memory: 1196kb

input:

9

output:

416

result:

wrong answer 1st numbers differ - expected: '55', found: '416'

Test #8:

score: 0
Wrong Answer
time: 0ms
memory: 1196kb

input:

5

output:

41

result:

wrong answer 1st numbers differ - expected: '8', found: '41'

Test #9:

score: 0
Wrong Answer
time: 0ms
memory: 1200kb

input:

4

output:

22

result:

wrong answer 1st numbers differ - expected: '5', found: '22'

Test #10:

score: 0
Wrong Answer
time: 0ms
memory: 1196kb

input:

1

output:

3

result:

wrong answer 1st numbers differ - expected: '1', found: '3'