# Searching

### Rabbit House | Google Kickstart 2021 Round A

#include using namespace std;  void solve(long long int r, long long int c,           vector& grid){    priority_queue        pq;      for (long long int i = 0; i…

### Count of different numbers divisible by 3 that can be obtained by changing at most one digit

Given a string str[] number N, the task is to calculate the number of ways to make the given number…

### Maximum number of teams of size K possible with each player from different country

Given an array arr[] consisting of N positive integers and a  positive integer K such that there are N countries,…

### Modify a numeric string to a balanced parentheses by replacements

#include using namespace std;void balBracketSequence(string str){    int n = str.size();            if (str        == str[n – 1])    {        cout

### Rearrange Array to find K using Binary Search algorithm without sorting

#include using namespace std;  void Rearrange(int arr[], int K, int N){        int ans[N + 1];              int f = -1;      for (int i = 0;…

### Minimum value of X such that sum of arr[i] – X raised to the power of brr[i] is less than or equal to K

Given an array arr[] and brr[] both consisting of N integers and a positive integer K, the task is to…

### Maximize the smallest array element by incrementing all elements in a K-length subarray by 1 exactly M times

Given an array arr[] of size N, and integers M and K, the task is to find the maximum possible…

### Altitude of largest Triangle that can be inscribed in a Rectangle

Given a rectangle of length L and breadth B, the task is to print the maximum integer altitude possible of…