Reformated code, added license, and copyright notice in every file