tax and total method working