Return the union of arrays in new array
552459
function() {
            var arg = arguments,
                target = [],
                ln = arg.length;

            for (var i = 0; i < ln; i++) {
                var aryLn = arg[i].length;
                for (var j = 0; j < aryLn; j++) {
                    var itm = arg[i][j];
                    if (jsonQ.index(target, itm) == -1) {
                        target.push(itm);
                    }
                }

            }
            return target;
        }
985174
function arrayMergeUnique(a, b) {
  return a.concat(b).filter(function(v,i,c) {
    if(i === c.indexOf(v)) return true
    return false
  })
}
1320015
def array_subscripts(expr):
    """"""
    if isinstance(expr, Array):
        return all_subs(expr._bounds)
    elif isinstance(expr, list):
        subs = [subscripts(x) for x in expr]
        return flatten(subs)
    else:
        return [expr]
1370400
def union(self, *args):
        """"""
        if self._readonly:
            raise AttributeError

        if len(args) == 0:
            return None
        if len(args) == 1:
            return self[args[0]]
        for a, b in zip(args[:-1], args[1:]):
            result = self._union_pair(a, b)
        return result
873710
function mergeDeepArrays(array1, array2) {
  const length = Math.max(array1.length, array2.length);

  let index = -1,
      mergedArray = [];

  while (++index < length) {
    if (index < array2.length) {
      mergedArray[index] = getDeeplyMergedValues(array1[index], array2[index]);

      continue;
    }

    mergedArray[index] = array1[index];
  }

  return mergedArray;
}
1346542
def from_array(cls, arr):
        """"""
        return cls().with_columns([(f, arr[f]) for f in arr.dtype.names])
295607
static function arrayMerge($array1, $array2, $overwriteValue = true)
    {
//        if($overwriteValue) {
//            foreach ($array2 as $key => $Value) {
//                if (array_key_exists($key, $array1) && is_array($Value)) {
//                    $array1[$key] = self::arrayMergeRecursively(
//                        $array1[$key], $array2[$key], $overwriteValue
//                    );
//                } else {
//                    $array1[$key] = $Value;
//                }
//            }
//        } else {
//            $array1 = array_merge_recursive($array1, $array2);
//        }

        $arrayMerged = array_merge_recursive($array1, $array2);
        $arrayUnique = array_unique($arrayMerged, SORT_STRING);

        return $arrayUnique;
    }
514692
def union(cls, *sets):
        
        import utool as ut
        lists_ = ut.flatten([list(s) for s in sets])
        return cls(lists_)
20179
def union(a: Iterable[Any], b: Iterable[Any]) -> List[Any]:
    
    u = []  # type: List[Any]
    for item in a:
        if item not in u:
            u.append(item)
    for item in b:
        if item not in u:
            u.append(item)
    return u
1266431
def union(*args):
    
    if not args:
        return []

    base = args[0]
    for other in args[1:]:
        base.extend(other)

    return list(OrderedDict.fromkeys(base))
857139
def union(self, *iterables):
        
        return self.__class__(chain(iter(self), *iterables), key=self._key)
417724
static function arrayMergeRecursive()
    {
        $params = func_get_args();
        $return = array_shift($params);
        foreach ($params as $array){
            foreach ($array as $key => $value){
                if (isset($return[$key]) && is_array($value) && is_array($return[$key])){
                    $return[$key] = self::arrayMergeRecursive($return[$key], $value);
                }else{
                    $return[$key] = $value;
                }
            }
        }
        return $return;
    }
142851
function interleave(...arrays) {
  var more = true;
  var n = 0;
  var result = [];
  while (more) {
    more = false;
    for (var array of arrays) {
      if (n >= array.length) continue;
      result.push(array[n]);
      more = true;
    }
    n++;
  }
  return result;
}
35024
def union(*argv):
        
        res = OrderedSet()
        for ods in argv:
            res = res | ods
        return res
800295
function(array, n) {
      var ret = [];
      var sz = _.size(array);

      if (n <= 0) return [];
      if (n === 1) return array;

      for(var index = 0; index < sz; index += n) {
        ret.push(array[index]);
      }

      return ret;
    }
1364926
protected function mergeArrays()
    {
        $arrays = func_get_args();
        $merged = array();

        foreach ($arrays as $array) {
            foreach ($array as $key => $value) {
                $merged = $this->setValue($key, $value, $merged);
            }
        }

        return $merged;
    }
1114247
static function arrayMerge() {
        $output = [];
        
        foreach(func_get_args() as $array) {
            foreach($array as $key => $value) {
                $output[$key] = isset($output[$key]) ?
                    array_merge($output[$key], $value) : $value;
            }
        }
        
        return $output;
    }