RosettaCodeData/Task/Constrained-random-points-on-a-circle/BBC-BASIC/constrained-random-points-on-a-circle.basic

9 lines
194 B
Text
Raw Permalink Normal View History

2023-07-01 11:58:00 -04:00
MODE 8
ORIGIN 640, 512
FOR i% = 1 TO 1000
x% = RND(31)-16
y% = RND(31)-16
r = SQR(x%^2 + y%^2)
IF r >= 10 IF r <= 15 PLOT x%*2, y%*2
NEXT