File management and stuff for the sixth challenge