fork download
  1. function GlobalObject()
  2. {
  3. this.test1 = function() { return this; }();
  4. this.test2 = function() { return (function(){return this;}); }();
  5. }
  6.  
  7. var go = new GlobalObject();
  8.  
  9. print(go.test1());
  10. print(go.test2());
  11.  
Runtime error #stdin #stdout 0.02s 4980KB
stdin
Standard input is empty
stdout
Standard output is empty