Code of the required functions was implemented