【算法】计算质数
2020-12-13 06:20
阅读:349
标签:OLE his turn shu ret for ++ boolean bool 【算法】计算质数 标签:OLE his turn shu ret for ++ boolean bool 原文地址:https://www.cnblogs.com/LPworld/p/11175362.html
static boolean zhishu(int a) {
int b=a/2;
int i=2;
for(;i) {
if(a%i==0)
return false;
b=a/i;
}
return true;
}
评论
亲,登录后才可以留言!