cleaned up code some
added headers to all files