EasyRating 800
No Change Needed
A shovel costs k taka. You have many 10-taka coins and exactly one coin of r taka (1 ≤ r ≤ 9). What is the fewest shovels you can buy so you can pay exactly (at least one)?
Input
Two integers k (1 ≤ k ≤ 1000) and r.
Output
One integer.
Sample 1
Input
117 3
Output
9
Sample 2
Input
237 7
Output
1
Output appears here