This commit is contained in:
2024-03-04 23:45:56 +08:00
commit 2e9a13a76c
33 changed files with 4563 additions and 0 deletions

20
Chapter1/b/b.cpp Normal file
View File

@@ -0,0 +1,20 @@
#include<iostream>
using namespace std;
void main()
{
int i = 0, j = 0, count = 0;
for (i = 2; i <= 1000; i++)
{
for (j = 2; j <= i - 1; j++)
if (i % j == 0)
break;
if (j > i - 1)
{
cout << j << '\t';
count++;
if (count % 5 == 0) cout << endl;
}
}
return;
}