A combination lock contains several dials. Each dial is marked with numbers from 0 to 9 (after 9 comes 0 again).
In one action, you can grasp one or two adjacent dials with your fingers and rotate them together at any angle. Determine the minimum number of such actions required to open the lock.
The first line of the input data contains the initial code on the lock. The second line contains the code to open the lock. The lengths of the lines are equal and do not exceed $$$10^5$$$.
Print one integer — the minimum number of actions to open the lock.
00007329
3
In the example, you can proceed as follows. Rotate the first (top) disk to get the code 7000. Then rotate the second and third disks simultaneously to get the code 7330. Finally, rotate the last two disks simultaneously to get the code 7329. A total of 3 steps.
| Name |
|---|


