Skip to main content

Posts

Featured

Height of Binary Tree | GFG|

 class Solution {     //Function to find the height of a binary tree.     int height(Node node)      {         // code here           if(node==null) return 0;         Stack<Node> q=new Stack<Node>();         q.add(node);         while(!q.isEmpty())         {             Node curr=q.peek();             {                 if(curr.left!=null)                 {                     q.add(curr.left);                 }                 else if(curr.right!=null)                 {          ...

Latest posts

Find Longest Palindrome String | Leet Code| JAVA

LeetCode 121. Best Time to Buy and Sell Stock

Merge Intervals Leet code solution

Intersection of Two Linked Lists Solution Leet code

Linked List Cycle II Solution LEET code

Remove Nth Node From End of List Solution LEET CODE

HACKERRANK :-SPLIT ARRAY EXAMPLE

HACKERANK PROGRAME:- DICTIONARY ONE

BUBBLE SORT SHORTEST TECHNIQUE

CALENDER CLASS OF JAVA PROGRAME