If I want to initialize the array like.
int a[5] = {0};
then it gives me all element 0.
but if i give int a[5] = {5};
then 5 0 0 0 0 is ans.
what will I do for all element 5 5 5 5 5 in a single
statement???
Answer Posted / litan parida
int a[1000];
memset(&a,0,sizeof(a))
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
This is a variation of the call_me function in the previous question:call_me (myvar)int *myvar;{ *myvar += 5; }The correct way to call this function from main() will be a) call_me(myvar) b) call_me(*myvar) c) call_me(&myvar) d) expanded memory
Explain threaded binary trees?
What are the 4 types of organizational structures?
How can I send mail from within a c program?
What are pointers? Why are they used?
What are header files? What are their uses?
what is the format specifier for printing a pointer value?
Why should I prototype a function?
Distinguish between actual and formal arguments.
What is a structure and why it is used?
Define and explain about ! Operator?
Explain how can I convert a number to a string?
What is unsigned int in c?
What is the explanation for prototype function in c?
What is #define size in c?