# Category Archives: Arrays

Given an array arr[] consisting of N integers such that arr[i] representing the number of socks of the color i and an integer K, the… Read More
Given an array arr[] consisting of N positive integers and a positive integer K, the task is to count minimum Bitwise XOR of array elements… Read More
Given an array arr[] consisting of N integers and an integer K, the task is to find the maximum number of disjoint subsets that the… Read More
Given an array arr[] consisting of N positive integers, the task is to find the maximum absolute difference between the sum of the array elements… Read More
Given an array arr[] consisting of N positive integers, the task is to sort the array arr[] according to the increasing order of GCD of… Read More
Given an array, arr[] consisting of N integers, the task for each array element arr[i] is to print the sum of |i – j| for… Read More
Given an array arr[] consisting of N positive integers, the task is to find an array element X such that sum of its absolute differences… Read More
Given an array arr[] consisting of N integers and two positive integers L and R, the task is to find the farthest co-prime number in… Read More
Given an array arr[] consisting of N positive integers, the task is to find the minimum number of bits of array elements required to be… Read More
Given an array arr[] consisting of N integers and an integer K, the task is to find the sum of the array elements possible by… Read More
Given two arrays arr[] and S[] consisting of N and K integers, the task is to find the maximum sum of minimum and maximum of… Read More
Given an array arr[] consisting of N integers, the task is to check if the sum of all possible values of (arr[i] / j) for… Read More
Given a 2D array arr[] consisting of information of N trains where arr[i] is the train number, arr[i] is the arrival time, and arr[i] is… Read More
Given an array arr[] consisting of N integers, the task is to split the array into subarrays such that the sum of the difference between… Read More
Given an array arr[] consisting of N integers, the task is to find the minimum number of array elements required to be incremented to make… Read More