Skip to main content
Tuesday (24.11.2026) at 20:00: ALGOR Contest: Round #4 (Special Challenge) starts!

~/algor $ cat problems/while-raqamlar-kopaytmasi

Product of digits

Easy 1000 ms 64 MB 29%
Share

A positive integer $n$ is given. Compute the product of all its digits.

Multiplying all the digits of the number together

Input

One positive integer $n$.

Output

One integer — the product of digits.

Note

$1 \le n \le 10^{9}$

Examples

Input #1
1234
Output #1
24
Input #2
2305
Output #2
0

Sign in to submit a solution

Signing up is free and takes a minute.