Tap here to switch tabs
Problem
Submissions

Problem: Subtract the Product and Sum of Digits of an Integer

med
30 min
Try to solve the Subtract the Product and Sum of Digits of an Integer problem.

Statement

Given an integer n, compute and return the difference between the product of its digits and the sum of its digits.

Constraints:

  • 1≤1 \leq n ≤105\leq 10^5

⋮
Tap here to switch tabs
Problem
Submissions

Problem: Subtract the Product and Sum of Digits of an Integer

med
30 min
Try to solve the Subtract the Product and Sum of Digits of an Integer problem.

Statement

Given an integer n, compute and return the difference between the product of its digits and the sum of its digits.

Constraints:

  • 1≤1 \leq n ≤105\leq 10^5