Run ID 作者 问题 语言 测评结果 分数 时间 内存 代码长度 提交时间
339833 金奕君 GESP:2023-6月等级2-T1-找素数 C++ 通过 100 0 MS 272 KB 255 2025-01-05 14:58:50

Tests(5/5):


#include<bits/stdc++.h> using namespace std; int main() { int n,s=0,b; bool a=true; cin>>b>>n; for (int i=b; i<=n; i++) { a=true; for (int j=2; j<i; j++) if (i%j==0) a=false; if (a==true) s++; } cout<<s; return 0; }


测评信息: