QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#335246#7698. ISBN ConversionZhangYiDeCompile Error//C++172.0kb2024-02-23 01:14:562024-02-23 01:14:58

詳細信息

answer.code: In function ‘int main()’:
answer.code:65:56: error: expected ‘;’ before ‘{’ token
   65 |         if(S[9] != (sum == 10 ? 'X' : (char)(sum + 48))
      |                                                        ^
      |                                                        ;
   66 |         {
      |         ~                                               
answer.code:70:9: error: expected primary-expression before ‘if’
   70 |         if(sum==10 && S[9] != 'X')
      |         ^~
answer.code:69:10: error: expected ‘)’ before ‘if’
   69 |         }
      |          ^
      |          )
   70 |         if(sum==10 && S[9] != 'X')
      |         ~~
answer.code:65:11: note: to match this ‘(’
   65 |         if(S[9] != (sum == 10 ? 'X' : (char)(sum + 48))
      |           ^
answer.code:84:9: error: ‘ans’ was not declared in this scope; did you mean ‘abs’?
   84 |         ans[ans.size() - 1] = (char) sum + 48;
      |         ^~~
      |         abs