## Smallest Special Prime which is greater than or equal to a given number

Given a number N. The task is to find the smallest special prime which is greater than or equal to N. A special prime is… Read More »

- Sum of the first N Prime numbers
- Sum of all Primes in a given range using Sieve of Eratosthenes
- Check if a prime number can be expressed as sum of two Prime Numbers
- Sum of all the prime numbers in a given range
- Largest factor of a given number which is a perfect square
- Find a number that divides maximum array elements
- Largest palindromic prime in an array
- Minimum and Maximum prime numbers in an array
- Find two distinct prime numbers with given product
- Count of Prime Nodes of a Singly Linked List
- Count number of integers less than or equal to N which has exactly 9 divisors
- Sum of all prime numbers in an Array
- Smallest prime number missing in an array
- Find the Product of first N Prime Numbers
- Print all safe primes below N
- Check if a number is a Trojan Number
- Check if the sum of primes is divisible by any prime from the array
- Lexicographically largest prime path from top-left to bottom-right in a matrix
- Sum of element whose prime factors are present in array
- Number of divisors of product of N numbers
- Sort prime numbers of an array in descending order
- Longest Prime Subarray after removing one element
- Product of all primes in the range from L to R
- Sum of elements in an array having prime frequency
- Find count of Almost Prime numbers from 1 to N
- Print prime numbers with prime sum of digits in an array
- Sum and product of k smallest and k largest prime numbers in the array
- Count pairs in an array such that at least one element is prime
- Maximum no. of contiguous Prime Numbers in an array
- Check if a number is Primorial Prime or not

Given a number N. The task is to find the smallest special prime which is greater than or equal to N. A special prime is… Read More »

Given a number N. The task is to count the number of prime numbers from 2 to N that can be expressed as a sum… Read More »

Given a range [L, R], the task is to find all the numbers from the range which are composite as well as the eventual sum… Read More »

Given two numbers A and B ( A and B can be up to 106 ) which forms a number N = (A!/B!). The task… Read More »

Given an integer N, the task is to print all the multiplicative primes ≤ N. Multiplicative Primes are the primes such that the product of… Read More »

Given an array arr[] and the task is to print the additive primes in an array. Additive primes: Primes such that the sum of their… Read More »

Given an array arr[] of distinct elements, the task is to count the total number of distinct pairs in which at least one element is… Read More »

Given an integer N, the task is to print all safe primes below N safe primes. A safe prime is a prime number of the… Read More »

Given an array arr[] and the task is to print the sum of the non-prime elements from the array. Examples: Input: arr[] = {1, 3,… Read More »

Given an array arr[] of integers, the task is to count the number of divisors of product of all the elements from given array. Examples:… Read More »

Given an array arr[] of non-negative integers where 2 ≤ arr[i] ≤ 106. The task is to find the sum of all those elements from… Read More »

Given an array arr[] of integers, the task is to print the largest palindromic prime from the array. If no element from the array is… Read More »

Given two integers N and K, the task is to count all the numbers < N which have equal number of positive divisors as K.… Read More »

Given an array arr[], the task is to check whether the sum of primes in the array is divisible by any of the primes in… Read More »

Given an array arr, the task is to find the sum of the elements which have prime frequencies in the array. Note: 1 is neither… Read More »