Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
1880 孙浚轩 n!大于k C++ Accepted 0 MS 260 KB 343 2023-11-26 11:47:02

Tests(10/10):


Code:

#include<iostream> using namespace std; int fac(int x){ if(x==0) return 1; else{ int i=x; while(i>1){ i--; x*=i; } return x; } } int main(){ int k; long long n=0; cin>>k; while(fac(n)<=k) n++; cout<<n; return 0; }