## Detect loop in a linked list

Given a linked list, check if the linked list has loop or not. Below diagram shows a linked list with a loop. Recommended: Please solve… Read More »

- Count of triplets that satisfy the given equation
- Write a function to get the intersection point of two Linked Lists | Set 2
- Print nodes having maximum and minimum degrees
- Number of triplets in array having subarray xor equal
- Minimum distance to visit all the nodes of an undirected weighted tree
- Widest Path Problem | Practical application of Dijkstra's Algorithm
- Find maximum count of duplicate nodes in a Binary Search Tree
- Twisted Tower of Hanoi Problem
- Minimum characters that are to be inserted such that no three consecutive characters are same
- Minimum value to be assigned to the elements so that sum becomes greater than initial sum
- Implementation of Non-Preemptive Shortest Job First using Priority Queue
- Sorting Algorithms Visualization | Selection Sort
- Queries to find the left-most given type integer in a binary array
- Van Emde Boas Tree | Set 4 | Deletion
- Difference between Linear and Non-linear Data Structures
- Skewed Binary Tree
- Extended Binary Tree

Given a linked list, check if the linked list has loop or not. Below diagram shows a linked list with a loop. Recommended: Please solve… Read More »

Given pointer to the head node of a linked list, the task is to reverse the linked list. We need to reverse the list by… Read More »

It depends on what traversals are given. If one of the traversal methods is Inorder then the tree can be constructed, otherwise not. Therefore, following… Read More »

A permutation, also called an “arrangement number” or “order,” is a rearrangement of the elements of an ordered list S into a one-to-one correspondence with… Read More »

A simple solution is to traverse the linked list until you find the node you want to delete. But this solution requires pointer to the… Read More »

Given a singly linked list and a key, count number of occurrences of given key in linked list. For example, if given linked list is… Read More »

Algorithm For C/C++: Iterate through the linked list and delete all the nodes one by one. Main point here is not to access next of… Read More »

Given a Linked List and a number n, write a function that returns the value at the n’th node from the end of the Linked… Read More »

Given a singly linked list, find middle of the linked list. For example, if given linked list is 1->2->3->4->5 then output should be 3. If… Read More »

Ugly numbers are numbers whose only prime factors are 2, 3 or 5. The sequence 1, 2, 3, 4, 5, 6, 8, 9, 10, 12,… Read More »

Mirror of a Tree: Mirror of a Binary Tree T is another Binary Tree M(T) with left and right children of all non-leaf nodes interchanged.… Read More »

To delete a tree we must traverse all the nodes of the tree and delete them one by one. So which traversal we should use… Read More »

Given a binary tree, find height of it. Height of empty tree is 0 and height of below tree is 3. Example Tree Recommended: Please… Read More »

Two trees are identical when they have same data and arrangement of data is also same. To identify if two trees are identical, we need… Read More »