Yin: Cash Account
Yang: Salary Account
(amount: $salary)
When you spend from that cash, you record it as this tuple: Yin: Dinner Expense
Yang: Cash Account
(amount: $bill_amount)
If you get your salary through cheque, it looks like this: Yin: The Bank Account
Yang: Salary Account
When you borrow: Yin: Cash Account
Yang: The Creditor Friend
And vice versa when you pay it back.Now replace Yin with Debit and Yang with Credit, and that's mostly it.