Some functions from ES5 ported on ES3. Just for fun