Gets the index at which the `key` is found in `array` of key-value pairs.

@private
@param {Array} array The array to inspect.
@param {*} key The key to search for.
@returns {number} Returns the index of the matched value, else `-1`.
162960
function assocIndexOf$1(array, key) {
  var length = array.length;
  while (length--) {
    if (eq(array[length][0], key)) {
      return length;
    }
  }
  return -1;
}
1293483
function findIndex (array, predicate) {
  for (let i = 0; i < array.length; i++) {
    if (predicate(array[i])) return i
  }
  return -1
}
246320
function (key) {                                                      // 186
    var self = this;                                                             // 187
    var ret = null;                                                              // 188
    self.forEach(function (v, k, i) {                                            // 189
      if (self._k(k) === self._k(key)) {                                         // 190
        ret = i;                                                                 // 191
        return OrderedDict.BREAK;                                                // 192
      }                                                                          // 193
      return undefined;                                                          // 194
    });                                                                          // 195
    return ret;                                                                  // 196
  }
1101846
public int getIndex(Object key) {
    int[] nums = (int[]) cset.get(key);
    if (nums == null) {
      return -1;
    }
    else {
      return nums[1];
    }
  }
997143
function (key) {
            var keys = Array.isArray(key) ? key : arguments;

            var input = self.input.all();
            var results = {};

            for (var i = 0; i < keys.length; i++) {
                results[keys[i]] = input[keys[i]];
            }

            return results;
        }
927925
function(key) {
          var self = this;
          var cache = self._indexCache;
          // evaluate whether our key is cached and, if so, whether it is up to date
          if( !cache.hasOwnProperty(key) || self.$keyAt(cache[key]) !== key ) {
            // update the hashmap
            var pos = self.$list.findIndex(function(rec) { return self.$$getKey(rec) === key; });
            if( pos !== -1 ) {
              cache[key] = pos;
            }
          }
          return cache.hasOwnProperty(key)? cache[key] : -1;
        }
689481
public int getIndex(Object key) {
    Integer i = (Integer) nset.get(key);
    if (i == null) {
      return -1;
    }
    else {
      return i.intValue();
    }
  }
660551
private function narrowArray(array $array, string $key = null)
    {
        if ($key) {
            $key .= '--';
        }

        $result = [];

        foreach ($array as $index => $value) {
            if (is_array($value)) {
                $result = array_merge($result, $this->narrowArray($value, $key . $index));
            } else {
                $result[$key . $index] = $value;
            }
        }

        return $result;
    }
814645
function assocIndexOf(array, key) {
  var length = array.length
  while (length--) {
    if (eq(array[length][0], key)) {
      return length
    }
  }
  return -1
}
251335
function arrayIndexOf (array, val) {

        // Use native indexOf
        if (Array.prototype.indexOf) {
            return array.indexOf(val);
        }

        // Use loop/if for environments without native indexOf
        var i, len = array.length;
        for (i = 0; i < len; len += 1) {
            if (array[i] === val) {
                return i;
            }
        }
        return -1;

    }
365244
function arrayEach$1(array, iteratee) {
  var index = -1,
      length = array == null ? 0 : array.length;

  while (++index < length) {
    if (iteratee(array[index], index, array) === false) {
      break;
    }
  }
  return array;
}
700166
function findWhereKey(arr, key) {

  return arr.find(elem => {

    for (const [k] of getIterableObjectEntries(elem)) {

      if (k === key) {
        return true;
      }
    }
  });
}
557273
static public Object getByEquality(Object[] array, Object key)
    {
        if (array != null)
        {
            int length = array.length;

            for (int i = 0; i < length; i += 2)
            {
                Object targetKey = array[i];
                if (targetKey == null)
                {
                    return null;
                }
                else if (targetKey.equals(key))
                {
                    return array[i + 1];
                }
            }
        }

        return null;
    }
72535
private static function findInArray(array $array, string $key, $default = null)
    {
        if (($pos = strrpos($key, '.')) !== false) {
            $array = self::findInArray($array, substr($key, 0, $pos), $default);
            $key = substr($key, $pos + 1);
        }

        return is_array($array) && array_key_exists($key, $array) ? $array[$key] : $default;
    }
912321
public int get(final int key)
    {
        final int[] entries = this.entries;
        final int initialValue = this.initialValue;
        @DoNotSub final int mask = entries.length - 1;
        @DoNotSub int index = Hashing.evenHash(key, mask);

        int value = initialValue;
        while (entries[index + 1] != initialValue)
        {
            if (entries[index] == key)
            {
                value = entries[index + 1];
                break;
            }

            index = next(index, mask);
        }

        return value;
    }
63264
private boolean representsArray(String key) {

        int openingBracket = key.indexOf("[");
        int closingBracket = key.indexOf("]");

        return closingBracket == key.length() - 1 && openingBracket != -1;

    }
939401
function(array) {
            var ln = array.length,
                newAry = [];
            for (var i = 0; i < ln; i++) {
                if (jsonQ.index(newAry, array[i]) == -1) {
                    newAry.push(array[i]);
                }
            }
            return newAry;
        }