Edited the solution part