DirectFN interview question

Asked about OOP, some javascript functions from the previous paper