Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
75343 张誉腾 十进制转二进制 C++ Compile Error 0 MS 0 KB 260 2024-05-26 16:35:17

Tests(0/0):


Code:

#include<bits/stdc++.h> using namespace std; int main(){ int a; cin>>a; int x[32],cnt=0; if(a==0){ cout<<0; return 0; } while(a!=0){ int yu=a%2; x[cnt]=yu; cnt++; a/=2; } for(int i=cnt-1;i>=0;i--){ cout<<b[i]; } }


Run Info:

Main.cc: In function 'int main()':
Main.cc:20:9: error: 'b' was not declared in this scope
   cout<