text: const format = function (bytes) {
      return (bytes / 1024 / 1024).toFixed(2) + ' MB';
  };
  
  const print = function() {
      const memoryUsage = process.memoryUsage();
      console.log(`heapTotal: ${format(memoryUsage.heapTotal)}, heapUsed: ${format(memoryUsage.heapUsed)}`);
  }
  
  /* var theThing = null
  var replaceThing = function () {
    var originalThing = theThing
    var unused = function () {
      if (originalThing)
        console.log("hi")
    }
    print()
    theThing = {
      longStr: new Array(1000000).join('*'),
      someMethod: function () {
        console.log(someMessage)
      }
    };
  };
  
  setInterval(replaceThing, 1000) */
  
  var theThing = null
  var replaceThing = function () {
    var originalThing = theThing
    var unused = function (originalThing) {
      if (originalThing)
        console.log("hi")
    }
    print()
    theThing = {
      longStr: new Array(1000000).join('*'),
      someMethod: function () {
        console.log(someMessage)
      }
    };
  };
  
  setInterval(replaceThing, 1000)
  