Skip to content

Tag Archives: maths-perfect-square

Given an integer N. The task is to find the number of pairs of integers (x, y) both less than N and greater than 1,… Read More
Given an integer K, the task is to find two consecutive perfect squares whose difference is K. If there don’t exist any such pairs of… Read More
Given a positive integer N, the task is to find the maximum number of unique squares that can be formed with N arbitrary points in… Read More
Given an array arr[](1-based indexing) consisting of N integers, the task is to find the last element remaining element after repeated removal of array element… Read More
Given an array arr[] consisting of N positive integers, the task is to check if the product of elements of every subsequence of the given… Read More
Given an array arr[] consisting of N positive integers, the task is to print the nearest perfect square for each array element. Examples: Input: arr[]… Read More
Given an integer N, the task is to find the number of ways to represent the number N as sum of perfect squares. Examples: Input:… Read More
Given a positive integer N, the task is to check if N can be represented as a sum of a Prime Number and a Perfect… Read More
Given an array arr[ ] of size N, the task for each array element is to print the nearest perfect square having same parity. Examples:… Read More
Given an array arr[] consisting of N positive integers, the task is to find the nearest perfect power of 2 of the nearest perfect squares… Read More
Given an array points[] representing N points in a K-dimensional space, the task is to find the count of pairs of points in the space… Read More
Given an array arr[] of size N consisting of only of 0s initially, the task is to count the number of 1s that can be… Read More
Given array arr[] consisting of N non-negative integers, and an integer K, the task is to check if GCD of all composite numbers in the… Read More
Given a singly linked list containing N nodes, the task is to find the sum of all possible nodes of the list which contains value… Read More