/ Vijos /

记录详情

Compile Error

foo.cc:4:2: error: 'undefined' does not name a type
    4 | {undefined
      |  ^~~~~~~~~
foo.cc: In function 'int main()':
foo.cc:14:2: error: 'undefined' was not declared in this scope
   14 | {undefined
      |  ^~~~~~~~~
foo.cc:17:15: error: 'n' was not declared in this scope
   17 |          cin>>n;
      |               ^
foo.cc:19:19: error: expected ';' before 'return'
   19 |         {undefined
      |                   ^
      |                   ;
   20 |              return 0;
      |              ~~~~~~
foo.cc:24:20: error: expected ';' before 'cin'
   24 |          {undefined
      |                    ^
      |                    ;
   25 |                 cin>>s[i].Name>>s[i].Qm>>s[i].Py>>s[i].Sm>>s[i].Es>>s[i].Fb;
      |                 ~~~ 
foo.cc:28:19: error: expected ';' before 'if'
   28 |         {undefined
      |                   ^
      |                   ;
   29 |                if (s[i].Qm<=80)
      |                ~~  
foo.cc:40:24: error: expected ';' before 'if'
   40 |              {undefined
      |                        ^
      |                        ;
   41 |                       if (s[i].Fb>=1)
      |                       ~~
foo.cc:46:31: error: expected ';' before 'if'
   46 |                     {undefined
      |                               ^
      |                               ;
   47 |                              if (s[i].Sm=='y'||s[i].Sm=='Y')
      |                              ~~
foo.cc:53:30: error: expected ';' before 'if'
   53 |                    {undefined
      |                              ^
      |                              ;
   54 |                            if (s[i].Es=='y'||s[i].Es=='Y')
      |                            ~~ 
foo.cc:59:38: error: expected ';' before 'a'
   59 |                            {undefined
      |                                      ^
      |                                      ;
   60 |                                 a[i]+=4000;
      |                                 ~     
foo.cc:64:30: error: expected ';' before 'a'
   64 |                    {undefined
      |                              ^
      |                              ;
   65 |                           a[i]+=2000;
      |                           ~   
foo.cc:73:15: error: expected ';' before 'sum'
   73 |     {undefined
      |               ^
      |               ;
   74 |            sum+=a[i];
      |            ~~~ 
foo.cc:76:21: error: expected ';' before 'MaxMoney'
   76 |           {undefined
      |                     ^
      |                     ;
   77 |                  MaxMoney = a[i];
      |                  ~~~~~~~~
foo.cc:81:16: error: 'struct student' has no member named 'Name'
   81 |     cout<<s[j].Name<<endl
      |                ^~~~
[Hydro](https://hydro.ac)提供评测服务

信息

递交者
类型
递交
题目
P1001 谁拿了最多奖学金
语言
C++
递交时间
2022-04-01 11:39:52
评测时间
2022-04-01 11:39:52
评测机
分数
0
总耗时
0ms
峰值内存
0 Bytes