arr = ["color1","r1","g1","b1","a1","color2","r2","g2","b2","a2"]
        >>> brkl2d(arr,5)
        [{'color1': ['r1', 'g1', 'b1', 'a1']}, {'color2': ['r2', 'g2', 'b2', 'a2']}]
430141
def brkl2d(arr,interval):
    '''
        
    '''
    lngth = arr.__len__()
    brkseqs = elel.init_range(0,lngth,interval)
    l = elel.broken_seqs(arr,brkseqs)
    d = elel.mapv(l,lambda ele:{ele[0]:ele[1:]})
    return(d)
1044632
function(indexes) {
      var isArray, k, v;
      isArray = Array.isArray(indexes);
      if (!isArray) {
        indexes = [indexes];
      }
      indexes = (function() {
        var results;
        results = [];
        for (k in indexes) {
          v = indexes[k];
          results.push(`${k} ${v}`);
        }
        return results;
      })();
      if (isArray) {
        return indexes;
      } else {
        return indexes[0];
      }
    }
1100143
def _keys2sls(self, keys, key2sl):
        """"""
        sls = list()
        if isinstance(keys, tuple):
            for key in keys:
                sls.append(key2sl(key))
        else:
            sls.append(key2sl(keys))
        if len(sls) > self.ndim:
            fstr = "expected <= {0.ndim} slice dimensions, got {1}"
            raise ValueError(fstr.format(self, len(sls)))
        return sls
1128203
function (arr, val) {

            debug('Finding all indices...');
            debug('Array: %o', arr);

            let indexes = [];

            for (let i = 0; i < arr.length; i++) {

                const
                    camelCaseVal = camelCase(val),
                    camelCaseKey = camelCase(arr[i]);

                if (arr[i] === val || camelCaseKey === camelCaseVal) {

                    debug('Matched index: %s', i);

                    indexes.push(i);
                }
            }

            debug('Found indices: %o', indexes);

            return indexes;
        }
191336
function keysIndex(a) {
    var keys = [],
        l,
        k,
        i;

    for (i = 0, l = a.length; i < l; i++)
      for (k in a[i])
        if (!~keys.indexOf(k))
          keys.push(k);

    return keys;
  }
334867
function arrayIndexOf(arr, search, fromIndex, fromRight) {
  var length = arr.length, defaultFromIndex, index, increment;

  increment = fromRight ? -1 : 1;
  defaultFromIndex = fromRight ? length - 1 : 0;
  fromIndex = trunc(fromIndex);
  if (!fromIndex && fromIndex !== 0) {
    fromIndex = defaultFromIndex;
  }
  if (fromIndex < 0) {
    fromIndex = length + fromIndex;
  }
  if ((!fromRight && fromIndex < 0) || (fromRight && fromIndex >= length)) {
    fromIndex = defaultFromIndex;
  }

  index = fromIndex;

  while((fromRight && index >= 0) || (!fromRight && index < length)) {
    if (!(index in arr)) {
      return sparseIndexOf(arr, search, fromIndex, fromRight);
    }
    if (isArrayIndex(index) && arr[index] === search) {
      return index;
    }
    index += increment;
  }
  return -1;
}
61327
function keyInArray(keys) {
  var keySet = Immutable.Set(keys);
  return function (v, k) {

    return keySet.has(k);
  }
}
543368
function keyBy(arr, fn){
        var result = {};
        arr.forEach(function(v){
            result[fn(v)] = v;
        });
        return result;
    }
