Kind of completed the code