Category: Algorithm

07
Jul
2017

Bucket Sort

Pseudocode: bucketSort(arr[], n) 1) Create n empty buckets (Or lists). 2) Do following for every array element…

07
Jul
2017

Radix Sort

best video: pseudocode: Radix-Sort(A, d) //It works same as counting sort for d number of passes. //Each…

07
Jul
2017

Counting Sort

Algo: COUNTING-SORT(A,B,k) 1. let C[0..k] be a new array 2. for i = 0 to k 3….

06
Jul
2017

Binary Search Tree: Successor in Inorder Traversal

code: /* C++ program to find Inorder successor in a BST */ #include<bits/stdc++.h> using namespace std; struct…

05
Jul
2017

Delete a node in Binary Search Tree

code: #include<bits/stdc++.h> using namespace std; struct Node{ int data; struct Node* left; struct Node* right; }; Node*…

04
Jul
2017

Traversal in Binary Search Tree

Height of a binary tree:   Level Order BFS in Binary Search Tree: #include<bits/stdc++.h> #include<queue> using namespace…