Skip to content

Instantly share code, notes, and snippets.

@annajmorton
Last active June 2, 2016 21:50
Show Gist options
  • Save annajmorton/e4c8abd45468c27859445bc46d6cefb2 to your computer and use it in GitHub Desktop.
Save annajmorton/e4c8abd45468c27859445bc46d6cefb2 to your computer and use it in GitHub Desktop.
3.3.3-3.3.4 Notes - 06/02/2016

#Loops

##review questions

  1. what do loops represent (i.e. what is their duty)?

  2. what is a counter? how is it use?

  3. what are the three critical components of a fully defined loop? (hint: think the three arguments a for loop takes i.e.

    for( arg 1, arg 2, arg 3) {
    
    }

##exercise 3.3.4 #2 deep dive the following diagram (tries to) explain how the output pattern relates to the nested loop solution: ![](kings6_nested-loops

##more loop practice ... more loop practice ... more loop practice

  1. online loop quiz
  2. create a program using loops that prints the fibonacci sequence

#Break and Continue review question: what is the difference between break and continue?

#Solutions to all the exercises in section 3.3

  1. 3.3.1 If Else
  2. 3.3.2 Switch
  3. 3.3.3 While
  4. 3.3.4 For
  5. 3.3.5 Break Continue
@annajmorton
Copy link
Author

kings6_nested-loops

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment