| Run ID | 作者 | 问题 | 语言 | 测评结果 | Time | Memory | 代码长度 | 提交时间 |
|---|---|---|---|---|---|---|---|---|
| 162520 | 万骏博 | 二进制转十进制 | C++ | Accepted | 1 MS | 280 KB | 199 | 2026-10-17 17:10:42 |
#include<bits/stdc++.h> using namespace std; string s; int n,m=2; int main(){ cin>>s; int l=s.size(); for(int i=0;i<l;i++){ n+=pow(2,l-i-1)*(s[i]-'0'); } cout<<n; return 0; }