记录详情

Compile Error

/in/foo.c: In function 'isPrime':
/in/foo.c:7:16: error: expected ')' before 'II'
  if(num % 2==0 II num % 3 == 0)
                ^~
/in/foo.c:10:15: warning: implicit declaration of function 'sqrt' [-Wimplicit-function-declaration]
  for(i=5;i <= sqrt(num);i = i+6{
               ^~~~
/in/foo.c:10:15: warning: incompatible implicit declaration of built-in function 'sqrt'
/in/foo.c:10:15: note: include '<math.h>' or provide a declaration of 'sqrt'
/in/foo.c:10:32: error: expected ')' before '{' token
  for(i=5;i <= sqrt(num);i = i+6{
                                ^
/in/foo.c:15:1: error: expected expression before '}' token
 }
 ^
/in/foo.c: In function 'main':
/in/foo.c:23:17: error: expected ')' before 'count'
   if(isPrime(i) count++;
                 ^~~~~
/in/foo.c:24:2: error: expected expression before '}' token
  }
  ^
/in/foo.c: In function 'isPrime':
/in/foo.c:15:1: warning: control reaches end of non-void function [-Wreturn-type]
 }
 ^

信息

递交者
类型
自测
语言
C
递交时间
2024-11-19 08:37:50
评测时间
2024-11-19 08:37:50
评测机
分数
0
总耗时
0ms
峰值内存
0 Bytes