Tap here to switch tabs
Problem
Submissions

Problem: Check Digitorial Permutation

Try to solve the Check Digitorial Permutation problem.

Statement

Given an integer n, determine whether there exists a valid permutation of the digits of n that is equal to the sum of the factorials of its digits.

A permutation of digits is considered valid if it does not have leading zeros.

Constraints:

  • 1≤1 \leq n ≤109\leq 10^9

⋮
Tap here to switch tabs
Problem
Submissions

Problem: Check Digitorial Permutation

Try to solve the Check Digitorial Permutation problem.

Statement

Given an integer n, determine whether there exists a valid permutation of the digits of n that is equal to the sum of the factorials of its digits.

A permutation of digits is considered valid if it does not have leading zeros.

Constraints:

  • 1≤1 \leq n ≤109\leq 10^9