Updated timekeeping
Added file operations and did minor fixes.