## Number of shortest paths in an unweighted and directed graph

Given an unweighted directed graph, can be cyclic or acyclic. Print the number of shortest paths from a given vertex to each of the vertices.… Read More »

- Breadth First Search or BFS for a Graph
- Top 10 algorithms in Interview Questions
- Top 10 Algorithms and Data Structures for Competitive Programming
- BFS vs DFS for Binary Tree
- Detect cycle in an undirected graph
- Minimum steps to reach target by a Knight | Set 1
- Check whether a given graph is Bipartite or not
- Print Nodes in Top View of Binary Tree
- Shortest path in a Binary Maze
- Minimum time required to rot all oranges
- Connected Components in an undirected graph
- Snake and Ladder Problem
- Applications of Breadth First Traversal
- Minimum number of operation required to convert number x into y
- Articulation Points (or Cut Vertices) in a Graph
- Boggle | Set 2 (Using Trie)
- Minimum steps to reach a destination
- Find if there is a path between two vertices in a directed graph
- Shortest path in an unweighted graph
- Water Jug problem using BFS
- Find length of the largest region in Boolean Matrix
- Word Ladder (Length of shortest chain to reach a target word)
- Print all Jumping Numbers smaller than or equal to a given value
- Check if a graph is strongly connected | Set 1 (Kosaraju using DFS)
- Find whether there is path between two cells in matrix
- BFS using STL for competitive coding
- Count the number of nodes at given level in a tree using BFS.
- Print all paths from a given source to a destination using BFS
- Check if a given graph is tree or not
- Find the minimum number of moves needed to move from one cell of matrix to another

Given an unweighted directed graph, can be cyclic or acyclic. Print the number of shortest paths from a given vertex to each of the vertices.… Read More »

Given a unweighted graph, a source and a destination, we need to find shortest path from source to destination in the graph in most optimal… Read More »

We are given an integer N. We need to write a program to find the least positive integer X made up of only digits 9’s… Read More »

Breadth-first search traversal of a graph using the algorithm given in CLRS book. BFS is one of the ways to traverse a graph. It is… Read More »

BFS(Breadth First Search) is a graph traversal technique where a node and its neighbors are visited first and then the neighbors of neighbors. In simple… Read More »

Round 1: The first round consisted of two coding questions to be solved in 1 hr – Given a binary tree, print the boundary of… Read More »

Given a tree represented as undirected graph. Count the number of nodes at given level l. It may be assumed that vertex 0 is root… Read More »

I applied through an employee referral for SDET-1 position. I was interviewed at Amazon Chennai(SP Infocity).I faced 5 face to face rounds. On October 11th,… Read More »

Given two four digit prime numbers, suppose 1033 and 8179, we need to find the shortest path from 1033 to 8179 by altering only single… Read More »

Pablo has square chocolate Box of size n x n in which a variety of healthy chocolates are present denoted by ‘H’ initially but he… Read More »

N-ary tree refers to the rooted tree in which each node having atmost k child nodes. The diameter of n-ary tree is the longest path… Read More »

You are given a m litre jug and a n litre jug . Both the jugs are initially empty. The jugs don’t have markings to… Read More »

A STL based simple implementation of BFS using queue and vector in STL. The adjacency list is represented using vectors of vector. In BFS, we… Read More »

Given a directory, print all files and folders present in directory tree rooted with given directory. We can iteratively traverse directory in BFS using below… Read More »

Suppose A is at position (0, 0) of a 2-D grid containing ‘m’ rows and ‘n’ columns. His aim is to reach the bottom right… Read More »