Given a natural number N, the task is to find the Nth compositorial number....
Given the number of orders, find the number of valid arrangements of orders where delivery of ith order is always after the pickup of ith order....
Given a large number N, the task is to find the factorial of N using recursion....
Given a positive number N, the task is to calculate the factorial of N without using the multiplication operator....
Given a range [L, R], and a prime number P. We are required to find the sum of the highest power of P in all numbers from L to R.Examples:...
Given a string where . Assume that all the characters in are unique. The task is to compute the minimum length of a string which consists of all the permutations of the given string in any order....
Given two numbers, fact and n, find the largest power of n that divides fact! (Factorial of fact)....
Given two integer N and M, the task is to find the number of distinct numbers having N 0’s and M 1’s with no leading zeros and N + M total digits....
Given two numbers k and n, find the largest power of k that divides n! Constraints: K > 1...
Given an array arr[] of integers, the task is to find the count of permutation of the array such that the permutation is in increasing order i.e. arr[0] ? arr[1] ? arr[2] ? … ? arr[n – 1].Examples:...
Given an integer N, the task is to count the number of prime factors of N!....
Given an integer N, the task is to find the value of the expression ( N1 * (N – 1)2 * … * 1N) % (109 + 7)....