Pointers and Arrays on C related Questions and Answers


Question :   What are the different ways to initialize an array with all elements as zero?
1. int array[5] = {};
2. int array[5] = {0};
3.

   int a = 0,  b = 0,  c = 0;   int array[5] = {a, b, c};

4. All of the mentioned
Answer :   4 - All of the mentioned  

* Be the First to Post a Comment.

Submit comment :


Captcha Image
Reload

Ask Question

Captcha Image
Reload

Note : Name and Email never shown.





Subscribe


Become a part of EducationForever. Subscribe to our FREE Newsletter