## Minimum cost to reverse edges such that there is path between every pair of nodes

Given a connected, directional graph. Each node is connected to exactly two other nodes. There is weight associated with each edge denoting the cost to… Read More »

- Live Classes for Data Structures and Algorithms: Interview Preparation Focused Course
- Playfair Cipher with Examples
- Count of triplets that satisfy the given equation
- Maximum Sequence Length | Collatz Conjecture
- Implementation of BFS using adjacency matrix
- Find a pair (n,r) in an integer array such that value of nPr is maximum
- Minimum increment or decrement operations required to make the array sorted
- Maximum XOR of Two Numbers in an Array
- Check if the rows of a binary matrix can be made unique by removing a single column
- Longest Increasing Subsequence using Longest Common Subsequence Algorithm
- Color all boxes in line such that every M consecutive boxes are unique
- Count the number of elements which are greater than any of element on right side of an array
- Count all substrings having character K
- Count of triples (A, B, C) where A*C is greater than B*B
- Minimum increment operations to make K elements equal
- Maximise the number of toys that can be purchased with amount K using min Heap
- Number of sub arrays with negative product
- Minimize the cost of partitioning an array into K groups
- Find a pair (n,r) in an integer array such that value of nCr is maximum
- Minimum distance to visit all the nodes of an undirected weighted tree
- Widest Path Problem | Practical application of Dijkstra's Algorithm
- Count the values greater than X in the modified array
- Maximize the Expression | Bit Manipulation
- Maximum non-attacking Knights that can be placed on an N*M Chessboard
- Sum of absolute differences of pairs from the given array that satisfy the given condition
- Expand the string according to the given conditions
- Comparing X^Y and Y^X for very large values of X and Y
- Implementation of DFS using adjacency matrix
- Find all numbers between range L to R such that sum of digit and sum of square of digit is prime
- Minimum number of additons to make the string balanced

Given a connected, directional graph. Each node is connected to exactly two other nodes. There is weight associated with each edge denoting the cost to… Read More »

Given an array arr[] of N positive integers, the task is to find the count of indices i such that all the elements from arr[0]… Read More »

Given a binary array arr[] of size N. The task is to find the minimum number of inversions required so that no two adjacent elements… Read More »

Given a level N, the task is to find the sum of all the integers present at this given level in an Alternating Pascal’s triangle.… Read More »

Given an array arr[] of size N which represents the initial number on each card and given a two dimensional array B[][] of size M… Read More »

Given an array arr[] of size N > 1. The task is to find the maximum possible GCD of the array by replacing at most… Read More »

Given an array arr[] of size N, the task is to find the maximum sum of the elements of the array after applying the given… Read More »

An introduction to the transportation problem has been discussed in this article. In this article, the method to solve the unbalanced transportation problem will be… Read More »

Given an array arr[] of N non-negative integers and an integer 1 ≤ K ≤ N. The task is to find the sum of the… Read More »

A sequence of positive real numbers S1, S2, S3, …, SN is called a superincreasing sequence if every element of the sequence is greater than… Read More »

Given an undirected graph with N vertices and N edges. No two edges connect the same pair of vertices. A triangle is a set of… Read More »

Given an integer D, the task is to find the sum of all the prime numbers whose maximum position of set bits (farthest set bit… Read More »

Given a row of silver coins among which a special gold coin is present. Two players play the game, and with each move, a player… Read More »

Given two integer A and B, the task is to check whether the binary representation of B can be generated by permuting the binary digits… Read More »

Transportation problem is a special kind of Linear Programming Problem (LPP) in which goods are transported from a set of sources to a set of… Read More »