/ Vijos /

记录详情

Compile Error

foo.cpp: In function 'int main()':
foo.cpp:8:7: warning: left operand of comma operator has no effect [-Wunused-value]
  for(0<=x,y<=32767)
      ~^~~
foo.cpp:8:19: error: expected ';' before ')' token
  for(0<=x,y<=32767)
                   ^
foo.cpp:8:12: warning: right operand of comma operator has no effect [-Wunused-value]
  for(0<=x,y<=32767)
           ~^~~~~~~
foo.cpp:11:37: error: invalid operands of types 'int' and '<unresolved overloaded function type>' to binary 'operator<<'
  cout << "the sum is =>" << sum=x+y << endl;
                                 ~~~~^~~~~~~
foo.cpp:11:34: warning: suggest parentheses around '+' inside '<<' [-Wparentheses]
  cout << "the sum is =>" << sum=x+y << endl;
                                 ~^~
foo.cpp:12:35: error: expected ')' before ';' token
     cout << "hello, world" << endl;
                                   ^

信息

递交者
类型
递交
题目
P1000 A+B Problem
语言
C++
递交时间
2017-02-24 11:32:07
评测时间
2017-02-24 11:32:07
评测机
分数
0
总耗时
0ms
峰值内存
0 Bytes