Describe how costs flow from inventory to cost of goods sold for the following methods: (a) FIFO and (b) LIFO.