/* ************************************************************************** */ /* */ /* ::: :::::::: */ /* ft_any.c :+: :+: :+: */ /* +:+ +:+ +:+ */ /* By: jhalford +#+ +:+ +#+ */ /* +#+#+#+#+#+ +#+ */ /* Created: 2016/08/12 13:24:57 by jhalford #+# #+# */ /* Updated: 2016/08/13 16:22:45 by jhalford ### ########.fr */ /* */ /* ************************************************************************** */ int ft_any(char **tab, int (*f)(char*)) { int i; i = 0; while (tab[i]) { if (f(tab[i]) == 1) return (1); i++; } return (0); }