Logical or from functions.

    Parameters
    ----------
    f1, f2 : function
        Function that takes array and returns true or false for each item in array.

    Returns
    -------
    Function.
193226
def logical_or(f1, f2):  # function factory
    '''
    '''
    def f(value):
        return np.logical_or(f1(value), f2(value))
    f.__name__ = "(" + f1.__name__ + "_or_" + f2.__name__ + ")"
    return f
1031603
function(fs) {
        var fR = [];
        for (var key in fs) {
            var fact = fs[key];
            if(!fact.explicit) {
                fR.push(fact);
            }
        }
        return fR;
    }
581346
@Override
    public final <B> Maybe<B> fmap(Function<? super A, ? extends B> fn) {
        return Monad.super.<B>fmap(fn).coerce();
    }
794332
def _(f, x):
    
    result = {}
    for k, v in x.items():
        k_, v_ = f(k, v)
        result[k_] = v_
    return result
1158274
function _curry2 (fn) {
  return function f2 (a, b) {
    if (!arguments.length) {
      return f2
    }

    if (arguments.length === 1) {
      return function (_b) {
        return fn(a, _b)
      }
    }

    return fn(a, b)
  }
}
1034597
function liftA2(fn, x, y) {
  if(!isFunction(fn)) {
    throw new TypeError('liftA2: Function required for first argument')
  }

  if(!((isApply(x) || isArray(x)) && isSameType(x, y))) {
    throw new TypeError('liftA2: Applys of same type required for last two arguments')
  }

  if(isArray(x)) {
    return ap(y, map(fn, x))
  }

  return x.map(fn).ap(y)
}
606948
public static<A, B, Z> Function2<A, B, Z> lift(Func2<A, B, Z> f) {
	return bridge.lift(f);
    }
835568
function(or1, or2) {
			var union1 = set.union(or1.values[0], or2.values[0]);
			var union2 = set.union(or1.values[1], or2.values[1]);

			if (!isAndOrOr(union1) || !isAndOrOr(union2)) {
				return set.union(union1, union2);
			}
			union1 = set.union(or1.values[0], or2.values[1]);
			union2 = set.union(or1.values[1], or2.values[0]);

			if (!isAndOrOr(union1) || !isAndOrOr(union2)) {
				return set.union(union1, union2);
			} else {
				return new is.Or([or1, or2]);
			}
		}
864196
def find(self, func):
        
        self.ftmp = None

        def test(value, index, list):
            if func(value, index, list) is True:
                self.ftmp = value
                return True
        self._clean.any(test)
        return self._wrap(self.ftmp)
101750
function(a,b,beStrict){
           if(this.isArray(a) && this.isArray(b)){
            var alen = a.length, i = 0;
            if(beStrict){
             if(alen !== (b).length){ return false; }
           }

           for(; i < alen; i++){
             if(a[i] === undefined || b[i] === undefined) break;
             if(b[i] !== a[i]){
              return false;
              break;
            }
          }
          return true;
        }
    }
448073
function(fn) {
		return function() {
			var realArgs = [];
			var fnArgs = arguments;
			each(fnArgs, function(val, i) {
				if (i <= fnArgs.length) {
					while (val && val.isComputed) {
						val = val();
					}
					realArgs.push(val);
				}
			});
			return fn.apply(this, realArgs);
		};
	}
892284
public static <I,O> BoolExprPattern<I,O> matches(Function<I,Boolean> expr, Function<I,O> f) {
        return new BoolExprPattern<I, O>(expr, f);
    }
1334919
function (arr, f) {
      for (var i = 0; i < arr.length; i++) {
        var r = f(arr[i], i);
        if (r.isSome()) {
          return r;
        }
      }
      return Option.none();
    }
54781
function(arr, f) {
      var r = [];
      for (var i = 0; i < arr.length; i++) {
        var x = arr[i];
        if (x.isSome()) {
          r.push(x.getOrDie());
        } else {
          return Option.none();
        }
      }
      return Option.some(f.apply(null, r));
    }
338727
function(fun) {
      return function(x, y) {
        if (truthy(fun(x, y)))
          return -1;
        else if (truthy(fun(y, x)))
          return 1;
        else
          return 0;
      };
    }
522207
def logical_xor(f1, f2):  # function factory
    '''
    '''
    def f(value):
        return np.logical_xor(f1(value), f2(value))
    f.__name__ = "(" + f1.__name__ + "_xor_" + f2.__name__ + ")"
    return f
1217329
function (f, direction) {

        if (typeof (f) !== 'function') {
            var prop = f;
            // make unary function
            f = function (v1) {

                return v1[prop];
            };
        }
        if (f.length === 1) {
            // f is a unary function mapping a single item to its sort score
            var uf = f;
            f = function (v1, v2) {

                return uf(v1) < uf(v2) ? -1 : uf(v1) > uf(v2) ? 1 : 0;
            };
        }
        if (direction === -1) {
            return function (v1, v2) {

                return -f(v1, v2);
            };
        }
        return f;
    }