Note that 10 dimes = $1
Therefore , 40 dimes = 40/10 = $4
So if you had 40 dimes, its equivalent to you having $4
To get $5, if you already have $4 , you will be needing $1 more
Convert $1 to nickels
But 20 nickels = $1
Hence, you will be needing 20 nickels to get $5