================================================
A quick book for public courses {
/**
* to determine whether a number is a prime number.
* @param a's number.
* @return is a prime number that returns true.
*/
public boolean isSuhu(int a){
boolean isSushu = true
//Judge whether a number is a prime number according to the nature of the prime number.
for(int I = 2; I & lta;; i++){
if(a%i==0){
isSushu = false
Break;
}
}
Return to isSushu
}
/**
* Determine which of several consecutive numbers are prime numbers.
* @param start starting number
* @param termination number
*/
public void selectSushu(int start,int end){
//Determine which numbers in a string are prime numbers and print out the results.
for(int I = start; I<= end; i++){
if(isSuhu(i)){
system . out . println(I);
}
}
}
Public static void main(String []args){
//Define the starting position and ending position.
int start = 1;
int end = 100;
//Declare variables
Sushu s = new Sushu();
//Call the method
S.selectSushu (start, end);
}
}