answersLogoWhite

0

The char type store only one symbol of data (letter, digit, space, tab and so on). The string type is able to keep virtually data of any length. Also string type is based on arrays and uses reference type working with memory.

User Avatar

Wiki User

17y ago

What else can I help you with?

Continue Learning about Engineering

In java is A string the same thing as a char?

No.A char is a single Unicode character. It is stored as a primitive (i.e., non-object) data. A string can be considered as an array of chars - Java stores it as an object.No.A char is a single Unicode character. It is stored as a primitive (i.e., non-object) data. A string can be considered as an array of chars - Java stores it as an object.No.A char is a single Unicode character. It is stored as a primitive (i.e., non-object) data. A string can be considered as an array of chars - Java stores it as an object.No.A char is a single Unicode character. It is stored as a primitive (i.e., non-object) data. A string can be considered as an array of chars - Java stores it as an object.


What type of data is held in a string?

String in C is basically a Character 1-D array, whose last character is a NULL ['\0']. It is declared as follows: char array_name[size]; Ex. char wiki[10];


What is char data types?

The char data types holds a single ASCII (or unicode) value, so it holds any character, for example: '2', 'r', or '~'. The problem is it only holds one character, not a whole string. That is why the string was developed; it holds a whole bunch of characters in a row. But strings cant be compared with < and >, so for alphabetical ordering, use char.


What are the nine basic data types?

Byte Short Int Long Float Double Char Bool String


What is size of char far data type?

char is a primitive data type and depends on the programming language and the operating system.

Related Questions

Where string is primitive data type of string data type?

String is not primitive data. Only char,int,double,and boolean are!


In java is A string the same thing as a char?

No.A char is a single Unicode character. It is stored as a primitive (i.e., non-object) data. A string can be considered as an array of chars - Java stores it as an object.No.A char is a single Unicode character. It is stored as a primitive (i.e., non-object) data. A string can be considered as an array of chars - Java stores it as an object.No.A char is a single Unicode character. It is stored as a primitive (i.e., non-object) data. A string can be considered as an array of chars - Java stores it as an object.No.A char is a single Unicode character. It is stored as a primitive (i.e., non-object) data. A string can be considered as an array of chars - Java stores it as an object.


Can you make an integer pointer variable to char data?

Of course. But why? int *p = (int *)"string";


What is primare datatype in c?

primary datatypes means the data types which are provided by developer of language himself like int,float,double,char are the primary data types in c language where as the String,array are nothing but the derived data types. for Ex.we derived the String data type from char datatype using array system.


What type of data is held in a string?

String in C is basically a Character 1-D array, whose last character is a NULL ['\0']. It is declared as follows: char array_name[size]; Ex. char wiki[10];


What is char data types?

The char data types holds a single ASCII (or unicode) value, so it holds any character, for example: '2', 'r', or '~'. The problem is it only holds one character, not a whole string. That is why the string was developed; it holds a whole bunch of characters in a row. But strings cant be compared with < and >, so for alphabetical ordering, use char.


What are the nine basic data types?

Byte Short Int Long Float Double Char Bool String


What are Strings in C programming?

Arrays of chars are strings. there is a built in librray, that handles string string.h but the data-type is held as arrays of chars. char[10] c="string"; translate to ['s','t','r','i','n','g',\0] Arrays of chars are strings. there is a built in librray, that handles string string.h but the data-type is held as arrays of chars. char[10] c="string"; translate to ['s','t','r','i','n','g',\0]


What is the syntax for string in c?

The C programming language has no notion of a string. The C runtime libraries interpret a string as an array of 'char' (sometimes 'unsigned char'), where a byte (char) with numerical value zero (often written as '\0' in C) denotes the end of the string. Modern variations also support modern forms of strings based on different data types (wchar, etc) in order to support more complex encodings such as Unicode. These, too, are interpretations of combinations of language features, but not a built-in part of the language.


What is the difference between string and class?

A string is a specific class that is used for dealing with text data


What is the c plus plus command to read a line?

You can use cin which located in iostream.h You have to use certain data type to read string, for instance, array of char


What is the relationship between two data sets when one data set of data values increases while the other decreases?

There is an inverse relationship between the datasets.