Skip to content
/ assingment-2 Public template

This repository contains assignment questions on Queue and Binary Search Tree

Notifications You must be signed in to change notification settings

divaibhav/assingment-2

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 

Repository files navigation

GLA University, 2020

Problems Based on Queue and Binary Search Tree - Module 2

Problem - 1

  • Define & Implement your own algorithm, to traverse a Binary Search Tree and print all the left children as well as also print the count of nodes who doesn't have left child.

Problem - 2

  • Write a program to check & justify the given statement.
    • Pre order and post order traversal of Binary Search Tree shows following properties:
      1. Root element is placed at opposite end, i.e. in pre order root is the first element where as in post order root is the last element.
      2. They have common mid point, i.e. both the traversal will give same element at the mid position for odd number of nodes.

Problem - 3

  • Implement an queue which follows some order using Linked list. For example create queue of student as per the roll number, in ascending order.

Problem - 4

  • Implement a queue to store pre - order successor of all the nodes of given binary search tree.

Problem - 5

  • Implement a circular queue to process the given list of students as per the following conditions:
    1. Element will be removed from the queue if its backLog counter value is equal to zero.
    2. You can only process the front element, processing means "backLog - appearingCount".
    3. For any element appearing count will not be greater than 2.

Important instruction

Kindly DO NOT create the program in a single Main class. Try out some Object-Oriented Programming and use your skills from your software engineering classes as well.

Steps to attempt this assignment:

1. Fork this repository.
2. Clone the repository you forked to your computer.
3. Write code and commit it.
4. Push the code back to your fork.
5. paste the repository link on classroom

You can specify your own packages if require.

Please feel free to reach out to me in case of any queries.

*ctrl+c & ctrl+v from assignment 1

About

This repository contains assignment questions on Queue and Binary Search Tree

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages