(In reply to
re(2): computer solution NEEDS FILTERING by Charlie)
I'll let the previous post be the limit of the portion of the filtered listing I include. The revised main part of the program is:
For bse = 3 To 36
Text1.Text = Text1.Text & bse & crlf
st = bse * bse * bse
fin = st * bse
p = nxtprm(st)
Do
DoEvents
s4$ = base$(p, bse)
good = 1
For i = 2 To 4
If InStr(s4$, Mid(s4, i, 1)) < i Then good = 0
Next
If good Then
p1 = fromBase(Left(s4$, 1), bse)
If prmdiv(p1) = p1 And p1 > 1 Then
p2 = fromBase(Left(s4$, 2), bse)
If prmdiv(p2) = p2 Then
p3 = fromBase(Left(s4$, 3), bse)
If prmdiv(p3) = p3 Then
Print #2, bse & " " & s4 & " " & p1 & Str(p2) & Str(p3) & Str(p)
End If
End If
End If
End If
p = nxtprm(p)
Loop Until p > fin
Next bse
|
Posted by Charlie
on 2016-03-03 20:09:20 |