539894
function() {
      var fontArray = ["Abadi MT Condensed Light", "Adobe Fangsong Std", "Adobe Hebrew", "Adobe Ming Std", "Agency FB", "Aharoni", "Andalus", "Angsana New", "AngsanaUPC", "Aparajita", "Arab", "Arabic Transparent", "Arabic Typesetting", "Arial Baltic", "Arial Black", "Arial CE", "Arial CYR", "Arial Greek", "Arial TUR", "Arial", "Batang", "BatangChe", "Bauhaus 93", "Bell MT", "Bitstream Vera Serif", "Bodoni MT", "Bookman Old Style", "Braggadocio", "Broadway", "Browallia New", "BrowalliaUPC", "Calibri Light", "Calibri", "Californian FB", "Cambria Math", "Cambria", "Candara", "Castellar", "Casual", "Centaur", "Century Gothic", "Chalkduster", "Colonna MT", "Comic Sans MS", "Consolas", "Constantia", "Copperplate Gothic Light", "Corbel", "Cordia New", "CordiaUPC", "Courier New Baltic", "Courier New CE", "Courier New CYR", "Courier New Greek", "Courier New TUR", "Courier New", "DFKai-SB", "DaunPenh", "David", "DejaVu LGC Sans Mono", "Desdemona", "DilleniaUPC", "DokChampa", "Dotum", "DotumChe", "Ebrima", "Engravers MT", "Eras Bold ITC", "Estrangelo Edessa", "EucrosiaUPC", "Euphemia", "Eurostile", "FangSong", "Forte", "FrankRuehl", "Franklin Gothic Heavy", "Franklin Gothic Medium", "FreesiaUPC", "French Script MT", "Gabriola", "Gautami", "Georgia", "Gigi", "Gisha", "Goudy Old Style", "Gulim", "GulimChe", "GungSeo", "Gungsuh", "GungsuhChe", "Haettenschweiler", "Harrington", "Hei S", "HeiT", "Heisei Kaku Gothic", "Hiragino Sans GB", "Impact", "Informal Roman", "IrisUPC", "Iskoola Pota", "JasmineUPC", "KacstOne", "KaiTi", "Kalinga", "Kartika", "Khmer UI", "Kino MT", "KodchiangUPC", "Kokila", "Kozuka Gothic Pr6N", "Lao UI", "Latha", "Leelawadee", "Levenim MT", "LilyUPC", "Lohit Gujarati", "Loma", "Lucida Bright", "Lucida Console", "Lucida Fax", "Lucida Sans Unicode", "MS Gothic", "MS Mincho", "MS PGothic", "MS PMincho", "MS Reference Sans Serif", "MS UI Gothic", "MV Boli", "Magneto", "Malgun Gothic", "Mangal", "Marlett", "Matura MT Script Capitals", "Meiryo UI", "Meiryo", "Menlo", "Microsoft Himalaya", "Microsoft JhengHei", "Microsoft New Tai Lue", "Microsoft PhagsPa", "Microsoft Sans Serif", "Microsoft Tai Le", "Microsoft Uighur", "Microsoft YaHei", "Microsoft Yi Baiti", "MingLiU", "MingLiU-ExtB", "MingLiU_HKSCS", "MingLiU_HKSCS-ExtB", "Miriam Fixed", "Miriam", "Mongolian Baiti", "MoolBoran", "NSimSun", "Narkisim", "News Gothic MT", "Niagara Solid", "Nyala", "PMingLiU", "PMingLiU-ExtB", "Palace Script MT", "Palatino Linotype", "Papyrus", "Perpetua", "Plantagenet Cherokee", "Playbill", "Prelude Bold", "Prelude Condensed Bold", "Prelude Condensed Medium", "Prelude Medium", "PreludeCompressedWGL Black", "PreludeCompressedWGL Bold", "PreludeCompressedWGL Light", "PreludeCompressedWGL Medium", "PreludeCondensedWGL Black", "PreludeCondensedWGL Bold", "PreludeCondensedWGL Light", "PreludeCondensedWGL Medium", "PreludeWGL Black", "PreludeWGL Bold", "PreludeWGL Light", "PreludeWGL Medium", "Raavi", "Rachana", "Rockwell", "Rod", "Sakkal Majalla", "Sawasdee", "Script MT Bold", "Segoe Print", "Segoe Script", "Segoe UI Light", "Segoe UI Semibold", "Segoe UI Symbol", "Segoe UI", "Shonar Bangla", "Showcard Gothic", "Shruti", "SimHei", "SimSun", "SimSun-ExtB", "Simplified Arabic Fixed", "Simplified Arabic", "Snap ITC", "Sylfaen", "Symbol", "Tahoma", "Times New Roman Baltic", "Times New Roman CE", "Times New Roman CYR", "Times New Roman Greek", "Times New Roman TUR", "Times New Roman", "TlwgMono", "Traditional Arabic", "Trebuchet MS", "Tunga", "Tw Cen MT Condensed Extra Bold", "Ubuntu", "Umpush", "Univers", "Utopia", "Utsaah", "Vani", "Verdana", "Vijaya", "Vladimir Script", "Vrinda", "Webdings", "Wide Latin", "Wingdings"];
      var fontString = "";

      for (var i = 0; i < fontArray.length; i++) {
        if (fontDetective.detect(fontArray[i])) {
          if (i == fontArray.length - 1) {
            fontString += fontArray[i];
          } else {
            fontString += fontArray[i] + ", ";
          }
        }
      }

      return fontString;
    }
