@Eliminateur in accounting, each item is logged by both the gain and the loss, so when you log a purchase of something for 20$, you write it as gaining 20$ of inventory and losing 20$ of cash/credit/etc. The difference of the totals of gains and loss on a ledger should balance to zero.
In this situation, they accidentally wrote 200 on one side and 20 on the other, so when the totals were subtracted (assuming that was the only mistake) the difference would be 180. the trick of dividing by 9 is because one of the "20"s was already taken out when taking the difference, and 200/10 is equal to (200-20)/9
once you know that 20$ is the problem you just gotta figure out which item is worth that much and check the calculation for errors
Sincerely, an accounting major