YouTube

Got a YouTube account?

New: enable viewer-created translations and captions on your YouTube channel!

English subtitles

← Course 1 - Maze Loops

Get Embed Code
2 Languages

Showing Revision 2 created 02/26/2017 by 奕德 余.

  1. one thing that computers are really good
  2. at is repeating commands as a person you
  3. get really bored if you had to do the
  4. same thing lots of times in a row but a
  5. computer can do the same thing millions
  6. or even billions of times and not get
  7. bored and be able to carry that out
  8. really well
  9. so for example if I wanted to wish
  10. everyone on facebook a happy birthday by
  11. sending them an email it might take me
  12. more than a century to actually write
  13. out all of those emails to everyone but
  14. with just a few lines of code i can have
  15. a system send an email to everyone on
  16. facebook wishing them a happy birthday
  17. so that's what loops are and why they're
  18. valuable and something that computers
  19. can do very well in this example your
  20. goal is going to be to move the bird now
  21. we're going to be able to use the repeat
  22. block in order to be able to do this
  23. very easily you can either do this by
  24. giving the computer and move forward
  25. command five times in order to advance
  26. the the bird one step each time to the
  27. pig or you can just tell the computer to
  28. move forward once and then tell it to
  29. repeat that five times and it will do
  30. the same thing so in order to do this
  31. you drag your move forward command and
  32. then you put it inside the repeat block
  33. and you can click on it and tell it how
  34. many times you want to repeat the block
  35. to tell how many steps you wanted to
  36. take forward now one more thing is you
  37. can put as many commands as you want
  38. inside the repeat block so in this
  39. example your tongue it to move forward
  40. and turn left which will do five times
  41. alright good job and have fun