Question 81Asked in BPSC TRE 1.0 (2023) Computer Science Class 11-12

After performing following set of operations, what does the final list look contain?

After performing following set of operations, what does the final list look contain? InsertFront(10); InsertFront(20); InsertRear(30); DeleteFront( ); InsertRear(40); InsertRear(10); DeleteRear( ); InsertRear(15); display( );
  1. A10 30 10 15
  2. B20 30 40 15
  3. C10 30 40 15
  4. DMore than one of the above
  5. ENone of the above
Show answerHide answer

Correct answer: (C) 10 30 40 15

Explanation

After the steps the deque is: 10; 20 10; 20 10 30; 10 30; 10 30 40; 10 30 40 10; 10 30 40; then 10 30 40 15.

From BPSC TRE 1.0 (2023) Computer Science Class 11-12 — Previous Year Paper

This is question 81 of BPSC TRE 1.0 (2023) Computer Science Class 11-12 — Previous Year Paper. See all questions of this paper with answers, or attempt the paper as a timed online test to get your score and all-India rank.