Can we extend the String class?
Answers were Sorted based on User's Feedback
Answer / om
No, we can not extend the String class b'coz it's a final
class...
if a class is final, it's not possible to perform
inheritance operation on that class
| Is This Answer Correct ? | 50 Yes | 4 No |
Answer / maurya
We can`t extends String class because java make it final
and thats why we say String in java are immutable.
final..
class--->can not inharitted.
method-->can not overridden
variable->its valu can not change after once initialized.
| Is This Answer Correct ? | 16 Yes | 3 No |
Answer / shashi shaw
no we cant.becoz string ia a immutable class.
| Is This Answer Correct ? | 6 Yes | 16 No |
What is meant by Java interpreter?
What is functional interface in java example?
What is Collections API?
What is difference between classpath and path variables in java?
what is main difference b/w abstract class and interface
Why does java not support pointers?
How to find the length and capacity of a string buffer ?
Is there memory leaks in java?
List two java ide’s?
What is preflight request?
Difference between an argument and a parameter?
10 Answers Accounting, HCL, IBM, Quinnox,
What is the difference between int and integer in java?