An Algorithm for Clearing Combinatorial Markets