what is diffrence between string and character array?
Answer Posted / vadivelt
By default String always ends with NULL character ie., '\0'.
But in character array manually it is needed to terminate
with NULL(You can do this, only when you wanted to use
character array as string)
Eg;
char *p = "Vadivel"; /*By default string is terminated
with '\0'*/
char array[8] = {'V','a','d','i','v','e','l','\0'};
/*Here terminated manually*/
| Is This Answer Correct ? | 9 Yes | 1 No |
Post New Answer View All Answers
Why do we use null pointer?
Is there any possibility to create customized header file with c programming language?
Do character constants represent numerical values?
What is the use of extern in c?
Explain why can’t constant values be used to define an array’s initial size?
Why is c used in embedded systems?
What is bubble sort in c?
What is 02d in c?
Which is better oop or procedural?
What is scope rule of function in c?
What is extern c used for?
What is a structural principle?
Differentiate between the expression “++a” and “a++”?
How can I make sure that my program is the only one accessing a file?
What is call by value in c?