Skip to content

Tag Archives: Bitwise-AND

Given an array arr[] consisting of N positive integers, the task is to find the largest size of the subset of the array arr[] with… Read More
Given an array arr[] of N integers, the task is to find the number of subsequences of the given array such that their Bitwise AND… Read More
Given two positive integers X and K, the task is to find the Kth smallest positive integer (Y) such that the sum of X and… Read More
Given an integer N, the task is to find the maximum value of K such that N & (N-1) & (N-2) & … & (K)… Read More
Given an array arr[] consisting of N positive integers and an array of queries Q[] of type [L, R], the task is to find the… Read More
Given two integers X and Y, the task is to find two numbers whose Bitwise OR is X and their sum is Y. If there… Read More
Given two positive integers N and K, the task is to find the number of arrays of size N such that each array element lies… Read More
Given a positive integer N, the task is to print the minimum count of consecutive numbers less than N such that the bitwise AND of… Read More
Given a positive integer N, the task is to count the number of N-digit numbers such that the bitwise AND of adjacent digits equals 0.… Read More
Given two arrays arr[] of size N and queries[] of size Q, the task is to find the OR of AND of subsets of the… Read More
Given an integer N, the task is to find the smallest number K such that bitwise AND of all the numbers in range [N, N-K]… Read More
Given two positive integers A and B, the task is to calculate the minimum number of operations required such that Bitwise OR of A and… Read More
Given two arrays A and B of sizes N and M respectively, the task is to calculate the XOR sum of bitwise ANDs of all… Read More
Given an array arr[] consisting of N positive integers, the task is to find the sum of Bitwise AND of all possible triplets (arr[i], arr[j],… Read More
Given a positive integer N, the task is to count all numbers which are less than N and Bitwise AND of all such numbers with… Read More