## Least cost path in given digraph from given source to destination having exactly m edges

Given a weighted digraph (Directed Graph), find the least cost path from given source to destination that have exactly m edges.

Coding made easy

Given a weighted digraph (Directed Graph), find the least cost path from given source to destination that have exactly m edges.

Given a string, find first non-repeating character in it by doing only one traversal of it.

Given a binary tree that is only one swap away from becoming a BST, convert the binary tree into BST in single traversal of it.

Given a binary tree, write an efficient algorithm to find maximum sum path between any two leaves in it.

Given a binary M x N row-wise sorted matrix, find a row which contains maximum number of 1 in linear time.

Given an unsorted array of integers whose each element lies in range 0 to n-1 where n is the size of the array, calculate the frequency of all elements present in the array in linear time and using constant space.

Given a string, in-place remove all adjacent duplicates from it. The algorithm should continue removing adjacent duplicates from the string till no duplicate is present in the result.

Given a binary tree, write an efficient algorithm to find all nodes present at given distance from any leaf node. We need to find only those nodes that are present in root-to-leaf path for that leaf.

Given an expression consisting of opening brace ‘{‘ and a closing brace ‘}’, find the minimum number of inversions needed to make the expression balanced.

Given a positive integer n, print all combination of numbers from 1 to n having sum n.

Given a weighted graph, find the maximum cost path from given source to destination that isĀ greater than a given integer x. The path should not contain any cycles.

Given an array of distinct integers, replace each element of the array by its corresponding rank in the array.