Skip to content

Latest commit

 

History

History
18 lines (14 loc) · 373 Bytes

File metadata and controls

18 lines (14 loc) · 373 Bytes

Replace digit

Given the number n, as well as digits a and b. Replace in this number every occurrence of the digit a to digit b.

Input

Three numbers n, a, b (1 ≤ n ≤ 10⁹).

Output

Print the resulting number. Do not print the leading zeros.

Input example

123118 1 5

Output example

523558