summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorpaltherr <paltherr@epfl.ch>2003-05-20 08:27:26 +0000
committerpaltherr <paltherr@epfl.ch>2003-05-20 08:27:26 +0000
commit82bedc921b3e588251106c0946fb8d1e96edb44b (patch)
tree2039a24855134b45dfd02dd99b8d0943eb4d5d7f /doc
parent259221ca993b17f77a72e747a3b9cc3f7b905c0e (diff)
downloadscala-82bedc921b3e588251106c0946fb8d1e96edb44b.tar.gz
scala-82bedc921b3e588251106c0946fb8d1e96edb44b.tar.bz2
scala-82bedc921b3e588251106c0946fb8d1e96edb44b.zip
- Commented out some \red, \redtext, \bs \es
Diffstat (limited to 'doc')
-rw-r--r--doc/reference/examples.verb.tex8
1 files changed, 5 insertions, 3 deletions
diff --git a/doc/reference/examples.verb.tex b/doc/reference/examples.verb.tex
index 58aaf51d89..60036eb5ac 100644
--- a/doc/reference/examples.verb.tex
+++ b/doc/reference/examples.verb.tex
@@ -2713,7 +2713,7 @@ def sumPrimes(start: int, end: int): int = {
\end{verbatim}
Note that the variable \verb@i@ ``steps through'' all values of the interval
\verb@[start .. end-1]@.
-\es\bs
+%\es\bs
A more functional way is to represent the list of values of variable \verb@i@ directly as \verb@range(start, end)@. Then the function can be rewritten as follows.
\begin{verbatim}
def sumPrimes(start: int, end: int) =
@@ -2736,7 +2736,8 @@ constructed. But most of that list is never inspected!
However, we can obtain efficient execution for examples like these by
a trick:
\begin{quote}
-\red Avoid computing the tail of a sequence unless that tail is actually
+%\red
+ Avoid computing the tail of a sequence unless that tail is actually
necessary for the computation.
\end{quote}
We define a new class for such sequences, which is called \verb@Stream@.
@@ -2797,7 +2798,8 @@ constructing a stream with first element \verb@x@ and (unevaluated)
rest \verb@xs@. Instead of \verb@xs ::: ys@, one uses the operation
\verb@xs append ys@.
-\redtext{Is there another way?}
+%\redtext
+{Is there another way?}