## Largest Divisor for each element in an array other than 1 and the number itself

Given an array arr[] of N integers, the task is to find the largest divisor for each element in an array other than 1 and… 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 an array arr[] of N integers, the task is to find the largest divisor for each element in an array other than 1 and… Read More »

Given an unsorted array arr[] and an integer K, the task is to count the occurrences of K in the given array using Divide and… Read More »

Given a number N in decimal base, the task is to find the sum of digits of the number in any base B. Examples: Input:… Read More »

Given a number A in decimal base, the task is to find the Nth digit from last in base B Examples: Input: A = 100,… Read More »

Given a string consisting of characters a and b, check if the string starts and ends with the same character or not. If it does,… Read More »

Given a number N, the task is to find the Nth term in series 2, 3, 10, 15, 26…. Example: Input: N = 2 Output:… Read More »

Given a number N, the task is to find the Nth term in series 12, 35, 81, 173, 357, … Example: Input: N = 2… Read More »

Given a number N, the task is to find the N-th term in series 4, 2, 2, 3, 6, … Example: Input: N = 2… Read More »

Given an unsorted array arr[] of length N, the task is to find the median of of this array. Median of a sorted array of… Read More »

Prerequisite: Deterministic Finite Automata Given a string str consists of characters ‘a’ & ‘b’. The task is to check whether string str starts and ends… Read More »

Given a number N, the task is to convert every digit of the number into words. Examples: Input: N = 1234 Output: One Two Three… Read More »

Given an array arr[] of N integers, the task is to find the count of all the subsequences of the array that have a negative… Read More »

Given three integers A, B and L, the task is to print the ternary cantor set from range [A, B] upto L levels. Ternary Cantor… Read More »

Prerequisite: Arrays in C++, Vector in C++ STL An array is a collection of items stored at contiguous memory locations. It is to store multiple… Read More »

Consider a grid of dimensions NxM and an array R consisting of available circular obstacles, the task is to find the minimum number of circular… Read More »