Returning values are set according to the requirements.