| Run ID | 作者 | 问题 | 语言 | 测评结果 | Time | Memory | 代码长度 | 提交时间 |
|---|---|---|---|---|---|---|---|---|
| 67826 | 张俊杰 | 十进制转二进制 | C++ | Runtime Error | 0 MS | 272 KB | 271 | 2024-03-17 14:53:33 |
#include<bits/stdc++.h> using namespace std; int main(){ int n,l=0; int a[3]; cin>>n; for(int i=1;i<=n;i++){ a[l++]=n%2; n=n/2; } a[l++]=n%2; for(int i=l-1;i>=0;i--){ cout<<a[i]; } return 0; }
*** stack smashing detected ***: ./Main terminated