#D13284. Sum of Last Digits

    ID: 11049 Type: Default 1000ms 268MiB

Sum of Last Digits

Sum of Last Digits

Problem

Given the three integers n, m, k

n1% 10 + n1 + m% 10 + n1 + 2m% 10 + ... + n1 + (k-1) m% 10

Calculate. a% b represents the remainder when a is divided by b.

Constraints

Input meets the following conditions

  • 0 ≤ n ≤ 1018
  • 0 ≤ m ≤ 109
  • 1 ≤ k ≤ 109

Input

n m k

One line is given n, m, k.

Output

Print the answer on one line.

Examples

Input

1 1 9

Output

9

Input

2 1 3

Output

14

Input

6 11 11

Output

66

Input

100 7 12

Output

0

Input

123 123 3

Output

11

inputFormat

Input meets the following conditions

  • 0 ≤ n ≤ 1018
  • 0 ≤ m ≤ 109
  • 1 ≤ k ≤ 109

Input

n m k

One line is given n, m, k.

outputFormat

Output

Print the answer on one line.

Examples

Input

1 1 9

Output

9

Input

2 1 3

Output

14

Input

6 11 11

Output

66

Input

100 7 12

Output

0

Input

123 123 3

Output

11

样例

1 1 9
9