Compile Error

foo.cc: In function 'int main()':
foo.cc:9:5: warning: this 'while' clause does not guard... [-Wmisleading-indentation]
    9 |     while (X!=0);
      |     ^~~~~
foo.cc:10:5: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the 'while'
   10 |     {
      |     ^
foo.cc:12:11: error: 'x' was not declared in this scope
   12 |      sum+=x%10;
      |           ^
[Hydro](https://hydro.ac)提供评测服务

信息

递交者
类型
递交
题目
P1033 任意整数的数字之和。
语言
C++
递交时间
2021-12-11 20:49:14
评测时间
2021-12-11 20:49:14
评测机
分数
0
总耗时
0ms
峰值内存
0 Bytes