We calculate the subtotal based on the quantity multiplied by the price. The tax is 6%, so we multiply .06 by the subtotal. To get the total price for the amount of the item/s someone is purchasing, we add the subtotal and the tax together.
To get the final price you take each total for each item, we auto summed the your totals and got the total price for all.