
diff -r 45bcdc34bf73 -r 56aa2efbf7d9 day1/session3.tex
--- a/day1/session3.tex	Tue Dec 29 19:26:13 2009 +0530
+++ b/day1/session3.tex	Mon Jan 04 19:08:48 2010 +0530
@@ -147,7 +147,7 @@
   ....     point = line.split()
   ....     l = float(point[0])
   ....     t = float(point[1])
-  ....     g = 4 * pi * pi * l / t * t
+  ....     g = 4 * pi * pi * l / (t * t)
   ....     G.append(g)
   \end{lstlisting}
 \end{frame}
@@ -166,8 +166,8 @@
 for g in G:
     total += g
 
-g_mean = total / len(g)
-print "Mean: ", g_mean
+g_mean = total / len(G)
+print 'Mean: ', g_mean
   \end{lstlisting}
 \end{frame}
 
@@ -175,7 +175,7 @@
   \frametitle{Mean ``g''}
   \begin{lstlisting}
 g_mean = sum(G) / len(G)
-print "Mean: ", g_mean
+print 'Mean: ', g_mean
   \end{lstlisting}
 \end{frame}
 
@@ -183,7 +183,7 @@
   \frametitle{Mean ``g''}
   \begin{lstlisting}
 g_mean = mean(G)
-print "Mean: ", g_mean
+print 'Mean: ', g_mean
   \end{lstlisting}
   \inctime{10}
 \end{frame}
@@ -277,11 +277,11 @@
 \begin{frame}[fragile]
   \frametitle{Dictionaries \ldots}
   \begin{lstlisting}
-In []: d = {"jpg" : "image file",
-      "txt" : "text file", 
-      "py" : "python code"}
+In []: d = {'jpg' : 'image file',
+      'txt' : 'text file', 
+      'py' : 'python code'}
 
-In []: d["txt"]
+In []: d['txt']
 Out[]: 'text file'
   \end{lstlisting}
 \end{frame}
@@ -289,10 +289,10 @@
 \begin{frame}[fragile]
   \frametitle{Dictionaries \ldots}
   \begin{lstlisting}
-In []: "py" in d
+In []: 'py' in d
 Out[]: True
 
-In []: "cpp" in d
+In []: 'cpp' in d
 Out[]: False
   \end{lstlisting}
 \end{frame}
@@ -417,11 +417,11 @@
 \begin{frame}[fragile]
   \frametitle{Obtaining statistics}
   \begin{lstlisting}
-print "Mean: ", mean(math_scores)
+print 'Mean: ', mean(math_scores)
 
-print "Median: ", median(math_scores)
+print 'Median: ', median(math_scores)
 
-print "Standard Deviation: ",
+print 'Standard Deviation: ',
               std(math_scores)
   \end{lstlisting}
   \inctime{10}
@@ -432,11 +432,11 @@
   \begin{lstlisting}
 math_array = array(math_scores)
 
-print "Mean: ", mean(math_array)
+print 'Mean: ', mean(math_array)
 
-print "Median: ", median(math_array)
+print 'Median: ', median(math_array)
 
-print "Standard Deviation: ",
+print 'Standard Deviation: ',
               std(math_array)
   \end{lstlisting}
   \inctime{5}




