code: function isPrefix(candidate) {
      return function(xs) {
        if (candidate.length > xs.length) return false;
        for (var idx = 0; idx < candidate.length; idx += 1) {
          if (candidate[idx] !== xs[idx]) return false;
        }
        return true;
      };
    }
docs: isPrefix :: Array a -> Array a -> Boolean