记录详情

Compile Error

/in/foo.c: In function 'Fibonacci':
/in/foo.c:5:18: warning: comparison of constant '50' with boolean expression is always true [-Wbool-compare]
  for (int i=2;0<i<50;i++)
                  ^
/in/foo.c:5:16: warning: comparisons like 'X<=Y<=Z' do not have their mathematical meaning [-Wparentheses]
  for (int i=2;0<i<50;i++)
               ~^~
/in/foo.c:7:19: error: expected expression before '[' token
   arr[i]=arr[i-1]+[i-2];
                   ^
/in/foo.c: In function 'main':
/in/foo.c:13:2: error: 'intc' undeclared (first use in this function)
  intc=0;
  ^~~~
/in/foo.c:13:2: note: each undeclared identifier is reported only once for each function it appears in
/in/foo.c:15:2: warning: implicit declaration of function 'scanf_s' [-Wimplicit-function-declaration]
  scanf_s("%d",&c);
  ^~~~~~~
/in/foo.c:15:16: error: 'c' undeclared (first use in this function)
  scanf_s("%d",&c);
                ^

信息

递交者
类型
递交
题目
P1005 斐波那契数列
语言
C
递交时间
2024-08-25 16:58:11
评测时间
2024-08-25 16:58:11
评测机
分数
0
总耗时
0ms
峰值内存
0 Bytes