Site Owners Forums - Webmaster Forums

Site Owners Forums - Webmaster Forums (http://siteownersforums.com/index.php)
-   Java (http://siteownersforums.com/forumdisplay.php?f=12)
-   -   Is String a data type in java? (http://siteownersforums.com/showthread.php?t=165969)

Kunal 03-07-2016 10:50 PM

Is String a data type in java?
 
String is not a primitive data type in java. When a string is created in java, it’s actually an object of Java.Lang.String class that gets created. After creation of this string object, all built-in methods of String class can be used on the string object.

Shivangi Panwar 03-18-2016 10:46 PM

In Java Language Strings can be initialized by enclosing a string value in double quotes. Strings can be concatenated using the plus ('+') operator. So is String considered a Java data type? Inspite of all the above, String is not considered a primitive data type in Java.


All times are GMT -7. The time now is 08:04 AM.


Powered by vBulletin Copyright © 2020 vBulletin Solutions, Inc.