Programming - Arrays - Discussion

You Are Here :: Home > C++ Language > Arrays - Discussion

 



Q.

Which of the following statements declares alpha to be an array of 5 components of the type int and initializes each component to 0?
(i) int alpha[5] = {0, 0, 0, 0, 0};
(ii) int alpha[5] = {0};                         


A. Only (i) B. Only (ii)
C. Both (i) and (ii) D. None of these

Answer: Option A
Explaination:

 


No Explanation




Discussion

Your Comments Goes here...
NameDiscussion