| 308 |      1 | % !TEX program = xelatex
 | 
| 22 |      2 | \documentclass[dvipsnames,14pt,t,xelatex]{beamer}
 | 
|  |      3 | \usepackage{../slides}
 | 
| 32 |      4 | \usepackage{../graphics}
 | 
| 22 |      5 | \usepackage{../langs}
 | 
|  |      6 | %\usepackage{../data}
 | 
|  |      7 | 
 | 
|  |      8 | \hfuzz=220pt 
 | 
|  |      9 | 
 | 
|  |     10 | %\setmonofont[Scale=.88]{Consolas}
 | 
|  |     11 | %\newfontfamily{\consolas}{Consolas}
 | 
|  |     12 | 
 | 
|  |     13 | \lstset{language=Scala,
 | 
|  |     14 |         style=mystyle,
 | 
|  |     15 |         numbersep=0pt,
 | 
|  |     16 |         numbers=none,
 | 
|  |     17 |         xleftmargin=0mm}
 | 
|  |     18 | 
 | 
|  |     19 | \newcommand{\bl}[1]{\textcolor{blue}{#1}}     
 | 
|  |     20 | 
 | 
|  |     21 | % beamer stuff 
 | 
| 195 |     22 | \renewcommand{\slidecaption}{PEP (Scala) \liningnums{01}, King's College London}
 | 
| 22 |     23 | 
 | 
| 278 |     24 | %https://insights.stackoverflow.com/survey/2019#technology-most-loved-dreaded-and-wanted
 | 
| 22 |     25 | 
 | 
|  |     26 | \begin{document}
 | 
|  |     27 | 
 | 
|  |     28 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 | 
|  |     29 | \begin{frame}[t]
 | 
|  |     30 | \frametitle{%
 | 
|  |     31 |   \begin{tabular}{@ {}c@ {}}
 | 
|  |     32 |   \\[5mm]
 | 
| 199 |     33 |   \hspace{7mm}\huge PEP Scala (\liningnums{1}) 
 | 
| 22 |     34 |   \end{tabular}}
 | 
|  |     35 | 
 | 
|  |     36 |   \normalsize
 | 
|  |     37 |   \begin{center}
 | 
|  |     38 |   \begin{tabular}{ll}
 | 
| 137 |     39 |     Email:  & christian.urban at kcl.ac.uk\\
 | 
| 195 |     40 |     Office: & N\liningnums{7.07} (North Wing, Bush House)\\
 | 
| 137 |     41 |     Slides \& Code: & KEATS\medskip\\
 | 
| 308 |     42 |     Office Hours: &  Thursdays 12:00 -- 14:00\\
 | 
|  |     43 |     Additionally: & (for Scala) Tuesdays 10:45 -- 11:45\\ 
 | 
| 22 |     44 |   \end{tabular}
 | 
|  |     45 |   \end{center}
 | 
|  |     46 | 
 | 
| 199 |     47 |   %\tiny
 | 
|  |     48 |   %developed since 2004 bv Martin Odersky
 | 
|  |     49 |   %picture about assignments
 | 
|  |     50 | 
 | 
|  |     51 | \begin{textblock}{6}(0.5,0.5)
 | 
|  |     52 | \includegraphics[scale=0.035]{../pics/assign.jpg}\\[-1mm]
 | 
|  |     53 | \end{textblock}
 | 
| 22 |     54 | 
 | 
|  |     55 | \end{frame}
 | 
|  |     56 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%     
 | 
|  |     57 | 
 | 
|  |     58 | 
 | 
|  |     59 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 | 
|  |     60 | \begin{frame}[c]
 | 
|  |     61 | \frametitle{Why Scala?}
 | 
|  |     62 | 
 | 
| 23 |     63 | \begin{textblock}{6}(3,4)
 | 
| 22 |     64 | \begin{tabular}{l}
 | 
|  |     65 | \mbox{}\hspace{-1mm}\includegraphics[scale=0.36]{../pics/twitter.png}\\[-1mm]
 | 
|  |     66 | \includegraphics[scale=0.30]{../pics/linked.png}\\
 | 
| 141 |     67 | \includegraphics[scale=0.30]{../pics/guardian.jpg}\\[-3mm]
 | 
| 22 |     68 | \mbox{}\hspace{-2mm}\includegraphics[scale=0.38]{../pics/morgan.png}\\[-3mm]
 | 
|  |     69 | \includegraphics[scale=0.30]{../pics/suisse.png}\\
 | 
| 23 |     70 | {\large\bf ...}
 | 
|  |     71 | \end{tabular}
 | 
|  |     72 | \end{textblock}
 | 
|  |     73 | 
 | 
|  |     74 | \begin{textblock}{6}(9,4)
 | 
|  |     75 | \begin{tabular}{l}
 | 
| 22 |     76 | \includegraphics[scale=0.20]{../pics/edf.png}\\[-1mm]
 | 
|  |     77 | \includegraphics[scale=0.08]{../pics/novell.png}\\[-1mm]
 | 
|  |     78 | \includegraphics[scale=0.30]{../pics/foursquare.png}\\
 | 
|  |     79 | \includegraphics[scale=0.30]{../pics/hsbc.png}\\
 | 
|  |     80 | {\large\bf ...}
 | 
|  |     81 | \end{tabular}
 | 
|  |     82 | \end{textblock}
 | 
|  |     83 | 
 | 
| 199 |     84 | 
 | 
|  |     85 | \begin{textblock}{6}(2,12)
 | 
| 308 |     86 | \begin{bubble}[9.4cm]
 | 
| 199 |     87 |   \small
 | 
| 308 |     88 |   developed since 2004 by Martin Odersky
 | 
| 200 |     89 |   (he was behind Generic Java which was included in Java 5
 | 
| 308 |     90 |   \ldots I am using Scala since maybe 2008?)
 | 
| 199 |     91 | \end{bubble}
 | 
|  |     92 | \end{textblock}
 | 
|  |     93 | 
 | 
| 22 |     94 | \end{frame}
 | 
|  |     95 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%     
 | 
|  |     96 | 
 | 
| 174 |     97 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 | 
| 199 |     98 | %\begin{frame}[c]
 | 
|  |     99 | %\frametitle{Why Scala?}
 | 
|  |    100 | %
 | 
|  |    101 | %In the last few years there is  a ``Cambrian explosion'' of
 | 
|  |    102 | %languages from both academia and industry.
 | 
|  |    103 | %
 | 
|  |    104 | %It is essential for students to have skills to pick up new languages
 | 
|  |    105 | %quickly.
 | 
|  |    106 | %
 | 
|  |    107 | %\end{frame}
 | 
| 174 |    108 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
 | 
|  |    109 | 
 | 
| 23 |    110 | 
 | 
|  |    111 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 | 
|  |    112 | \begin{frame}[c]
 | 
|  |    113 | \frametitle{Why Scala?}
 | 
|  |    114 | 
 | 
|  |    115 | \begin{itemize}
 | 
| 34 |    116 | \item compiles to the JVM\\
 | 
|  |    117 |   \textcolor{gray}{(also JavaScript, native X86 in the works)}\medskip
 | 
| 32 |    118 | \item integrates seamlessly with Java\medskip
 | 
| 33 |    119 | \item combines \underline{\bf functional} and {\bf object-oriented} programming\bigskip
 | 
| 308 |    120 | \item it is a bit on the ``theory'' / ``mathematical'' side\\
 | 
| 199 |    121 |   \textcolor{gray}{(no pointers, no \texttt{null}, but expressions)}
 | 
| 34 |    122 |   
 | 
| 33 |    123 | \item often one can write very concise and elegant code
 | 
|  |    124 | \end{itemize}\bigskip\medskip  
 | 
|  |    125 | 
 | 
| 308 |    126 | %\small
 | 
|  |    127 | %alternatives:\\
 | 
|  |    128 | %Elm, Haskell, Ocaml, F$\sharp$, Erlang, ML, Lisp (Racket), \ldots
 | 
| 23 |    129 | 
 | 
|  |    130 | \end{frame}
 | 
| 22 |    131 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
 | 
| 23 |    132 | 
 | 
|  |    133 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 | 
| 308 |    134 | \begin{frame}[t]
 | 
| 32 |    135 | \frametitle{Java vs Scala}
 | 
|  |    136 | 
 | 
| 308 |    137 | {\lstset{language=java,numbers=right}\fontsize{12}{12}\selectfont
 | 
| 32 |    138 | \texttt{\lstinputlisting{Point.java}}}
 | 
|  |    139 | 
 | 
| 308 |    140 | \rule{11cm}{0.3mm}\\[-3mm]
 | 
| 33 |    141 | 
 | 
| 32 |    142 | {\lstset{language=scala}\fontsize{12}{12}\selectfont
 | 
|  |    143 | \texttt{\lstinputlisting{Point.scala}}}
 | 
|  |    144 | 
 | 
|  |    145 | \begin{textblock}{6}(13,3)
 | 
|  |    146 | \textbf{\large Java}
 | 
| 33 |    147 | \end{textblock}
 | 
|  |    148 | 
 | 
| 308 |    149 | \begin{textblock}{6}(13,14.3)
 | 
| 32 |    150 | \textbf{\large Scala}
 | 
|  |    151 | \end{textblock}  
 | 
|  |    152 | 
 | 
|  |    153 | \end{frame}
 | 
|  |    154 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
 | 
|  |    155 | 
 | 
| 33 |    156 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 | 
| 199 |    157 | %\begin{frame}[c]
 | 
|  |    158 | %\frametitle{Scala (imperative) vs Scala (functional)}
 | 
|  |    159 | %
 | 
|  |    160 | %Reham's example
 | 
|  |    161 | %
 | 
|  |    162 | %
 | 
|  |    163 | %\end{frame}
 | 
| 174 |    164 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 | 
|  |    165 | 
 | 
|  |    166 | 
 | 
|  |    167 | 
 | 
|  |    168 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 | 
|  |    169 | \begin{frame}[c]
 | 
| 137 |    170 | \frametitle{First Steps: Scala Tools}
 | 
| 32 |    171 | 
 | 
| 33 |    172 | \begin{itemize}
 | 
| 308 |    173 | \item contains a REPL  
 | 
| 200 |    174 | \item I use VS Code and a Scala extension (M'place)
 | 
| 199 |    175 | \begin{center}  
 | 
|  |    176 | \includegraphics[scale=0.10]{../pics/vscode.png}\\[-10mm]\mbox{}
 | 
|  |    177 | \end{center}\bigskip
 | 
|  |    178 |   
 | 
| 33 |    179 | \item there is a plugin for Eclipse (called Scala IDE)\medskip
 | 
| 137 |    180 | \item there is also a plugin for IntelliJ\medskip
 | 
| 33 |    181 | \end{itemize}  
 | 
|  |    182 | 
 | 
|  |    183 | \end{frame}
 | 
| 137 |    184 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 | 
|  |    185 | 
 | 
|  |    186 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 | 
|  |    187 | \begin{frame}[c]
 | 
|  |    188 |   \frametitle{\bf
 | 
|  |    189 |   \only<1>{\begin{tabular}{l}\\[2mm]Why Scala?\\ \mbox{}\end{tabular}}
 | 
| 200 |    190 |   \only<2->{\begin{tabular}{c}\\[2mm]Why Functional\\[-2mm] Programming?\end{tabular}}
 | 
| 137 |    191 | }
 | 
|  |    192 | 
 | 
|  |    193 |   %
 | 
|  |    194 |   \mbox{}\\[3.5cm]
 | 
|  |    195 |   \small
 | 
| 140 |    196 | Scala, Elm, Haskell, Ocaml, F$\sharp$, Erlang, ML, Lisp (Racket), \ldots 
 | 
| 137 |    197 | 
 | 
|  |    198 | \only<3>{
 | 
|  |    199 | \begin{textblock}{6}(2,6.2)
 | 
|  |    200 | \begin{bubble}[10cm]
 | 
|  |    201 | \normalsize``If you want to see which features will be in mainstream programming
 | 
|  |    202 |   languages tomorrow, then take a look at functional programming
 | 
|  |    203 |   languages today.''\medskip\small\\
 | 
|  |    204 |   \hfill{}---Simon Peyton Jones (works at Microsoft)\\
 | 
|  |    205 |   \hfill{}main developer of the Glasgow Haskell Compiler
 | 
|  |    206 | \end{bubble}
 | 
|  |    207 | \end{textblock}}
 | 
|  |    208 | 
 | 
| 200 |    209 | \only<4>{
 | 
|  |    210 | \begin{textblock}{6}(5,5.8)
 | 
|  |    211 | \hspace{2mm}\includegraphics[scale=0.06]{../pics/assign.jpg}\\[-1mm]
 | 
|  |    212 | \Large\alert{\textbf{Immutability}}
 | 
|  |    213 | \end{textblock}}
 | 
|  |    214 | 
 | 
|  |    215 | 
 | 
| 137 |    216 | \end{frame}
 | 
|  |    217 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 
 | 
|  |    218 | 
 | 
| 200 |    219 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 | 
|  |    220 | \begin{frame}[c, fragile]
 | 
|  |    221 | 
 | 
|  |    222 | {\Large Why bother? or\smallskip\\\hfill What is wrong with this?}\bigskip\bigskip
 | 
|  |    223 | 
 | 
|  |    224 |   
 | 
|  |    225 | \begin{lstlisting}[language=C,numbers=none]
 | 
|  |    226 | for (int i = 10; i < 20; i++) {
 | 
|  |    227 |     
 | 
|  |    228 |   //...Do something interesting
 | 
|  |    229 |   //   with i...
 | 
|  |    230 | 
 | 
|  |    231 | }
 | 
|  |    232 | \end{lstlisting}
 | 
|  |    233 | 
 | 
|  |    234 |   
 | 
|  |    235 | \end{frame}
 | 
|  |    236 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 | 
|  |    237 | 
 | 
|  |    238 | 
 | 
|  |    239 | 
 | 
| 137 |    240 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 
 | 
|  |    241 | \begin{frame}[c]
 | 
|  |    242 | \mbox{}\\[-21mm]\mbox{}  
 | 
|  |    243 | 
 | 
|  |    244 | \begin{center}
 | 
|  |    245 |   \begin{tikzpicture}[scale=1,
 | 
|  |    246 |                       node/.style={
 | 
|  |    247 |                       rectangle,rounded corners=3mm,
 | 
|  |    248 |                       very thick,draw=black!50,
 | 
|  |    249 |                       minimum height=18mm, minimum width=20mm,
 | 
|  |    250 |                       top color=white,bottom color=black!20}]
 | 
|  |    251 | 
 | 
|  |    252 |   \onslide<1-10>{                
 | 
|  |    253 |   \node (A) at (0,0) [node]
 | 
|  |    254 |      {\mbox{\includegraphics[scale=0.15]{../pics/cplus2.jpg}}};
 | 
|  |    255 |   \node [above right] at (A.north west) {1986};}
 | 
|  |    256 | 
 | 
|  |    257 |   \onslide<2->{
 | 
|  |    258 |   \node (B) at (3.5,0) [node]
 | 
|  |    259 |      {\mbox{\includegraphics[scale=0.15]{../pics/robotron.jpg}}};
 | 
|  |    260 |   \node [above right] at (B.north west) {1988, C};
 | 
|  |    261 |   \draw [->,line width=4mm] (A) -- (B);}
 | 
|  |    262 | 
 | 
|  |    263 |   \onslide<3->{
 | 
|  |    264 |   \node (C0) at (6.3,0) {};
 | 
|  |    265 |   \node (C) at (8,0)  [node]
 | 
|  |    266 |      {\mbox{\includegraphics[scale=0.15]{../pics/sun.jpg}}};
 | 
|  |    267 |   \node [above right] at (C.north west) {1992, {\small Linux}};
 | 
|  |    268 |   \draw [->,line width=4mm] (B) -- (C0);
 | 
|  |    269 |   \draw [->,line width=4mm] (C0) -- (C);}
 | 
|  |    270 | 
 | 
|  |    271 |   \onslide<4->{
 | 
|  |    272 |   \node (D) at (8,-3.3)  [node]
 | 
|  |    273 |      {\mbox{\includegraphics[scale=0.2]{../pics/gateway.jpg}}};
 | 
|  |    274 |   \draw [->,line width=4mm] (C) -- (D);
 | 
|  |    275 |   \node [below right] at (D.south west) {1996};}
 | 
|  |    276 | 
 | 
|  |    277 |   \onslide<5->{
 | 
|  |    278 |   \node (E) at (4,-3.3)  [node]
 | 
|  |    279 |      {\mbox{\includegraphics[scale=0.1]{../pics/appleg4.jpg}}};
 | 
|  |    280 |   \draw [->,line width=4mm] (D) -- (E);
 | 
|  |    281 |   \node [above right] at (E.north west) {2000};}   
 | 
|  |    282 | 
 | 
|  |    283 |   \onslide<6->{
 | 
|  |    284 |   \node (F0) at (1.5,-3.3) {};
 | 
|  |    285 |   \node (F1) at (1,-3.3) {};
 | 
|  |    286 |   \node (F) at (-0.9,-3.3)  [node]
 | 
|  |    287 |      {\mbox{\includegraphics[scale=0.3]{../pics/appleair.png}}};
 | 
|  |    288 |   \draw [->,line width=4mm] (E) -- (F0);
 | 
|  |    289 |   \draw [->,line width=4mm] (F1) -- (F);   
 | 
|  |    290 |   \node [above right] at (F.north west) {2012?};}   
 | 
|  |    291 | 
 | 
|  |    292 |   \onslide<7->{
 | 
|  |    293 |   \node (G) at (-0.9,-6.3)  [node]
 | 
|  |    294 |      {\mbox{\includegraphics[scale=0.02]{../pics/applepro.jpg}}};
 | 
|  |    295 |   \draw [->,line width=4mm] (F) -- (G);
 | 
|  |    296 |   \node [right] at (G.west) {\hspace{22mm}2017};}   
 | 
|  |    297 |   
 | 
|  |    298 |   \end{tikzpicture}
 | 
|  |    299 |   \end{center}
 | 
|  |    300 | 
 | 
|  |    301 | 
 | 
|  |    302 |   \only<1>{%  
 | 
|  |    303 |     \begin{textblock}{10}(2.5,5)  
 | 
|  |    304 |       \includegraphics[scale=0.26]{../pics/cplus1.jpg}\\
 | 
|  |    305 |       \footnotesize 64K RAM, no HD, no monitor, lots of cables
 | 
|  |    306 |     \end{textblock}
 | 
|  |    307 |     \begin{textblock}{6}(10.9,4.5)  
 | 
|  |    308 |       \includegraphics[scale=0.09]{../pics/mand1.png}
 | 
|  |    309 |       \includegraphics[scale=0.09]{../pics/mand2.png}
 | 
|  |    310 |     \end{textblock}
 | 
|  |    311 |     \begin{textblock}{6}(10.8,2.2)  
 | 
|  |    312 |     \huge\bf 3 days
 | 
|  |    313 |     \end{textblock}
 | 
|  |    314 |   }
 | 
|  |    315 |   \only<8->{%
 | 
|  |    316 |   \begin{textblock}{8}(5.8,11.6)  
 | 
|  |    317 |     \large\bf
 | 
|  |    318 |     \begin{tabular}{l@{}l}
 | 
|  |    319 |       1986:\, & no Internet\\
 | 
|  |    320 |             & no Amazon\\
 | 
|  |    321 |             & no FB, no mobiles,\ldots\\ 
 | 
|  |    322 |     \end{tabular}         
 | 
|  |    323 |     \end{textblock}
 | 
|  |    324 |   }
 | 
|  |    325 |   \only<9>{
 | 
|  |    326 |   \begin{textblock}{1}(3,3)
 | 
|  |    327 |     \begin{bubble}[9cm]  
 | 
|  |    328 |       \begin{tabular}{@{\hspace{8mm}}llll@{\hspace{8mm}}}
 | 
|  |    329 |         \\
 | 
| 200 |    330 |       \multicolumn{4}{c}{\alert{\bf Speedup by Moore's Law}}\medskip\\
 | 
| 137 |    331 |       \textbf{1986:} & 3 days    & \textbf{1996:} & 135 mins\\
 | 
|  |    332 |       \textbf{1988:} & 1.5 days  & \textbf{1998:} & 67 mins\\
 | 
|  |    333 |       \textbf{1990:} & 18 hs     & \textbf{2000:} & 33 mins\\
 | 
|  |    334 |       \textbf{1992:} & 9 hs      & \textbf{2002:} & 16 mins\\
 | 
|  |    335 |       \textbf{1994:} & 4.5 hs    & \multicolumn{2}{c}{???}\\                    
 | 
|  |    336 |       \\
 | 
|  |    337 |       \end{tabular}
 | 
|  |    338 |       \small Every two years, computers got twice as powerful.
 | 
|  |    339 |   \end{bubble}
 | 
|  |    340 |   \end{textblock}}
 | 
|  |    341 | 
 | 
|  |    342 | \end{frame}
 | 
|  |    343 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 | 
|  |    344 | 
 | 
|  |    345 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 | 
|  |    346 | \begin{frame}[c]
 | 
| 200 |    347 | \frametitle{Seq \;vs\; Par}
 | 
| 137 |    348 | 
 | 
|  |    349 | \begin{center}
 | 
|  |    350 |   \begin{tabular}[t]{@{}l@{}l@{}}
 | 
| 200 |    351 |     \includegraphics[scale=0.14]{../pics/mand4.png} & \hspace{4mm}
 | 
|  |    352 |     \raisebox{0mm}{\includegraphics[scale=0.14]{../pics/mand3.png}}\\
 | 
|  |    353 |     \hspace{6mm}\includegraphics[scale=0.5]{../pics/cpu2.png} &
 | 
|  |    354 |     \hspace{11mm}\includegraphics[scale=0.5]{../pics/cpu1.png}
 | 
| 137 |    355 |   \end{tabular}     
 | 
|  |    356 | \end{center}  
 | 
|  |    357 | 
 | 
|  |    358 | \only<2>{
 | 
|  |    359 |   \begin{textblock}{5}(12,2)
 | 
|  |    360 |     \begin{bubble}[2.1cm]
 | 
|  |    361 |       \footnotesize{}in Java or C++\\
 | 
|  |    362 |       \includegraphics[scale=0.50]{../pics/skeleton.jpg}\\
 | 
|  |    363 |     \end{bubble}  
 | 
|  |    364 |   \end{textblock}}
 | 
|  |    365 | 
 | 
|  |    366 | \only<3>{
 | 
| 200 |    367 |   \begin{textblock}{14.2}(1,13.5)
 | 
| 140 |    368 |     In FP: Once a variable is created, it is assigned a value and then
 | 
| 308 |    369 |     never changed again $\Rightarrow$ no synchronisation needed\smallskip\\
 | 
| 200 |    370 |     %%\small\textcolor{gray}{(Andrew's second favourite feature of C++)}
 | 
| 137 |    371 |   \end{textblock}}
 | 
|  |    372 | 
 | 
|  |    373 | \end{frame}
 | 
|  |    374 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%  
 | 
|  |    375 | 
 | 
|  |    376 | 
 | 
|  |    377 | 
 | 
| 32 |    378 | 
 | 
|  |    379 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 | 
|  |    380 | \begin{frame}[c]
 | 
| 23 |    381 | \frametitle{Types}
 | 
|  |    382 | 
 | 
|  |    383 | \begin{itemize}
 | 
| 33 |    384 | \item Base types\smallskip
 | 
| 23 |    385 | 
 | 
| 33 |    386 |   \begin{tabular}{@{}l@{}}
 | 
| 23 |    387 |     \textcolor{codegreen}{\texttt{Int}},
 | 
|  |    388 |     \textcolor{codegreen}{\texttt{Long}},
 | 
|  |    389 |     \textcolor{codegreen}{\texttt{BigInt}},
 | 
|  |    390 |     \textcolor{codegreen}{\texttt{Float}},
 | 
|  |    391 |     \textcolor{codegreen}{\texttt{Double}}\\
 | 
|  |    392 |     \textcolor{codegreen}{\texttt{String}},
 | 
| 25 |    393 |     \textcolor{codegreen}{\texttt{Char}}\\
 | 
|  |    394 |     \textcolor{codegreen}{\texttt{Boolean}}
 | 
| 23 |    395 |   \end{tabular}
 | 
|  |    396 | 
 | 
| 33 |    397 | \item Compound types \smallskip   
 | 
| 23 |    398 | 
 | 
| 33 |    399 |   \begin{tabular}{@{}ll@{}}
 | 
| 23 |    400 |     \textcolor{codegreen}{\texttt{List[Int]}}     & lists of Int's \\
 | 
|  |    401 |     \textcolor{codegreen}{\texttt{Set[Double]}}   & sets of Double's \\
 | 
|  |    402 |     \textcolor{codegreen}{\texttt{(Int, String)}} & Int-String pair\\
 | 
|  |    403 |     \textcolor{codegreen}{\texttt{List[(BigInt, String)]}} &
 | 
|  |    404 |                                       lists of BigInt-String\\
 | 
|  |    405 |                                       & pairs\\
 | 
| 200 |    406 |     \textcolor{codegreen}{\texttt{List[List[Int]]}} & list of lists of Int's\\      \textcolor{codegreen}{\texttt{Option[Int]}}     & options of Int's \\                            
 | 
| 23 |    407 |   \end{tabular}
 | 
|  |    408 | 
 | 
|  |    409 | \end{itemize}  
 | 
|  |    410 | 
 | 
|  |    411 | \end{frame}
 | 
|  |    412 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
 | 
|  |    413 | 
 | 
| 32 |    414 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 | 
| 200 |    415 | %\begin{frame}[c]
 | 
|  |    416 | %\frametitle{An Http Request}
 | 
| 32 |    417 |   
 | 
| 200 |    418 | %\begin{textblock}{1}(2,5)
 | 
|  |    419 | %\begin{tabular}{c}
 | 
|  |    420 | %\includegraphics[scale=0.15]{../pics/servers.png}\\[-2mm]
 | 
|  |    421 | %\small Server
 | 
|  |    422 | %\end{tabular}
 | 
|  |    423 | %\end{textblock}
 | 
| 32 |    424 | 
 | 
| 200 |    425 | %\begin{textblock}{1}(5.6,4)
 | 
|  |    426 | %  \begin{tikzpicture}[scale=1.1]
 | 
|  |    427 | %  \draw[white] (0,1) node (X) {};
 | 
|  |    428 | %  \draw[white] (2,1) node (Y) {};
 | 
|  |    429 | %   \draw[white] (0,0) node (X1) {};
 | 
|  |    430 | %  \draw[white] (2,0) node (Y1) {};
 | 
|  |    431 | %   \draw[white] (0,-1) node (X2) {};
 | 
|  |    432 | %  \draw[white] (2,-1) node (Y2) {};
 | 
|  |    433 | %  \draw[red, <-, line width = 2mm] (X) -- (Y);
 | 
|  |    434 | %  \node [inner sep=5pt,label=above:\textcolor{black}{GET request}] at ($ (X)!.5!(Y) $) {};
 | 
|  |    435 | %  \draw[red, ->, line width = 2mm] (X1) -- (Y1);
 | 
|  |    436 | %  \node [inner sep=5pt,label=above:\textcolor{black}{webpage}] at ($ (X1)!.5!(Y1) $) {};
 | 
|  |    437 | %  \draw[red, <-, line width = 2mm] (X2) -- (Y2);
 | 
|  |    438 | %  \node [inner sep=7pt,label=above:\textcolor{black}{POST data}] at ($ (X2)!.5!(Y2) $) {};
 | 
|  |    439 | %  \end{tikzpicture}
 | 
|  |    440 | %\end{textblock}
 | 
| 32 |    441 | 
 | 
|  |    442 | 
 | 
| 200 |    443 | %\begin{textblock}{1}(9,5.5)
 | 
|  |    444 | %\begin{tabular}{c}
 | 
|  |    445 | %\includegraphics[scale=0.15]{../pics/laptop.png}\\[-2mm]
 | 
|  |    446 | %\small Browser
 | 
|  |    447 | %\end{tabular}
 | 
|  |    448 | %\end{textblock}
 | 
|  |    449 | %\end{frame}
 | 
| 32 |    450 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
 | 
|  |    451 | 
 | 
|  |    452 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 | 
| 200 |    453 | %\begin{frame}[c]
 | 
|  |    454 | %
 | 
|  |    455 | %{\lstset{language=Java}\fontsize{7}{8}\selectfont
 | 
|  |    456 | %\texttt{\lstinputlisting{URLReader.java}}}
 | 
|  |    457 | %
 | 
|  |    458 | %\end{frame}
 | 
| 32 |    459 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
 | 
|  |    460 | 
 | 
| 33 |    461 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 | 
|  |    462 | \begin{frame}[c]
 | 
| 140 |    463 | \frametitle{Coursework}
 | 
|  |    464 | 
 | 
|  |    465 | \begin{itemize}
 | 
| 200 |    466 | \item Sorry, I might have been a bit wordy:\\
 | 
| 308 |    467 |   Part 6 of CW description is 7 pages, but
 | 
|  |    468 |   I only needed \mbox{< 100} loc for \emph{all} Part 6.\bigskip
 | 
| 140 |    469 | 
 | 
| 308 |    470 | \item there is feedback when pushing code to github\medskip
 | 
| 140 |    471 | 
 | 
| 200 |    472 | \item there are \texttt{jar}-files you can use to test my implementation\bigskip
 | 
|  |    473 |   
 | 
| 308 |    474 | \item we want you to learn FP!\\ \alert{\bf no vars}, no mutable
 | 
|  |    475 |   data-structures\\ e.g.~no \texttt{Arrays}, no \texttt{ListBuffer}
 | 
| 140 |    476 | \end{itemize}
 | 
|  |    477 | \end{frame}
 | 
|  |    478 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 | 
|  |    479 | 
 | 
|  |    480 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%     
 | 
|  |    481 | 
 | 
|  |    482 | \begin{frame}[c, fragile]
 | 
|  |    483 | \frametitle{The Joy of Immutability}
 | 
|  |    484 | 
 | 
|  |    485 | \begin{itemize}
 | 
|  |    486 | \item If you need to manipulate some data in a list say, then you make
 | 
|  |    487 |   a new list with the updated values, rather than revise the original
 | 
|  |    488 |   list. Easy!\medskip
 | 
|  |    489 | 
 | 
|  |    490 |   {\small
 | 
|  |    491 |   \begin{lstlisting}[language=Scala, numbers=none, xleftmargin=-1mm]
 | 
|  |    492 |     val old_list = List(1, 2, 3, 5)
 | 
|  |    493 |     val new_list = 0 :: old_list
 | 
| 308 |    494 |                 // -> List(0, 1, 2, 3, 4, 5)
 | 
| 140 |    495 |   \end{lstlisting}}  
 | 
|  |    496 |   
 | 
| 200 |    497 | \item You do not have to be defensive about who can access the data.
 | 
|  |    498 | 
 | 
|  |    499 | \item You can look at your code in isolation.  
 | 
| 140 |    500 | \end{itemize}  
 | 
|  |    501 | \end{frame}
 | 
|  |    502 | 
 | 
|  |    503 | 
 | 
|  |    504 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 | 
|  |    505 | 
 | 
|  |    506 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 | 
|  |    507 | \begin{frame}[t]
 | 
|  |    508 | \frametitle{Email: Hate 'val'}
 | 
|  |    509 | 
 | 
| 308 |    510 | \mbox{}\\[-23mm]\mbox{}
 | 
| 140 |    511 | 
 | 
|  |    512 | \begin{center}
 | 
|  |    513 |   \begin{bubble}[10.5cm]
 | 
|  |    514 |   Subject: \textbf{Hate '\textbf{\texttt{val}}'}\hfill 01:00 AM\medskip\\
 | 
|  |    515 | 
 | 
|  |    516 |   Hello Mr Urban,\medskip\\
 | 
|  |    517 | 
 | 
|  |    518 |   I just wanted to ask, how are we suppose to work
 | 
|  |    519 |   with the completely useless \textbf{\texttt{val}}, that can’t be changed ever? Why is
 | 
|  |    520 |   this rule active at all? I’ve spent 4 hours not thinking on the
 | 
|  |    521 |   coursework, but how to bypass this annoying rule. What’s the whole
 | 
|  |    522 |   point of all these coursework, when we can’t use everything Scala
 | 
|  |    523 |   gives us?!?\medskip\\
 | 
|  |    524 | 
 | 
|  |    525 |   Regards.\\
 | 
|  |    526 |   \mbox{}\hspace{5mm}\textcolor{black!50}{<<deleted>>}\\
 | 
|  |    527 |   \end{bubble}
 | 
|  |    528 | \end{center}
 | 
|  |    529 | 
 | 
|  |    530 | \end{frame}
 | 
|  |    531 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%     
 | 
|  |    532 | 
 | 
|  |    533 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 | 
|  |    534 | \begin{frame}[c]
 | 
|  |    535 | 
 | 
|  |    536 | \mbox{}\\[-25mm]\mbox{}
 | 
|  |    537 | 
 | 
|  |    538 | \begin{center}
 | 
|  |    539 |   \begin{bubble}[10.5cm]
 | 
|  |    540 |   Subject: \textbf{Re: Hate '\textbf{\texttt{val}}'}\hfill 01:02 AM\bigskip\bigskip\\
 | 
|  |    541 | 
 | 
|  |    542 |   \textcolor{black!70}{
 | 
|  |    543 |     \textit{\large<<my usual rant about fp\ldots\\ concurrency bla bla\ldots{} better programs
 | 
|  |    544 |     yada>>}}\bigskip\bigskip\bigskip
 | 
|  |    545 |   
 | 
|  |    546 |   PS: What are you trying to do where you desperately want to use \texttt{var}?
 | 
|  |    547 |   \end{bubble}
 | 
|  |    548 | \end{center}
 | 
|  |    549 | 
 | 
|  |    550 | \end{frame}
 | 
|  |    551 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%     
 | 
|  |    552 | 
 | 
|  |    553 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 | 
|  |    554 | \begin{frame}[c,fragile]
 | 
|  |    555 | 
 | 
|  |    556 | \begin{textblock}{6}(0.5,0.5)
 | 
|  |    557 | \begin{bubble}[11.5cm]
 | 
|  |    558 |   \small  
 | 
|  |    559 |   Subject: \textbf{Re: Re: Hate '\textbf{\texttt{val}}'}\hfill 01:04 AM\medskip\\
 | 
|  |    560 | 
 | 
|  |    561 |   \textbf{Right now my is\_legal function works fine:}
 | 
|  |    562 |   
 | 
|  |    563 | \footnotesize\begin{lstlisting}[language=Scala, numbers=none, xleftmargin=-1mm]
 | 
|  |    564 |  def is_legal(dim: Int, path: Path)(x: Pos): Boolean = {
 | 
|  |    565 |    var boolReturn = false
 | 
|  |    566 |    if(x._1 > dim || x._2 > dim || x._1 < 0 || x._2 < 0) {
 | 
|  |    567 |    else { var breakLoop = false
 | 
|  |    568 |           if(path == Nil) { boolReturn = true }
 | 
|  |    569 |           else { for(i <- 0 until path.length) {
 | 
|  |    570 |                     if(breakLoop == false) {
 | 
|  |    571 |                       if(path(i) == x) {
 | 
|  |    572 |                         boolReturn = true
 | 
|  |    573 |                         breakLoop = true
 | 
|  |    574 |                       }
 | 
|  |    575 |                       else { boolReturn = false }
 | 
|  |    576 |                     } else breakLoop
 | 
|  |    577 |             }
 | 
|  |    578 |           }
 | 
|  |    579 |           boolReturn
 | 
|  |    580 |    }
 | 
|  |    581 | \end{lstlisting}
 | 
|  |    582 | \end{bubble}
 | 
|  |    583 | \end{textblock}
 | 
|  |    584 | 
 | 
|  |    585 | \begin{textblock}{6}(8.2,11.8)
 | 
|  |    586 | \begin{bubble}[5.5cm]\footnotesize\bf
 | 
|  |    587 | \ldots{}but I can’t make it work with boolReturn being val. What approach would
 | 
|  |    588 | you recommend in this case, and is using var in this case justified?
 | 
|  |    589 | \end{bubble}
 | 
|  |    590 | \end{textblock}
 | 
|  |    591 | 
 | 
|  |    592 | \only<2>{
 | 
|  |    593 | \begin{textblock}{6}(0.3,11.8)
 | 
|  |    594 |   \begin{bubble}[3.1cm]
 | 
|  |    595 |     \textbf{Me:}
 | 
|  |    596 |     \raisebox{-12mm}{\includegraphics[scale=0.08]{../pics/throwup.jpg}}
 | 
|  |    597 |   \end{bubble}
 | 
|  |    598 | \end{textblock}}
 | 
|  |    599 | 
 | 
|  |    600 | \end{frame}
 | 
|  |    601 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 
 | 
|  |    602 | 
 | 
|  |    603 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 | 
|  |    604 | \begin{frame}[t,fragile]
 | 
|  |    605 | 
 | 
|  |    606 | \mbox{}\\[-25mm]\mbox{}
 | 
|  |    607 | 
 | 
|  |    608 | \begin{textblock}{6}(0.5,2)
 | 
|  |    609 |   \begin{bubble}[11.5cm]
 | 
|  |    610 |   Subject: \textbf{Re: Re: Re: Hate '\textbf{\texttt{val}}'}\hfill 01:06 AM\bigskip\\
 | 
|  |    611 |   \small
 | 
|  |    612 |   
 | 
|  |    613 |   OK. So you want to make sure that the \texttt{x}-position is not outside the
 | 
|  |    614 |   board....and furthermore you want to make sure that the \texttt{x}-position
 | 
|  |    615 |   is not yet in the path list. How about something like\bigskip
 | 
|  |    616 | 
 | 
|  |    617 | \footnotesize\begin{lstlisting}[language=Scala, numbers=none, xleftmargin=-1mm]
 | 
|  |    618 |  def is_legal(dim: Int, path: Path)(x: Pos): Boolean = 
 | 
|  |    619 |    ...<<some board conditions>>... && !path.contains(x)
 | 
|  |    620 | \end{lstlisting}\bigskip
 | 
|  |    621 |   
 | 
|  |    622 |   \small Does not even contain a \texttt{val}.
 | 
|  |    623 |   \end{bubble}
 | 
|  |    624 | \end{textblock}
 | 
|  |    625 | 
 | 
|  |    626 | \begin{textblock}{6}(7,12)
 | 
|  |    627 | \footnotesize\textcolor{black!50}{(This is all on one line)}
 | 
|  |    628 | \end{textblock}
 | 
|  |    629 | 
 | 
|  |    630 | \end{frame}
 | 
|  |    631 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%     
 | 
|  |    632 | 
 | 
|  |    633 | 
 | 
|  |    634 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 | 
|  |    635 | \begin{frame}[t,fragile]
 | 
|  |    636 | 
 | 
|  |    637 | \mbox{}\\[-15mm]\mbox{}
 | 
|  |    638 | 
 | 
|  |    639 | \begin{textblock}{6}(1,3)
 | 
|  |    640 |   \begin{bubble}[10.5cm]
 | 
|  |    641 |     Subject: \textbf{Re: Re: Re: Re: Hate '\textbf{\texttt{val}}'}\hfill 11:02 AM\bigskip\bigskip\\
 | 
|  |    642 |     
 | 
|  |    643 |     THANK YOU! You made me change my coding perspective. Because of you,
 | 
|  |    644 |     I figured out the next one\ldots
 | 
|  |    645 |   \end{bubble}
 | 
|  |    646 | \end{textblock}
 | 
|  |    647 | 
 | 
|  |    648 | \only<2>{
 | 
|  |    649 | \begin{textblock}{6}(0.3,11.8)
 | 
|  |    650 |   \begin{bubble}[3.1cm]
 | 
|  |    651 |     \textbf{Me:}
 | 
|  |    652 |     \raisebox{-12mm}{\includegraphics[scale=0.15]{../pics/happy.jpg}}
 | 
|  |    653 |   \end{bubble}
 | 
|  |    654 | \end{textblock}}
 | 
|  |    655 | 
 | 
|  |    656 | \end{frame}
 | 
|  |    657 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 
 | 
|  |    658 | 
 | 
|  |    659 | 
 | 
|  |    660 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 | 
|  |    661 | \begin{frame}[c]
 | 
| 33 |    662 | \frametitle{Conclusion}
 | 
|  |    663 | 
 | 
|  |    664 | \begin{itemize}
 | 
|  |    665 | \item Scala is still under heavy development\\ (the compiler is terribly slow)\medskip
 | 
|  |    666 | \item {\bf\url{http://www.scala-lang.org/}}\bigskip
 | 
| 140 |    667 |   
 | 
|  |    668 | \item it is a rather \textbf{\alert{deep}} language\ldots i.e.~gives
 | 
|  |    669 |   you a lot of rope to shoot yourself\bigskip
 | 
| 33 |    670 | 
 | 
| 140 |    671 | \item learning functional programming is not easy\ldots{}when you have
 | 
| 200 |    672 |   spent all of your career thinking in an imperative way, it is hard to
 | 
| 140 |    673 |   change\bigskip\medskip
 | 
|  |    674 |   
 | 
| 200 |    675 | \item hope you have fun with Scala and the assignments
 | 
| 33 |    676 | \end{itemize}
 | 
|  |    677 | \end{frame}
 | 
|  |    678 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
 | 
|  |    679 | 
 | 
|  |    680 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 | 
|  |    681 | \begin{frame}[c]
 | 
| 140 |    682 | \frametitle{\begin{tabular}{c}\\[0cm]\alert{Questions?}\end{tabular}}
 | 
| 33 |    683 | 
 | 
| 140 |    684 | \begin{center}
 | 
|  |    685 |   \begin{tabular}[t]{@{}l@{}l@{}}
 | 
| 200 |    686 |     \includegraphics[scale=0.1]{../pics/mand4.png} & \hspace{4mm}
 | 
|  |    687 |     \raisebox{0mm}{\includegraphics[scale=0.1]{../pics/mand3.png}}      
 | 
| 140 |    688 |   \end{tabular}     
 | 
|  |    689 | \end{center}
 | 
|  |    690 | 
 | 
|  |    691 | \begin{center}
 | 
| 308 |    692 |   My Office Hours: Thursdays 12 -- 14\\
 | 
|  |    693 |   And specifically for Scala: Tuesday 10:45 -- 11:45
 | 
| 140 |    694 | \end{center}
 | 
| 33 |    695 | \end{frame}
 | 
|  |    696 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   
 | 
|  |    697 | \end{document}
 | 
| 32 |    698 | 
 | 
|  |    699 | 
 | 
| 22 |    700 | \end{document}
 | 
|  |    701 | 
 | 
|  |    702 | %%% Local Variables:  
 | 
|  |    703 | %%% mode: latex
 | 
|  |    704 | %%% TeX-master: t
 | 
|  |    705 | %%% End: 
 | 
|  |    706 | 
 | 
| 140 |    707 | 
 | 
|  |    708 | “Functional programming is often regarded as the best-kept secret of
 | 
|  |    709 | scientific modelers, mathematicians, artificial intelligence
 | 
|  |    710 | researchers, financial institutions, graphic designers, CPU designers,
 | 
|  |    711 | compiler programmers, and telecommunications engineers.”
 | 
|  |    712 | 
 | 
|  |    713 | The Wikipedia F# page |