what is difference between integer and string data type?
Answers
Answered by
0
The differences between the Integer and String objects in Java are: Integercan be converted to String, but Stringcannot be converted to Integer.Integer is a numeric value and Stringis a character value represented in quotes.
Answered by
1
Answer:
Both Integer and String are Object classes in the Java language. The Integer class holds numeric values, while the String class holds character values enclosed in double quotes. Both classes have methods to extract data from the objects. ... intValue( ), which returns the integer value represented by the Integer object.
Similar questions
Math,
7 months ago
Science,
7 months ago
Math,
7 months ago
Physics,
1 year ago
Social Sciences,
1 year ago
Science,
1 year ago
Political Science,
1 year ago