What is the difference between char a[] = "string"; and
char *p = "string"; ?
Answer Posted / mak
in case of array size of it become fixed after initialization,
so a string of length greater than the size of previous string can't be assigned to array.
on the other hand pointer can take variable size string as it stores only the first address.
Is This Answer Correct ? | 0 Yes | 1 No |
Post New Answer View All Answers
What are variables and it what way is it different from constants?
any "C" function by default returns an a) int value b) float value c) char value d) a & b
What is pointer and structure in c?
#define PRINT(int) printf("int = %d ",int) main() {< BR> intx,y,z; x=03;y=02;z=01; PRINT(x^x); z<<=3;PRINT(x); y>>=3;PRINT(y); }
What is unsigned int in c?
The % symbol has a special use in a printf statement. How would you place this character as part of the output on the screen?
What is typeof in c?
What tq means in chat?
How can I use a preprocessorif expression to ?
Process by which one bit pattern in to another by bit wise operation is?
What is the package for freshers(Non IIT) in amazon(hyderabad). And what is the same for those who are a contract employee.
Explain what is wrong with this program statement? Void = 10;
What is auto keyword in c?
Hi how many types of software editions are there and their difference (like home editions, enterprise, standard etc) can u please help me
What is a lookup table in c?