Cullumber Company sold goods with a total selling price of $801,000 during the year. It purchased goods for $381,000 and had beginning inventory of $65,000. A count of its ending inventory determined that goods on hand was $51,000. What was its cost of goods sold?