code: function merge(obj1, obj2)
  {
      var obj3 = {}, index;
      for (index in obj1) {
          obj3[index] = obj1[index];
      }
      for (index in obj2) {
          obj3[index] = obj2[index];
      }
      return obj3;
  }
docs: merge two objects with priority on second