程序改动如下:
CLEAR
k=0
FOR m=10 TO 80
SS=1
FOR n=2 TO 9
IF mod(m,n)=0
SS=0
ENDIF
Next n
IF SS!=0
K=K+1
ENDIF
Next m
"素数的个数是:",k
RETURN
程序改动如下:
CLEAR
k=0
FOR m=10 TO 80
SS=1
FOR n=2 TO 9
IF mod(m,n)=0
SS=0
ENDIF
Next n
IF SS!=0
K=K+1
ENDIF
Next m
"素数的个数是:",k
RETURN