A program attempts to generate as many permutations as possible of the character p, q, r, s, t in the same order onto a stack, but it may pop off the top character at any time. Which of the following numbers can be generated using this program?

I.  s, r, q, p, t

II. r, q, t, p, s

III. t, s, r, q, p

IV. s, r, t, q, p

1
Only I and II
2
Only I, II and III
3
Only I, III and IV
4
Only III and IV

Sponsored

hivanix.in

Visit

This quiz is brought to you by hivanix.in

🌐 Web App Development

Quick Navigation