Ask 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?

+2
Answers (1)
  1. 13 July, 23:44
    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?
Find 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 the answers seem to be not correct or there’s no answer. Try a smart search to find answers to similar questions.
Search for Other Answers