Refactor code and add comments.