There are a number of text conventions used throughout this book.
CodeInText: Indicates code words in the text, database table names, folder names, filenames, file extensions, pathnames, dummy URLs, user input, and Twitter handles. Here is an example: "The simplest way to do that is to initiate new Thread() and then call the start() method on the thread."
A block of code is set as follows:
private boolean isNotUnique(Color[] guess) { final var alreadyPresent = new HashSet<Color>(); for (final var color : guess) { if (alreadyPresent.contains(color)) { return true; } alreadyPresent.add(color); } return false; }
When we wish to draw your attention to a particular part of a code block, the relevant lines or items are set in ...