当前位置:网站首页>100002nd prime
100002nd prime
2022-06-26 02:29:00 【886emmmm】
public class T2 {
public static void main(String[] args) {
// No prime found count Add one
int count=0;
// Judge j Prime or not
for (int i = 2;; i++) {
int j=2;
while (i%j!=0) {
j++;
}
if (i==j) {
count++;
}
if (count==1002) {
System.out.println(j);
return;
}
}
}
}
边栏推荐
猜你喜欢
Cross server SQL connection configuration
SQL column value to row value (unpivot)
OA process editing
Shell learning record (IV)
Scala 基础 (二):变量和数据类型
How to solve the problem that the iPhone 13 lock screen cannot receive the wechat notification prompt?
Shell learning record (II)
ARM流水线如何提高代码执行效率
SDRAM controller -- implementation of arbitration module
[untitled] vsbiji ESP thirty-two
随机推荐
Digital commodity DGE -- the dark horse of wealth in digital economy
What happens when the cloud answer does not display the third-party login button
OA process editing
树莓派 + AWS IoT Greengrass
Chrome browser developer tool usage
第一章:渗透测试的本质信息收集
工作一年闲记
奶牛排序问题
Prometeus 2.33.0 new features
Redis6.0新特性——ACL(权限控制列表)实现限制用户可执行命令和KEY
深度好文:什么是超网 Supernetting?
音视频与CPU架构
Mongoose - Why we make “mongoose.Promise = global.Promise” when setting a mongoose module?
df报错Stale file handle
Consumer of microservices
PyQt theme
Create OpenGL window
[image filtering] image filtering system based on Matlab GUI [including Matlab source code 1913]
图的深度优先遍历
表达式的动态解析和计算,Flee用起来真香