Updated to add more comments