## Sort an array according to the increasing count of distinct Prime Factors

Given an array of integers. The task is to sort the given array on the basis increasing count of distinct prime factors. Examples: Input :… Read More »

- Print all prime numbers less than or equal to N
- C Program to Check Whether a Number is Prime or not
- Length of largest sub-array having primes strictly greater than non-primes
- Queries of nCr%p in O(1) time complexity
- Find next palindrome prime
- Numbers less than N which are product of exactly two distinct prime numbers
- Count number of primes in an array
- Count number of integers less than or equal to N which has exactly 9 divisors
- Product of all primes in the range from L to R
- Number of Co-prime pairs from 1 to N with product equals to N
- Find two distinct prime numbers with given product
- Check whether the given number is Wagstaff prime or not
- Sum of the first N Prime numbers
- Check if a prime number can be expressed as sum of two Prime Numbers
- Sum of every K’th prime number in an array
- Smallest prime number missing in an array
- Sum of all the prime divisors of a number
- Sort prime numbers of an array in descending order
- Delete all Prime Nodes from a Singly Linked List
- Check if a number is Quartan Prime or not
- Number which has the maximum number of distinct prime factors in the range M to N
- Check whether the given number is Euclid Number or not
- Count and Sum of composite elements in an array
- Find four factors of N with maximum product and sum equal to N | Set 3
- Sort an array according to the increasing count of distinct Prime Factors
- Count subarrays with Prime sum
- Sum of all prime divisors of all the numbers in range L-R
- Find the super power of a given Number
- Number of prime pairs in an array
- Count of Prime Nodes of a Singly Linked List

Given an array of integers. The task is to sort the given array on the basis increasing count of distinct prime factors. Examples: Input :… Read More »

Given an array having N elements. The task is to check if the sum of prime elements of the array is prime or not. Examples:… Read More »

Given a prime number . The task is to check if it is possible to express as sum of two separate prime numbers. Note: The… Read More »

Given a string , the task is to check if the frequencies of all the characters of the string are prime or not. If all… Read More »

Given an array containing n distinct numbers. The task is to find the smallest prime which is not present in the array. Examples: Input: arr[]… Read More »

Given an array A[] of integers. The task is to count total subarrays whose sum is prime with ( size > 1 ). Examples: Input… Read More »

Given a string containing only lowercase english alphabets. The task is to find the bitwise XOR of all the prime frequencies of the characters in… Read More »

Given an integer k and an array of integers arr (less than 10^6), the task is to find the sum of every k’th prime number… Read More »

Given an integer . The task is to find the superpower from the factorization of . The Superpower is the highest power among the power… Read More »

Given an array arr[] of N positive integers. The task is to find the sum of all composite elements which are divisible by a given… Read More »

Given a singly linked list containing N nodes, the task is to find the total count of prime numbers. Examples: Input: List = 15 ->… Read More »

Given an array of integers. The task is to calculate the product of all the composite numbers in an array. Note: 1 is neither prime… Read More »

Given an array ‘arr’ of positive integers, the task is to count the number of composite numbers in the array. Note: 1 is neither Prime… Read More »

Given an array of integers ‘arr’, the task is to sort all the prime numbers from the array in descending order in their relative positions… Read More »

Given a number N(1<=N<=109), the task is to find the total number of integers less than equal to n which have exactly 9 divisors. Examples:… Read More »