Ask Question
1 November, 11:46

Why do we need to pass a size as well as the array to any function/procedure where we want it to use this array?

+2
Answers (1)
  1. 1 November, 12:43
    0
    In C+ + or C we don't have a function which tells us the size of array which is required. So it is necessary to pass the size of the arrays in the function. At the time of declaration we declare the size of the array more than we need. Then we store the elements upto the size which is necessary. So the actual size of the array is larger than the size we needed. So hence it is necessary to pass the size of the array.
Know the Answer?
Not Sure About the Answer?
Get an answer to your question ✅ “Why do we need to pass a size as well as the array to any function/procedure where we want it to use this array? ...” in 📙 Computers & Technology if there is no answer or all answers are wrong, use a search bar and try to find the answer among similar questions.
Search for Other Answers