• Tutorials
  • DSA
  • Data Science
  • Web Tech
  • Courses
August 21, 2024 |1.8K Views

Level order traversal in spiral form - SDE Sheet

  Share  1 Like
Description
Discussion

In this video, we are given a binary tree. We need to perform a level order traversal in spiral form. 

For Example: 

Input:
          10
        /     \
       20     30
     /    \
   40     60
Output: 10 20 30 60 40 

Try it out before watching the implementation of the problem in the video. We recommend watching the video, even if you can solve the problem. You may discover something new. All the best!!!

Do check out:-

Article: https://www.geeksforgeeks.org/level-order-traversal-in-spiral-form/
Problem: https://practice.geeksforgeeks.org/problems/level-order-traversal-in-spiral-form/1
SDE Sheet: https://www.geeksforgeeks.org/sde-sheet-a-complete-guide-for-sde-preparation/