Skip to content

Commit 941add5

Browse files
Merge pull request #16 from waldoluisribeiro/master
fixed typos; version 6.1.7
2 parents e60217e + 986ddfa commit 941add5

1 file changed

Lines changed: 12 additions & 12 deletions

File tree

thinkjava.tex

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
\newcommand{\thetitle}{Think Java}
77
\newcommand{\thesubtitle}{How to Think Like a Computer Scientist}
88
\newcommand{\theauthors}{Allen B. Downey and Chris Mayfield}
9-
\newcommand{\theversion}{6.1.6}
9+
\newcommand{\theversion}{6.1.7}
1010

1111
%%%% Both LATEX and PLASTEX
1212

@@ -404,7 +404,7 @@ \chapter{The way of the program}
404404

405405
The single most important skill for a computer scientist is {\bf problem solving}.
406406
It involves the ability to formulate problems, think creatively about solutions, and express solutions clearly and accurately.
407-
As it turns out, the process of learning to program is an excellent opportunity to develop problem solving skills.
407+
As it turns out, the process of learning to program is an excellent opportunity to develop problem-solving skills.
408408
That's why this chapter is called, ``The way of the program''.
409409

410410
On one level you will be learning to program, a useful skill by itself.
@@ -461,7 +461,7 @@ \section{What is computer science?}
461461

462462
Designing algorithms and writing code is difficult and error-prone.
463463
For historical reasons, programming errors are called {\bf bugs}, and the process of tracking them down and correcting them is called {\bf debugging}.
464-
As you learn to debug your programs, you will develop new problem solving skills.
464+
As you learn to debug your programs, you will develop new problem-solving skills.
465465
You will need to think creatively when unexpected errors happen.
466466

467467
Although it can be frustrating, debugging is an intellectually rich, challenging, and interesting part of computer programming.
@@ -809,7 +809,7 @@ \section{Formatting code}
809809
%These characters, which are called {\bf whitespace}, affect the format of the code, but they don't affect its behavior.
810810

811811
%You have a lot of freedom in how you arrange your code.
812-
%However with that freedom comes responsibility, both to yourself (when you look at the code in the future) and others who will be reading, understanding, and debugging it.
812+
%However, with that freedom comes responsibility, both to yourself (when you look at the code in the future) and others who will be reading, understanding, and debugging it.
813813

814814
\index{Google style}
815815

@@ -874,7 +874,7 @@ \section{Debugging code}
874874

875875
Finally, programming sometimes brings out strong emotions.
876876
If you are struggling with a difficult bug, you might feel angry, despondent, or embarrassed.
877-
Remember that you are not alone, and most if not all programmers have had similar experiences.
877+
Remember that you are not alone, and most, if not all, programmers have had similar experiences.
878878
Don't hesitate to reach out to a friend and ask questions!
879879

880880

@@ -2931,7 +2931,7 @@ \section{Adding new methods}
29312931
\item Introducing new methods can make a program smaller by eliminating repetitive code.
29322932
For example, to display nine consecutive new lines, you could invoke \java{threeLine} three times.
29332933

2934-
\item A common problem solving technique is to break tasks down into sub-problems.
2934+
\item A common problem-solving technique is to break tasks down into sub-problems.
29352935
Methods allow you to focus on each sub-problem in isolation, and then compose them into a complete solution.
29362936

29372937
\end{itemize}
@@ -7974,7 +7974,7 @@ \section{Garbage collection}
79747974

79757975
If there are no references to an object, there is no way to access its attributes or invoke a method on it.
79767976
From the programmer's view, it ceases to exist.
7977-
However it's still present in the computer's memory, taking up space.
7977+
However, it's still present in the computer's memory, taking up space.
79787978

79797979
\index{garbage collection}
79807980

@@ -11225,7 +11225,7 @@ \section{Exercises}
1122511225

1122611226
\index{override}
1122711227

11228-
Think of other ways you can minimize penalty points, such as playing the highest ranking cards first.
11228+
Think of other ways you can minimize penalty points, such as playing the highest-ranking cards first.
1122911229
Write a new class that extends \java{Player} and overrides \java{play} to implement your strategy.
1123011230
\end{exercise}
1123111231

@@ -11362,7 +11362,7 @@ \section{Command-line interface}
1136211362
One of the most powerful and useful skills you can learn is how to use the {\bf command-line interface}, also called the ``terminal''.
1136311363
The command line is a direct interface to the operating system.
1136411364
It allows you to run programs, manage files and directories, and monitor system resources.
11365-
Many advanced tools, both for software development and general purpose computing, are available only at the command line.
11365+
Many advanced tools, both for software development and general-purpose computing, are available only at the command line.
1136611366

1136711367
There are many good tutorials online for learning the command line for your operating system; just search the web for ``command line tutorial''.
1136811368
On Unix systems like Linux and OS X, you can get started with just four commands: change the working directory ({\tt cd}), list directory contents ({\tt ls}), compile Java programs ({\tt javac}), and run Java programs ({\tt java}).
@@ -11394,7 +11394,7 @@ \section{Command-line testing}
1139411394
And after you've completed programming an algorithm, it's important to test that it works correctly on a variety of inputs.
1139511395

1139611396
Throughout the book, we illustrate techniques for testing your programs.
11397-
Most if not all testing is based on a simple idea: does the program do what we expect it to do?
11397+
Most, if not all, testing is based on a simple idea: does the program do what we expect it to do?
1139811398
For simple programs, it's not difficult to run them several times and see what happens.
1139911399
But at some point, you will get tired of typing the same test cases over and over.
1140011400

@@ -11786,7 +11786,7 @@ \section{Graphics methods}
1178611786
\index{bounding box}
1178711787

1178811788
The four parameters specify a {\bf bounding box}, which is the rectangle in which the oval is drawn.
11789-
\java{x} and \java{y} specify the the location of the upper-left corner of the bounding box.
11789+
\java{x} and \java{y} specify the location of the upper-left corner of the bounding box.
1179011790
The bounding box itself is not drawn (see Figure~\ref{fig.circle}).
1179111791

1179211792
\begin{figure}[!ht]
@@ -12492,7 +12492,7 @@ \subsection*{No, I really need help.}
1249212492

1249312493
It happens.
1249412494
Even the best programmers get stuck.
12495-
Sometimes you need a another pair of eyes.
12495+
Sometimes you need another pair of eyes.
1249612496

1249712497
Before you bring someone else in, make sure you have tried the techniques described in this appendix.
1249812498

0 commit comments

Comments
 (0)