Month: July 2017

05
Jul
2017

Interview Question: Stack vs Heap

best:  

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…

04
Jul
2017

Binary Search Tree

youtube : code: #include<iostream> using namespace std; //Definition of Node for Binary search tree struct BstNode {…

02
Jul
2017

Hackerearth: COUNT NUMBERS

code: #include<bits/stdc++.h> using namespace std; int main() { int t,n,i,a; string s; cin>>t; while(t–) { int c=0;…

02
Jul
2017

Hackerearth: Fredo and Game

code: #include<bits/stdc++.h> using namespace std; int main() { int t,i,a,n; cin>>t; while(t–) { cin>>a>>n; int arr[n]; for(i=0;…

02
Jul
2017

Hackerearth: Little Jhool and psychic powers

code: #include<bits/stdc++.h> using namespace std; int main() { int zz,oo; string S; string z=”000000″; string o=”111111″; cin>>S;…