153550
def p_let_arr_substr_in_args4(p):
    
    i = 2 if p[1].upper() == 'LET' else 1

    id_ = p[i]
    arg_list = p[i + 2]
    substr = (arg_list.children.pop().value, p[i + 4])
    expr_ = p[i + 7]
    p[0] = make_array_substr_assign(p.lineno(i), id_, arg_list, substr, expr_)
758395
function(color1, color2) {
		var result = color1.slice();
		for (var i=0;i<3;i++) {
			for (var j=1;j<arguments.length;j++) {
				result[i] += arguments[j][i];
			}
		}
		return result;
	}
1020005
function(indexes) {
      var isArray;
      isArray = Array.isArray(indexes);
      if (!isArray) {
        indexes = [indexes];
      }
      indexes.forEach(function(index, i) {
        var k, v;
        if (i === 0) {
          indexes = {};
        }
        [k, v] = index.split(' ');
        return indexes[k] = v;
      });
      if (isArray) {
        return indexes;
      } else {
        return indexes[0];
      }
    }
576964
function createSerialCombinations(arr, fn) {
  var combinations = [''];
  var newCombinations;
  arr.forEach(function (elements) {
    newCombinations = [];
    elements.forEach(function (element) {
      combinations.forEach(function (combination) {
        newCombinations.push(fn(combination, element));
      });
    });
    combinations = newCombinations;
  });
  return combinations;
}
621613
def nice_indices(arr):
    '''
    
    '''
    # surprisingly, this is slower for very small (and very large) inputs:
    # u,f,i = np.unique(arr,return_index=True,return_inverse=True)
    # arr[:] = np.arange(u.shape[0])[np.argsort(f)][i]
    ids = collections.defaultdict(count().__next__)
    for idx,x in enumerate(arr):
        arr[idx] = ids[x]
    return arr
1129666
function eachOfArrayLike(coll, iteratee, callback) {
    callback = once(callback);
    var index = 0,
        completed = 0,
        {length} = coll,
        canceled = false;
    if (length === 0) {
        callback(null);
    }

    function iteratorCallback(err, value) {
        if (err === false) {
            canceled = true
        }
        if (canceled === true) return
        if (err) {
            callback(err);
        } else if ((++completed === length) || value === breakLoop) {
            callback(null);
        }
    }

    for (; index < length; index++) {
        iteratee(coll[index], index, onlyOnce(iteratorCallback));
    }
}
1274412
function mapObjects(arr, idKey) {
  var r = {};
  var len = arr.length;

  for (var i = 0; i < len; i++) {
    var item = arr[i];
    var id = isFunction(idKey) ? idKey(item, i) : item[idKey];
    r[id] = item;
  }

  return r;
}
1055034
def returnArrayFilters(arr1, arr2, limitsArr1, limitsArr2):
    
    posL = bisect.bisect_left(arr1, limitsArr1[0])
    posR = bisect.bisect_right(arr1, limitsArr1[1])
    matchMask = ((arr2[posL:posR] <= limitsArr2[1]) &
                 (arr2[posL:posR] >= limitsArr2[0])
                 )
    return posL, posR, matchMask