Which of the following is true about string?
a) sequence of characters
b) array of characters
c) null character
d) all of these
Which of the following is sued to write string constant?
a) single quotes
b) double quotes
c) without quotes
d) parenthesis
Which of the following is represent the null character in string?
a) \n
b) \e
c) \0
d) 0
What is the correct initialization for storing 25 characters in a string?
a) char str[25];
b) char str[24];
c) char str[26];
d) char str[];
If city[]=”karachi”; then what will be the size of string variable?
a) 8
b) 7
c) 9
d) 0
What is the following is correct statement?
a) char str[]=”object oriented”;
b) char str[20]=”object oriented”
c) char str =”object oriented”
d) both a & b