submitted problem 3-6 with greedy algorithm
rearranging directory structure