Data Structures

1:

Using
Pop(S1, Item)
Push(S1,Item)
Read(Item)
Print(Item)
the variables S1 represents (stack) and Item are  given the input file:

A,B,C,D,E,F  <EOF>

Which stacks are possible:

A.

5       A
4       B
3       C
2       D
1       E

B.

5  
4  
3      D
2      A
1      F

C.

5
4    
3      F
2      D
1      B

D.

5
4
3     C
2     E
1     B

 

Answer : C

Explanation :

Write your comments here:


Report Error
 

Option: A

Explanation : Explanation will come here. Explanation will come here. Explanation will come here. Explanation will come here. Explanation will come here.