What is the difference between char a[] = "string"; and
char *p = "string"; ?
Answer Posted / dharanidhar
P is a pointer which is constant. So, the values in this
array cannot be modified.
characters within a[] can be changed by accessing
like a[1] = '2',....
Is This Answer Correct ? | 1 Yes | 3 No |
Post New Answer View All Answers
What is %d called in c?
What are near, far and huge pointers?
What is the use of bitwise operator?
Explain a pre-processor and its advantages.
What are the general description for loop statement and available loop types in c?
Explain what are header files and explain what are its uses in c programming?
What is the size of structure in c?
What is assignment operator?
What is #define in c?
Write a C program linear.c that creates a sequence of
processes with a given length. By
sequence it is meant that each created process has exactly
one child.
Let's look at some example outputs for the program.
Here the entire process sequence consists of process 18181:
Sara@dell:~/OSSS$ ./linear 1
Creating process sequence of length 1.
18181 begins the sequence.
An example for a sequence of length three:
Sara@dell:~/OSSS$ ./linear 3
Creating process sequence of length 3.
18233 begins the sequence.
18234 is child of 18233
18235 is child of 18234
........ this is coad .... BUt i could not compleate it .....:(
#include
What is wrong with this initialization?
Do you know the use of fflush() function?
How can a program be made to print the name of a source file where an error occurs?
Did c have any year 2000 problems?
Why isnt any of this standardized in c?