## GCD of factorials of two numbers

Given two numbers m and n. Find the GCD of the their factorial. Examples : Input : n = 3, m = 4 Output :… Read More »

- Program to calculate the value of nPr
- Number of ways to go from one point to another in a grid
- Check if factorial of N is divisible by the sum of squares of first N natural numbers
- Find GCD of factorial of elements of given array
- Number of ways to arrange K different objects taking N objects at a time
- Check whether factorial of N is divisible by sum of first N natural numbers
- Count of N digit numbers possible which satisfy the given conditions
- Count numbers having N 0's and and M 1's with no leading zeros
- Find the smallest number X such that X! contains at least Y trailing zeros.
- Factorial of an Array of integers
- Find sum of factorials in an array
- Find the count of M character words which have at least one character repeated
- Check if a given number divides the sum of the factorials of its digits
- Count different numbers possible using all the digits their frequency times
- Calculate MDAS Factorial of given number
- Euler zigzag numbers ( Alternating Permutation )

Given two numbers m and n. Find the GCD of the their factorial. Examples : Input : n = 3, m = 4 Output :… Read More »

A number is said to be a Peterson number if the sum of factorials of each digit of the number is equal to the number… Read More »

Given two numbers k and n, find the largest power of k that divides n! Constraints: K > 1 Examples: Input : n = 7,… Read More »

Factorial of a non-negative integer, is multiplication of all integers smaller than or equal to n. Example : Factorial of 6 is 6 * 5… Read More »

A number N is called a factorial number if it is the factorial of a positive integer. For example, the first few factorial numbers are… Read More »

We are given two numbers A and B such that B >= A. We need to compute the last digit of this resulting F such… Read More »

You have been given a series 1/1! + 2/2! + 3/3! + 4/4! +…….+ n/n!, find out the sum of the series till nth term.… Read More »

This approach is based on Wilson’s theorem and using the fact that factorial computation can be done easily using DP Wilson theorem says if a… Read More »

Given a number ‘n’ and a prime number ‘p’. We need to find out the power of ‘p’ in the prime factorization of n! Examples:… Read More »

We are aware of calculating factorials using loops or recursion, but if we are asked to calculate factorial without using any loop or recursion. Yes,… Read More »

A Krishnamurthy number is a number whose sum of the factorial of digits is equal to the number itself. For example 145, sum of factorial… Read More »

Given an integer n, we need to find a range of positive integers such that all the number in that range are composite and length… Read More »

Given a number N. You are tasked with finding the smallest number S, such that N is a factor of S! (S factorial). N can… Read More »

Given a number n, write code to find the sum of digits in the factorial of the number. Given n <= 5000 Examples: Input :… Read More »

Given a number n, we need to calculate the sum of divisors of factorial of the number. Examples: Input : 4 Output : 60 Factorial… Read More »