slides/slides07.tex
changeset 215 828303e8e4af
parent 188 12ef150273ce
child 302 0fa7b4221745
equal deleted inserted replaced
214:5be68de225e9 215:828303e8e4af
     1 \documentclass[dvipsnames,14pt,t]{beamer}
     1 \documentclass[dvipsnames,14pt,t]{beamer}
     2 \usepackage{beamerthemeplaincu}
     2 \usepackage{beamerthemeplaincu}
     3 %\usepackage[T1]{fontenc}
       
     4 %\usepackage[latin1]{inputenc}
       
     5 \usepackage{mathpartir}
       
     6 \usepackage[absolute,overlay]{textpos}
     3 \usepackage[absolute,overlay]{textpos}
     7 \usepackage{ifthen}
     4 \usepackage{ifthen}
     8 \usepackage{tikz}
     5 \usepackage{tikz}
     9 \usepackage{pgf}
     6 \usepackage{pgf}
    10 \usepackage{calc} 
     7 \usepackage{calc} 
    19 \usetikzlibrary{positioning}
    16 \usetikzlibrary{positioning}
    20 \usetikzlibrary{calc}
    17 \usetikzlibrary{calc}
    21 \usetikzlibrary{plotmarks}
    18 \usetikzlibrary{plotmarks}
    22 \usepackage{graphicx} 
    19 \usepackage{graphicx} 
    23 \usepackage{pgfplots}
    20 \usepackage{pgfplots}
    24 
    21 \usepackage{../langs}
    25 \definecolor{javared}{rgb}{0.6,0,0} % for strings
    22 \usepackage{../data}
    26 \definecolor{javagreen}{rgb}{0.25,0.5,0.35} % comments
    23 
    27 \definecolor{javapurple}{rgb}{0.5,0,0.35} % keywords
       
    28 \definecolor{javadocblue}{rgb}{0.25,0.35,0.75} % javadoc
       
    29 
       
    30 \lstset{language=Java,
       
    31 	basicstyle=\ttfamily,
       
    32 	keywordstyle=\color{javapurple}\bfseries,
       
    33 	stringstyle=\color{javagreen},
       
    34 	commentstyle=\color{javagreen},
       
    35 	morecomment=[s][\color{javadocblue}]{/**}{*/},
       
    36 	numbers=left,
       
    37 	numberstyle=\tiny\color{black},
       
    38 	stepnumber=1,
       
    39 	numbersep=10pt,
       
    40 	tabsize=2,
       
    41 	showspaces=false,
       
    42 	showstringspaces=false}
       
    43 
       
    44 \lstdefinelanguage{scala}{
       
    45   morekeywords={abstract,case,catch,class,def,%
       
    46     do,else,extends,false,final,finally,%
       
    47     for,if,implicit,import,match,mixin,%
       
    48     new,null,object,override,package,%
       
    49     private,protected,requires,return,sealed,%
       
    50     super,this,throw,trait,true,try,%
       
    51     type,val,var,while,with,yield},
       
    52   otherkeywords={=>,<-,<\%,<:,>:,\#,@},
       
    53   sensitive=true,
       
    54   morecomment=[l]{//},
       
    55   morecomment=[n]{/*}{*/},
       
    56   morestring=[b]",
       
    57   morestring=[b]',
       
    58   morestring=[b]"""
       
    59 }
       
    60 
       
    61 \lstset{language=Scala,
       
    62 	basicstyle=\ttfamily,
       
    63 	keywordstyle=\color{javapurple}\bfseries,
       
    64 	stringstyle=\color{javagreen},
       
    65 	commentstyle=\color{javagreen},
       
    66 	morecomment=[s][\color{javadocblue}]{/**}{*/},
       
    67 	numbers=left,
       
    68 	numberstyle=\tiny\color{black},
       
    69 	stepnumber=1,
       
    70 	numbersep=10pt,
       
    71 	tabsize=2,
       
    72 	showspaces=false,
       
    73 	showstringspaces=false}
       
    74 
       
    75 \lstdefinelanguage{While}{
       
    76   morekeywords={while, if, then. else, read, write},
       
    77   otherkeywords={=>,<-,<\%,<:,>:,\#,@},
       
    78   sensitive=true,
       
    79   morecomment=[l]{//},
       
    80   morecomment=[n]{/*}{*/},
       
    81   morestring=[b]",
       
    82   morestring=[b]',
       
    83   morestring=[b]"""
       
    84 }
       
    85 
       
    86 
       
    87 \setmonofont{Consolas}
       
    88 
       
    89 \begin{filecontents}{interpreted.data}
       
    90 %1 0.00503
       
    91 200 1.005863
       
    92 400 7.8296765
       
    93 500 15.43106
       
    94 600 27.2321885
       
    95 800 65.249271
       
    96 1000 135.4493445
       
    97 1200 232.134097
       
    98 1400 382.527227
       
    99 \end{filecontents}
       
   100 
    24 
   101 % beamer stuff 
    25 % beamer stuff 
   102 \renewcommand{\slidecaption}{AFL 07, King's College London, 13.~November 2013}
    26 \renewcommand{\slidecaption}{AFL 07, King's College London, 13.~November 2013}
   103 \newcommand{\bl}[1]{\textcolor{blue}{#1}}       
    27 \newcommand{\bl}[1]{\textcolor{blue}{#1}}       
   104 \newcommand{\dn}{\stackrel{\mbox{\scriptsize def}}{=}}% for definitions
    28 \newcommand{\dn}{\stackrel{\mbox{\scriptsize def}}{=}}% for definitions