The equals method is defined in the Object class. Which of the following is correct to override it in the String class?
a. public boolean equals(String other)
b. public boolean equals(Object other)
c. public static boolean equals(String other)
d. public static boolean equals(Object other)
b. public boolean equals(Object other)
Computer Science & Information Technology
You might also like to view...
When you set up various conditions with the purpose of only showing a subset of data, that process is called ________
Fill in the blank(s) with correct word
Computer Science & Information Technology
What is the output of the following code (assuming it is embedded in a correct and complete program)?
```
char letter[5] = {'o', 'k', "c", "g''};
for(int i = 4; i >= 0; i-- )
cout << letter[i];
cout <
Computer Science & Information Technology