first stab at 1st problem