RosettaCodeData/Task/Babbage-problem/Run-BASIC/babbage-problem.basic

7 lines
161 B
Text
Raw Permalink Normal View History

2023-07-01 11:58:00 -04:00
for n = 1 to 1000000
if n^2 MOD 1000000 = 269696 then exit for
next
PRINT "The smallest number whose square ends in 269696 is "; n
PRINT "Its square is "; n^2