From 0b8f4c755c894f4dd8b035c5e4a618c271831120 Mon Sep 17 00:00:00 2001 From: erik Date: Fri, 2 May 2014 15:05:46 -0700 Subject: [PATCH] Reversed the episodes list order to match the loop count with the actual episode number. --- episode15/codingYouTube101.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/episode15/codingYouTube101.py b/episode15/codingYouTube101.py index 8510bc7..28526b5 100644 --- a/episode15/codingYouTube101.py +++ b/episode15/codingYouTube101.py @@ -68,8 +68,10 @@ while run: # Print the loop count & title # The count is converted into a str, and right justified print ' {0}. {1}'.format(str(count).rjust(2), episodeInfo[0]) - # Increment the loop count, same as: count = count + 1 - count += 1 + # Increment the loop count, unless we're on the last episode + if (count + 1) < len(episodes): + # Same as: count = count + 1 + count += 1 print