Answer:
a. Ending inventory = $162, Cost of Sales = $593, Gross Profit = $478
b. Ending inventory = $227, Cost of Sales = $528, Gross Profit = $543
c. Ending inventory = $492.30, Cost of Sales = $557.94 , Gross Profit = $513.06
d. FIFO
Explanation:
FIFO
Ending inventory = 18 units × $9   = $162
                                 Total               = $162
Cost of Sales = 11 units × $13 = $143
                          16 units × $12= $192
                          21 units × $11 = $231
                            3 units × $9 = $27
                          Total              = $593
Gross Profit = Sales less Cost of Sales
                    = (51 units × $21) - $593
                    = $1,071 - $593
                    = $478
LIFO
Ending inventory = 11 units × $13    = $143
                                  7 units × $12   =  $84
                                  Total               = $227
Cost of Sales = 9 units × $12 = $108
                          21 units × $11 = $231
                          21 units × $9 = $189
                          Total              = $528
Gross Profit = Sales less Cost of Sales
                    = (51 units × $21) - $528
                    = $1,071 - $528
                    = $543
Weighted-average cost
First determine the average cost.
Average cost = Total Cost / Total units
                       = $ 755 / 69
                       = $10.94
Ending inventory = Units Remaining × Average Price
                              = 45 units × $10.94
                              = $492.30
Cost of Sales = Units Sold × Average Cost
                       = 51 units × $10.94
                       = $557.94 
Gross Profit = Sales less Cost of Sales
                    = (51 units × $21) - $557.94
                    = $1,071.00 - $557.94
                    = $513.06