Adding rest of code