Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

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


Please Help Members By Posting Answers For Below Questions

how we can make a write-only class in java?

1020


How do you sort a set in java?

908


Can we define constructor in inner class?

995


If system.exit (0); is written at the end of the try block, will the finally block still execute?

1102


What are unchecked exceptions in java?

1029


What is nested class?

996


How can you set an applet’s height and width as a percentage?

926


Why is stringbuffer thread safe?

1041


What is a java list?

1100


Difference between class#getinstance() and new operator ?

1203


Find the value of a specified element of the array arr[i] where 0 <= i <= n-1

974


Will set allow duplicates in java?

968


What is passed by reference and pass by value ?

1028


How do you read and print a string in java?

950


What is the use of arraylist class in java?

1067