Exam Objectives
Write code using the following methods of the java.lang.Math class: abs(), ceil(), floor(), max(), min(), random(), round(), sin(), cos(), tan(), sqrt().Describe the significance of...
Overview of the java.lang Package
The java.lang package is indispensable when programming in Java. It is automatically imported into every source file at compile time. The...
The Object Class
All classes extend the Object class, either directly or indirectly. A class declaration, without the extends clause, implicitly extends the Object class (see...
10.1
What is the return type of the hashCode() method in the Object class?
Select the one correct answer.
StringintlongObjectClass10.2
Which statement is true?
Select the one correct answer.
If the...
Wrapper classes were introduced with the discussion of the primitive data types (see Section 2.2, p. 28). Primitive values in Java are not objects. In...
Review Questions
10.4
Which of the following are wrapper classes?
Select the three correct answers.
java.lang.Voidjava.lang.Intjava.lang.Booleanjava.lang.Longjava.lang.String10.5
Which of the following classes do not extend the java.lang.Number class?
Select the two correct...
The Math Class
The final class Math defines a set of static methods to support common mathematical functions, including functions for rounding numbers, performing trigonometry, generating...
The String Class
Handling character strings is supported through two final classes: String and StringBuffer. The String class implements immutable character strings, which are read-only once...
10.16
Which of the following operators cannot be used in conjunction with a String object?
Select the two correct answers.
+-+=.&10.17
Which expression will extract the substring "kap" from...
The StringBuffer Class
In contrast to the String class, which implements immutable character strings, the StringBuffer class implements mutable character strings. Not only can the character...
Chapter Summary
The following information was included in this chapter:
discussion of the Object class, which is the most fundamental class in Javadiscussion of the wrapper classes,...
10.1
Create a class named Pair, which aggregates two arbitrary objects. Implement the equals() and hashCode() methods in such a way that a Pair object is...
AJAX popular information C# language guides Windows books and cookbooks
.......
С 2009 года мы стали переводить структура сайта на различные языки. Сайт теперь будет содержать книги не только на английском языке, но также и на других европейских языках, в том числе и на Русском языке.