why string is not taking as primitive datatypes but we r
taking it as a class? why explain it?
Answer Posted / ankit
All primitive types have fixed memory size. Now in case of
the String, its length is not fixed and so is its size.
That's why it cannot be a primitive data type.
| Is This Answer Correct ? | 5 Yes | 2 No |
Post New Answer View All Answers
How does enum work in java?
Can we modify the throws clause of the superclass method while overriding it in the subclass?
What is a modifier?
Are arrays dynamic in java?
Can java program run without jre?
Why parsing is done?
Can we force the garbage collection to run?
What does a boolean method return?
What is a parameter in simple terms?
How can you write a loop indefinitely in java programming?
What are basic keywords?
Can we have two methods in a class with the same name?
What is the purpose of the runtime class in java programming?
What is a lightweight component?
What is map java?