Amazon Interview Question

To secure the code about decrease an amount of money from account a and increase the same amount of money on account b.