/* ************************************************************************** */ /* */ /* ::: :::::::: */ /* ft_strcmp.c :+: :+: :+: */ /* +:+ +:+ +:+ */ /* By: scebula +#+ +:+ +#+ */ /* +#+#+#+#+#+ +#+ */ /* Created: 2015/11/26 09:30:45 by scebula #+# #+# */ /* Updated: 2015/11/27 19:43:01 by scebula ### ########.fr */ /* */ /* ************************************************************************** */ #include "libft.h" int ft_strcmp(const char *s1, const char *s2) { while (*s1 && *s1 == *s2) { s1++; s2++; } return ((unsigned char)*s1 - (unsigned char)*s2); }