algo_026.md (341B)
1 # algo_026 2 3 ### Problem Statement 4 5 > Write an algorithm to check if the stack is full or not. 6 7 ## Algorithm 8 ``` 9 procedure isFull(top, n) 10 begin 11 /* n represents stack size, 12 having index 0 to n-1 and 'top' is an index variable. */ 13 14 if(top = n - 1) 15 return true; 16 else 17 return false; 18 endif 19 end procedure 20 ```