| Run ID | 作者 | 问题 | 语言 | 测评结果 | 分数 | 时间 | 内存 | 代码长度 | 提交时间 |
|---|---|---|---|---|---|---|---|---|---|
| 438560 | 陈梓霖 | 【C3-9】角谷猜想 | C++ | 通过 | 100 | 1 MS | 240 KB | 239 | 2026-05-02 13:29:08 |
#include<bits/stdc++.h> using namespace std; int fun(int n){ if(n!=1){ if(n%2==0){ return 1+fun(n/2); }else{ return 1+fun(n*3+1); } }else{ return 0; } } int main(){ int n; cin>>n; cout<<fun(n); return 0; }