Added body of the functions and added comments + validation outputºº»