The following figure is a ____ tree after zig-zig rotations.

2013

The following figure is a ____ tree after zig-zig rotations.

image.pngimage.png
  1. A.

    Heap

  2. B.

    Bubble

  3. C.

    Splay

  4. D.

    Binary

Attempted by 345 students.

Show answer & explanation

Correct answer: C

A splay tree is a self-balancing binary search tree. Splaying is performed using rotations. There are six types of rotations used in splay trees: Zig rotation (Right rotation)

Zag rotation (Left rotation)

Zig-Zag (Zig followed by Zag)

Zag-Zig (Zag followed by Zig)

Zig-Zig (Two right rotations)

Zag-Zag (Two left rotations)

Explore the full course: Niacl Ao It Specialist