From 7082f840a48d17e1aa262b2fd504f8132b1986e4 Mon Sep 17 00:00:00 2001
From: Prabhu Ramachandran
Date: Wed, 8 Feb 2017 22:04:31 +0530
Subject: Fix several mistakes and update practice_ds.

---
 basic_python/practice_control_flow.tex | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

(limited to 'basic_python/practice_control_flow.tex')

diff --git a/basic_python/practice_control_flow.tex b/basic_python/practice_control_flow.tex
index 5ce053f..4fa966b 100644
--- a/basic_python/practice_control_flow.tex
+++ b/basic_python/practice_control_flow.tex
@@ -138,6 +138,7 @@ from __future__ import print_function
   \item Use a while loop to generate the numbers from 1 to 10
   \item If a number divisible by 3 is found, print ***
   \item If a number divisible by 5 is found, print *****
+  \item Otherwise just print the number
   \end{enumerate}
 \end{frame}
 
@@ -295,7 +296,7 @@ from __future__ import print_function
 \begin{lstlisting}
   from numpy import linspace
   n = int(input())
-  data = linspace(0, 1, n)
+  data = linspace(1, 2, n)
   for x in data:
       print(x)
 \end{lstlisting}
@@ -305,7 +306,7 @@ from __future__ import print_function
 \begin{frame}[plain,fragile]
   \frametitle{\typ{for} loop over list 2}
   \begin{enumerate}
-  \item Ask the user for an list of fruits separated by a space
+  \item Ask the user for an list of fruits separated by a comma
   \item Print each fruit in a separate line
   \end{enumerate}
   For example let us say user enters \typ{apple, pear}, print
@@ -365,7 +366,7 @@ from __future__ import print_function
 \begin{frame}[fragile,plain]
 \frametitle{Solution}
 \begin{lstlisting}
-  n = input()
+  n = int(input())
   for i in range(n):
       for j in range(n):
           print(i+j, end=' ')
-- 
cgit 

