# HG changeset patch # User Christian Urban # Date 1410749347 -3600 # Node ID baf41b05210ff3c9b28507d6a3248aa4c5d6bfbe # Parent a5fade10c207d2d99cc8396de3b38d4aab3042ad updated diff -r a5fade10c207 -r baf41b05210f handouts/notation.pdf Binary file handouts/notation.pdf has changed diff -r a5fade10c207 -r baf41b05210f handouts/notation.tex --- a/handouts/notation.tex Sun Sep 14 23:32:22 2014 +0100 +++ b/handouts/notation.tex Mon Sep 15 03:49:07 2014 +0100 @@ -106,12 +106,12 @@ stands for the string of $n$ repeated $a$s. So $a^{n}b^{n}$ is a string that has as many $a$s as $b$s. -While for us strings are just lists of characters, programming -languages often differentiate between the two concepts. In -Scala, for example, there is the type of \code{String} and the -type of lists of characters, \code{List[Char]}. They are not -the same and we need to explicitly coerce elements between the -two types, for example +Note however that while for us strings are just lists of +characters, programming languages often differentiate between +the two concepts. In Scala, for example, there is the type of +\code{String} and the type of lists of characters, +\code{List[Char]}. They are not the same and we need to +explicitly coerce elements between the two types, for example \begin{lstlisting}[numbers=none] scala> "abc".toList @@ -284,11 +284,11 @@ $\Sigma = \{a, b\}$, then $\Sigma^*$ is \[ -\{[], a, b, ab, ba, aaa, aab, aba, abb, baa, bab, \ldots\} +\{[], a, b, aa, ab, ba, bb, aaa, aab, aba, abb, baa, bab, \ldots\} \] -\noindent or in other words all strings containing $a$s and -$b$s only. +\noindent or in other words all strings containing $a$s and +$b$s only, plus the empty string. \end{document}