## Find all the numbers in the range which has prime set bits.

Objective: Given a range, find all the numbers in the range which has prime set bits. Example: L = 4, R = 10 Output: 5 Explanation: 4 = 1 0 0 ( not prime)...

Skip to content# Author: SJ

## Find all the numbers in the range which has prime set bits.

## Check if Graph is Bipartite – Adjacency Matrix using Depth-First Search(DFS)

## Check if Arithmetic Expression contains duplicate parenthesis

## Introduction to Bipartite Graphs OR Bigraphs

## Reverse the Directed Graph

## Round Price Problem

## Smallest Number after Removing K digits

## Find Third Smallest elements in a given array

## Determine the order of Tests when tests have dependencies on each other

## Implement Graph Using Map – Java

## Find the maximum number present in a String

## Count number of subgraphs in a given graph

## Reverse a Stack using recursion – In Place (Without using extra memory)

## Check if given an edge is a bridge in the graph

## Convert Prefix to Postfix Expression

@tutorialhorizon

Objective: Given a range, find all the numbers in the range which has prime set bits. Example: L = 4, R = 10 Output: 5 Explanation: 4 = 1 0 0 ( not prime)...

Objective: Given a graph represented by the adjacency matrix, write a Depth-First Search(DFS) algorithm to check whether the graph is bipartite or not. Bipartite Graphs OR Bigraphs is a graph whose vertices can be...

Objective: Given an arithmetic expression, write an algorithm to find out whether the expression contains duplicate parenthesis. Duplicate Parenthesis: Two contiguous parentheses with no elements between them can be called as duplicate parenthesis. Example:...

Bipartite Graphs OR Bigraphs is a graph whose vertices can be divided into two independent groups or sets, U and V such that each edge in the graph has one end in set U...

Objective: Given a directed graph, write an algorithm to reverse the graph. Example: Approach: Create a new graph with the same number of vertices. Traverse the given graph. Here we are using the adjacency...

Problem Statement: When customers book an Airbnb the total price, which includes base price + service fee + cleaning fee. all these prices are in decimals. Write an algorithm to round each price such...

Objective: Given a number with N digits, write a program to get the smallest number possible after removing k digits from number N. OR Implement a method that returns the lowest possible number that...

Objective: Given an array of integers, write an algorithm to find the third smallest element in the array. Example: Int [] a = { 6, 8, 1, 9, 2, 10}; Output: Third smallest element...

Objective: You are working on a project where QA team has automated set of test cases for the project, but these test cases have to be executed in a specific order since test cases...

Earlier, we have seen Graph and its representations. A graph can be represented using adjacency list and adjacency matrix. So far we have seen the traditional implementation of the Graph. In this article, we...

Given a string with alphabets and numbers. Write an algorithm to find the maximum number in the string. If any number is greater than equal to Max_Value of integer then return the Max_Value. Example:...

Objective: Given a Graph, write a program to count all the subgraphs. Example: Approach: Use Depth-First Search Start the DFS from any random vertex. Once DFS is completed check if all the vertices are...

Objective: Given a Stack, write an algorithm to reverse the stack. Example: Original Stack: [14, 9, 67, 91, 101, 25] Reversed Stack: [25, 101, 91, 67, 9, 14] Approach: Use Recursion In this solution,...

Objective – Given a graph and an edge, write a program to check if the edge is a bridge. Bridge in Graph: An edge is called a bridge if connects two subgraphs and removing...

Objective: Given a Prefix expression, write an algorithm to convert it into Postfix expression. Example: Input: Prefix expression: + A B Output: Postfix expression: A B + Input: Prefix expression: *-A/BC-/AKL Output: Postfix expression:...

%d bloggers like this: