记录详情

Compile Error

/in/foo.cc:1:1: error: 'var' does not name a type; did you mean 'char'?
 var k,l,i:longint;
 ^~~
 char
/in/foo.cc:2:1: error: 'begin' does not name a type
 begin
 ^~~~~
/in/foo.cc:6:2: error: 'l' does not name a type
  l:=k;
  ^
/in/foo.cc:7:2: error: expected unqualified-id before 'if'
  if (k<>4)and(k mod 2=0) then l:=k div 2;
  ^~
/in/foo.cc:8:2: error: expected unqualified-id before 'for'
  for i:=3 to trunc(sqrt(k))+1 do
  ^~~
/in/foo.cc:10:2: error: expected unqualified-id before 'if'
  if k mod i=0 then l:=i;
  ^~
/in/foo.cc:11:2: error: 'l' does not name a type
  l:=l-1;
  ^
/in/foo.cc:12:9: error: expected constructor, destructor, or type conversion before '(' token
  writeln(l);
         ^
/in/foo.cc:13:7: error: expected constructor, destructor, or type conversion before '(' token
  close(input);close(output);
       ^
/in/foo.cc:13:20: error: expected constructor, destructor, or type conversion before '(' token
  close(input);close(output);
                    ^
/in/foo.cc:14:1: error: 'end' does not name a type; did you mean 'enum'?
 end.
 ^~~
 enum

信息

递交者
类型
递交
题目
3# 分糖果
题目数据
下载
语言
C++
递交时间
2018-11-07 18:50:20
评测时间
2018-11-07 18:50:20
评测机
分数
0
总耗时
8ms
峰值内存
2.789 MiB