## Check whether all the bits are unset in the given range

Given a non-negative number n and two values l and r. The problem is to check whether all the bits are unset or not in… Read More »

Given a non-negative number n and two values l and r. The problem is to check whether all the bits are unset or not in… Read More »

BitSet is a class defined in the java.util package. It creates an array of bits represented by boolean values. Syntax public void xor(BitSet set); Explanation:… Read More »

Given two binary strings. The task is to check if string s1 can be converted to string s2 by performing the given operations any number… Read More »

Given a number N and the min and max range. Given N values of a and b respectively. The task is to count the number… Read More »

Given an array A of size n. the task is to generate a new sequence B with size N^2 having elements sum of every pair… Read More »

Given an array where all elements appear even number of times except two, print the two odd occurring elements. It may be assumed that the… Read More »

Given an array of N numbers and a number K. The task is to insert a number in the given array such that the bitwise… Read More »

Here is a cipher algorithm, based on hexadecimal strings that is implemented by XORing the given plaintext, N number of times where N is its… Read More »

You are given a sequence of N integers and Q queries. In each query, you are given two parameters L and R. You have to… Read More »

Given an array arr[] of n integers and some queries. Each query is of the form (L, R), where L and R are indices of… Read More »

A Levelwise OR/XOR alternating segment tree is a segment tree, such that at every level the operations OR and XOR alternate. In other words at… Read More »

Given two strings which are of lengths n and n+1. The second string contains all the character of the first string, but there is one… Read More »

You are given an array A[] of n-elements. There are two players Alice and Bob. A Player can choose any of element from array and… Read More »

We are given an array arr[] of size n. Numbers are from 1 to (n-1) in random order. The array has only one repetitive element.… Read More »

Given an integer N, we need to find three integers(X, Y, Z) which can form a triangle with the following conditions: Lengths of sides are… Read More »