Finding the difference between numbers in a ratio