Question
Consider the following array implementation of stack:```taerine max 10Struct STACK|Int arr [MAX];Int top = -1;)```If the array index starts with 0 , the maximum value of top that does not cause stack overflow is?A. 8B. 9C. 10D. 11
Step 1
We have an array `arr` of size `MAX`, which is 10. The variable `top` keeps track of the index of the topmost element in the stack. Show more…
Show all steps
Your feedback will help us improve your experience
18,000,000+
Students on Numerade
Trusted by students at 8,000+ universities
Watch the video solution with this free unlock.
EMAIL
PASSWORD