Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
139842 左锶焜 14经过路口 C++ Compile Error 0 MS 0 KB 419 2025-12-09 19:54:01

Tests(0/0):


Code:

#include<iostream> // cin\cout\endl #include<cstdio> //scanf()\printf() #include<cstring> // strcpy()\strcat()\strcmp()\strlen()\memset() #include<cmath> //sqrt()\pow()\abs()\ceil()\floor()\max()\min() using namespace std; int main(){ int y=100000,s,x; cin>>n; while(y>50000){ y-=y*5%; x++; } if(y<50000){ y-5000; x++ } return 0; }


Run Info:

Main.cc: In function 'int main()':
Main.cc:9:10: error: 'n' was not declared in this scope
     cin>>n;
          ^
Main.cc:11:16: error: expected primary-expression before ';' token
         y-=y*5%;
                ^
Main.cc:15:10: warning: statement has no effect [-Wunused-value]
         y-5000;
          ^
Main.cc:17:5: error: expected ';' before '}' token
     }
     ^
Main.cc:8:18: warning: unused variable 's' [-Wunused-variable]
     int y=100000,s,x;
                  ^