Anonymous user
Community Data Science Workshops (Fall 2014)/Day 1 lecture: Difference between revisions
Community Data Science Workshops (Fall 2014)/Day 1 lecture (view source)
Revision as of 17:34, 8 November 2014
, 9 years ago→loops and more flow control
imported>Mako |
imported>Mako |
||
Line 92:
* <tt>if</tt> statements inside <tt>for</tt> loops
** e.g., <code>if name[0] in "AEIOU"</code> then print "starts with a vowel"
** show we can test
** add an else statement to capture words that start with a consonant
* nested <tt>for</tt> loops
* <tt>range()</tt>
|