equal
deleted
inserted
replaced
224 \end{frame} |
224 \end{frame} |
225 |
225 |
226 \section{Lists} |
226 \section{Lists} |
227 \begin{frame}[fragile] |
227 \begin{frame}[fragile] |
228 \frametitle{How to create the data?} |
228 \frametitle{How to create the data?} |
229 What are \typ{x} and \typ{y} here??\\ |
229 What were \typ{x} and \typ{y}??\\ |
230 \begin{center} |
230 \begin{center} |
231 \alert{\typ{lists!!}} |
231 \alert{\typ{lists!!}} |
232 \end{center} |
232 \end{center} |
233 \begin{lstlisting} |
233 \begin{lstlisting} |
234 In []: mtlist = [] #Empty List |
234 In []: mtlist = [] #Empty List |
424 \begin{frame}[fragile] |
424 \begin{frame}[fragile] |
425 \frametitle{Reading files \ldots} |
425 \frametitle{Reading files \ldots} |
426 \typ{In []: for line in open('pendulum.txt'):} |
426 \typ{In []: for line in open('pendulum.txt'):} |
427 \begin{itemize} |
427 \begin{itemize} |
428 \item opening file `pendulum.txt' |
428 \item opening file `pendulum.txt' |
429 \item iterating through file using variable \typ{line} |
429 \item iterating through the file by reading each line into variable \typ{line} |
430 \item \typ{line} is a \kwrd{string} variable |
430 \item \typ{line} is a \kwrd{string} variable |
431 \end{itemize} |
431 \end{itemize} |
432 \end{frame} |
432 \end{frame} |
433 |
433 |
434 \section{Strings} |
434 \section{Strings} |