Logo - Building Some Amusing Procedures

Try these out!  Just copy and paste them into your Execute window.  What happens if you flipped a coin, walked and turned a random angle?  Let's see where you would turn up after 10,000 coin flips!  What kind of shape will result if you use trigonometric calculations?

Logo Procedure What it does!
Execute the command: Repeat 10000 [FD Random 10 LT Random 90]
  • Click on the Logo Procedure Random_walk
  • Execute the command: Repeat 100000 [Random_Walk]
  • Try repeating the command a few more times!
  • Execute this command: for [step 10 80 5] [repeat 5 [repeat 8 [fd :step rt 45] rt 72]
  • What changes do you see if you change the number of repeats
  • Execute this : repeat 360 [setxy (sin(89 * repcount)) * 150 (sin(179 * repcount)) * 150]
  • Change the sin ( short for sine ) values and see what shape you get!
  • Execute this command: repeat 5100 [fd 5 rt arctan (remainder repcount 100) / 100]