Compile Error

foo.cc: In function ‘int main()’:
foo.cc:15:17: error: ‘ans’ was not declared in this scope; did you mean ‘abs’?
   15 |                 ans+=(s[j]-48)*jz;
      |                 ^~~
      |                 abs
foo.cc:15:32: error: ‘jz’ was not declared in this scope; did you mean ‘j’?
   15 |                 ans+=(s[j]-48)*jz;
      |                                ^~
      |                                j
foo.cc:17:17: error: ‘ans’ was not declared in this scope; did you mean ‘abs’?
   17 |                 ans+=(s[j]-'A'+10)*jz;
      |                 ^~~
      |                 abs
foo.cc:17:36: error: ‘jz’ was not declared in this scope; did you mean ‘j’?
   17 |                 ans+=(s[j]-'A'+10)*jz;
      |                                    ^~
      |                                    j
foo.cc:18:13: error: ‘jz’ was not declared in this scope; did you mean ‘j’?
   18 |             jz*=k;
      |             ^~
      |             j

信息

递交者
类型
递交
题目
P2605 进制转换4级1 202309
语言
C++
递交时间
2026-04-30 19:20:51
评测时间
2026-04-30 19:20:51
评测机
分数
0
总耗时
0ms
峰值内存
0 Bytes