Run ID | 作者 | 问题 | 语言 | 测评结果 | 时间 | 内存 | 代码长度 | 提交时间 |
---|---|---|---|---|---|---|---|---|
63599 | lhrssby | 质因数的个数 | C++ | 通过 | 0 MS | 248 KB | 297 | 2025-03-30 17:11:10 |
using namespace std; int main(){ int a,b,maxl=0,ans=0,d; cin>>a>>b; for(int i=a;i<=b;i++){ ans=0; d=i; int t=2; while(d!=1){ while(d%t==0){ d/=t; ans++; } t++; } maxl=max(maxl,ans); } cout<<maxl; return 0; }
exit code: 0, checker exit code: 0