280 views

2 Answers

3 votes
3 votes

The above programme is pushing each binary digit of 156 ( 10011100 ) from LSB into the stack of size 8. 

After 8th push on stack, while condition fails, because of n=0. So Programme will terminate without printing ''stack overflow''.

Ans- Value present in stack from top to bottom = 1 0 0 1 1 1 0 0
 

Related questions

1 votes
1 votes
0 answers
3
0 votes
0 votes
1 answer
4
vanshikha020 asked Jul 1, 2023
464 views
Is the product of eigen values of a matrix equal to its determinant true for all the matrices?