export function find<K, V>(x: Map<K, V>, ft: TestFunction<K, V>): V {
  for (var [k, v] of x)
    if (ft(v, k, x)) return v;
}