Don't implement burn function but rather transfer tokens (that you
want to burn) to 0x0 address and implement 'totalBalance()function
astotalBalance - balances[0x0]`
I'll not prefer 2nd one, there is a catch in this method. Let's assume in future some one created account address 0, then he will get access for all burn coins. Some of the people are following this process because its easy track who is burning coin's using https://etherscan.io or any block explorer. People are saying its not possible to create an account with 0x address.
implement a burn function that decreases balances[msg.sender] and
This is one of the best way to burn coins and your not transfer to any one account, i.e its actually burning coins from the chain(changes will happens from block).
So I'll recommend 1st one, we should not take any risk in Crypto world.