Adding append and prepend functions