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 / n
int a[5]={5,5,5,5,5};
Is This Answer Correct ? | 27 Yes | 1 No |
Post New Answer View All Answers
What is infinite loop?
swap 2 numbers without using third variable?
Where static variables are stored in c?
Write a C/C++ program that connects to a MySQL server and checks if the InnoDB plug-in is installed on it. If so, your program should print the maximum number of concurrent threads that the InnoDB plug-in can create.
What is union in c?
What is a pointer value and address in c?
What are structure types in C?
What are volatile variables in c?
What is a void pointer in c?
Explain what is the best way to comment out a section of code that contains comments?
What is a protocol in c?
Is there sort function in c?
what is the structure pointer?
Explain how do you override a defined macro?
What does a derived class inherit from a base class a) Only the Public members of the base class b) Only the Protected members of the base class c) Both the Public and the Protected members of the base class d) .c file