diff -r 018b9c12ee1f -r f7bcb27d1940 slides/slides02.tex --- a/slides/slides02.tex Fri Nov 09 07:30:02 2018 +0000 +++ b/slides/slides02.tex Thu Nov 15 03:35:38 2018 +0000 @@ -38,10 +38,9 @@ \begin{center} \begin{tabular}{ll} Email: & christian.urban at kcl.ac.uk\\ - Office: & N7.07 (North Wing, Bush House)\\ + Office: & N\liningnums{7.07} (North Wing, Bush House)\\ Slides \& Code: & KEATS\medskip\\ - Scala Office & \\ - Hours: & Thursdays 11 -- 13\\ + Office Hours: & Mondays 12:00 -- 14:00\\ \end{tabular} \end{center} @@ -49,56 +48,28 @@ \end{frame} %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -\begin{frame}[t,fragile] - \frametitle{Mea Culpa} -\bigskip - -\mbox{\hspace{-4mm}}CW6, Part 3 (deadline 21 December)\bigskip\medskip -\small -\begin{lstlisting}[language=Scala, numbers=none, xleftmargin=-4mm] -val blchip_portfolio = - List("GOOG", "AAPL", "MSFT", "IBM", "FB", - "YHOO", "AMZN", "BIDU") - -val rstate_portfolio = -List("PLD", "PSA", "AMT", "AIV", "AVB", - "BXP", "CBG", "CCI", - "DLR", "EQIX", "EQR", "ESS", "EXR", - "FRT", "GGP", "HCP") -\end{lstlisting}\bigskip - -\onslide<2>{The results in the CW are calculated with YHOO and CBG deleted.} +\begin{frame}[c,fragile] +\frametitle{Scala on Lab Computers} -\only<2>{ -\begin{textblock}{6}(8.5,6.6) - \begin{tikzpicture} - \node (B0) at (0,0) {}; - \node (B1) at (0,0.5) {}; - \node (B2) at (1.2,0) {}; - \node (B3) at (1.2,0.5) {}; - \draw [red,line width=1mm] (B0) -- (B3); - \draw [red,line width=1mm] (B1) -- (B2); - \end{tikzpicture} -\end{textblock}} +\begin{lstlisting}[language={},numbers=none, + basicstyle=\ttfamily\small,xleftmargin=-2mm] +$ /usr/share/scala/bin/scala + +Welcome to Scala 2.12.6 (Java HotSpot(TM) 64-Bit +Server VM, Java 10.0.1). Type in expressions for +evaluation. Or try :help. -\only<2>{ -\begin{textblock}{6}(10.5,9.9) - \begin{tikzpicture} - \node (B0) at (0,0) {}; - \node (B1) at (0,0.5) {}; - \node (B2) at (1.2,0) {}; - \node (B3) at (1.2,0.5) {}; - \draw [red,line width=1mm] (B0) -- (B3); - \draw [red,line width=1mm] (B1) -- (B2); - \end{tikzpicture} -\end{textblock}} +scala> +\end{lstlisting}%$ + \end{frame} %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \begin{frame}[c] -\frametitle{Mea Culpa 2} +\frametitle{Scala on Lab Computers} Avoid at all costs, even in comments @@ -113,6 +84,7 @@ \end{frame} %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \begin{frame}[t] \frametitle{For-Comprehensions Again}