Solve p169
Clean up and update some files