Can anybody elaborate the difference between “Char” and “String” at Java

Total Post:19

Points:133
Java 
 1336  View(s)
Ratings:
Rate this:

 I can't understand which is the difference between the variable type "char" and "string". For example, there is a difference between "int" and "short", the bytes at the memory and the area of numbers that they have.

But what is the difference between "char" and "string"? Expect that "char" use (') and "string" (").

  1. Post:24

    Points:168
    Re: Can anybody elaborate the difference between “Char” and “String” at Java

    char is one character. String is zero or more characters.

    char is a primitive type. The string is a class.

      Modified On Apr-03-2018 04:26:07 AM

Answer