Given an integer array nums, return the sum of floor(nums[i] / nums[j]) for all pairs of indices 0 <= i, j < nums.length in the array. The floor() function returns the integer Read more →
Programs
1 postIn a country some special kinds of coins are available. The coin’s value is decided by a rule, that the values of the coins are first N positive odd numbers. As an Read more →
Mithlesh has ‘N’ buckets each consisting of some fruits. Mithlesh wants to eat at least ‘M’ fruits and so, he decided to set a marker (integer) as maximum as possible such that Read more →
You are given a m*n row wise sorted matrix. The task is to find the common element in all rows of given matrix. Examples: Input : mat[3][4]={{1,3,5,6}, {3,4,7,8}, {1,2,3,4}} Output: 3 Input Read more →
Given a vector vec, and a integer K the task is to count the number of elements such that it occurs only once in the vector and with the number Kth times Read more →
Given two arrays a and b of the same size. Find the count of total pair in array a, such that the sum of elements of pair of array a is greater Read more →
Given an array consisting of integers in range 1 to n consisting of only one duplicate element. Find out the duplicate element in O(logN) time. Examples: Input : 6 1 1 2 Read more →
Given n strings in any order. Sort all the strings (lexicographically), but if a string is present completely as a prefix in another string, then string with larger length should come first. Read more →
You are given an array of integers and sum. You have to find out if there exist a pair of sum is equal to that sum or not. Print “Yes” if exist, Read more →
Given an array of N size denotes number of students and element of array denotes marks of students ,marks belongs between 1 to 100, where A[i] is less or equal to 32 Read more →