提交时间:2023-10-05 10:23:13

运行 ID: 105096

#include<iostream> using namespace std; int shenma(int x) { int y; y=x/2; if(x==1) return 1; else return y+shenma(y); } int main() { int a; cin>>a; cout<<shenma(a)+1; return 0; }