Errata for Liang Java 13e

You can access bonus chapters from https://liveexample.pearsoncmg.com/liang/BonusChapters.html.

If you see an error, please email y.daniel.liang@gmail.com. Thanks!

Last update:

NOTE: Revel assigned exercises are currently submitted to a Java 11 compiler. Use the CheckExercise tool from https://liveexample.pearsoncmg.com/CheckExercise/faces/CheckExercise13e.xhtml to automatically check your code for logic errors before submitting to Revel.

In Programming Exercise 1.7 in Chapter 1: Programming Exercises from the Book: Delete - 1 / 15.

In Multiple Choice Quiz 4.4.7: Question 5, change "s.length() - 1" to "s1.length()".

In Section 5.5, in the first code box, change "getLine()" to "nextLine()".

In Multiple Choice Quiz 7.9: Question 2, change "incorrect" to "correct".

In Chapter 7: Programming Project 1: change > to >= four times.

In Chapter 8: Section 8.2.3, change "triangle-Array" to "triangleArray".

In Chapter 20: Programming Project 2, change LiveExample 20.9 to LiveExample 20.12.

In Section 21.4, Multiple-Choice Quiz 21.4 Question 1, the choice "The program will be fine if set1.clone() is replaced by (Set<String>)set1.clone()." is also correct, but it is mistakenly set as incorrect in the grading.

In Section 21.4, Multiple-Choice Quiz 21.4 Question 2, change "the clone method is not defined Set" to "the clone method is not defined in Set".

In Chapter 21: Programming Project 2, there is an error in the sample run. It should be

Enter a string: Welcome to Java
c: 1
j: 1
l: 1
m: 1
t: 1
v: 1
w: 1
a: 2
e: 2
o: 2
    

In Chapter 24: Programming Project 1, there are two retainAll. Change the second one to toArray().

In Chapter 25: Programming Project 4, change MyList to Tree in the first line.

In Chapter 29: Multiple-Choice Quiz 29.3 Question 3, the choice "Adds a weighted edge to the adjacent list for vertex u." is also correct, but it is mistakenly set as incorrect in the grading.