Which of the following statements about strings is false? Strings are declared a
ID: 3694711 • Letter: W
Question
Which of the following statements about strings is false?
Strings are declared as character arrays.
As long as they are identically declared, including their length, one string may be assigned to another.
Strings may be declared as a character pointer.
When a string is initialized, we do not need to specify the size of the array.
Strings can be read and written using the formatted I/O functions or special string I/O functions.
Strings are declared as character arrays.
As long as they are identically declared, including their length, one string may be assigned to another.
Strings may be declared as a character pointer.
When a string is initialized, we do not need to specify the size of the array.
Strings can be read and written using the formatted I/O functions or special string I/O functions.
Explanation / Answer
TRUE. A string is simply a character array that means a group of characters is called string. FALSE As long as strings are identically declared including their length. we can assign one string to another but bothe are same so the resulting output is same... TRUE. A string can be declared in different ways. so one of the declaration method is we can declare is as a character pointer.when we declare a character pointer it is possible to assign a maximum lenght string to it with blank spaces. so the character pointer is capable of holding the base address of the string.then string can be stored at some location in the memory and assign the base address of the string to a char pointer ex: char *s="bharath"; bharath is string store some where at memeory location its base address is going to be store at a character pointer s...... TRUE. so when we initialize a string it we do not specify the size of the arry. example .. char name[]={'b','h','a','r','a','t','h','