[go: nahoru, domu]

Skip to content

Commit

Permalink
Removing confusing exercise
Browse files Browse the repository at this point in the history
  • Loading branch information
AllenDowney committed Jul 2, 2015
1 parent ec51916 commit 265dad6
Showing 1 changed file with 2 additions and 27 deletions.
29 changes: 2 additions & 27 deletions book/book.tex
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,8 @@
\title{Think Python}
\author{Allen B. Downey}
\newcommand{\thetitle}{Think Python: How to Think Like a Computer Scientist}
\newcommand{\theversion}{2.0.15}
\newcommand{\thedate}{March 2015}
\newcommand{\theversion}{2.0.16}
\newcommand{\thedate}{}

% these styles get translated in CSS for the HTML version
\newstyle{a:link}{color:black;}
Expand Down Expand Up @@ -1540,31 +1540,6 @@ \section{Variables}
<type 'float'>
\end{verbatim}

\begin{exercise}

If you type an integer with a leading zero, you might get
a confusing error:

\begin{verbatim}
>>> zipcode = 02492
^
SyntaxError: invalid token
\end{verbatim}

Other numbers seem to work, but the results are bizarre:

\begin{verbatim}
>>> zipcode = 02132
>>> zipcode
1114
\end{verbatim}

Can you figure out what is going on? Hint: display the
values {\tt 01}, {\tt 010}, {\tt 0100} and {\tt 01000}.
\index{octal}

\end{exercise}



\section{Variable names and keywords}
Expand Down

0 comments on commit 265dad6

Please sign in to comment.