Cleaned up files, added flatmap for concat to I/O.