ft_nm/subprojects/libft/ft_strequ.c

29 lines
1.1 KiB
C
Raw Normal View History

2019-05-10 18:29:21 +03:00
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ft_strequ.c :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: gtertysh <marvin@42.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2016/12/01 18:51:03 by gtertysh #+# #+# */
/* Updated: 2016/12/01 19:00:02 by gtertysh ### ########.fr */
/* */
/* ************************************************************************** */
#include "libft.h"
int ft_strequ(char const *s1, char const *s2)
{
if (s1 && s2)
{
while (*s1 && *s2 && *s1 == *s2)
{
s1++;
s2++;
}
if (*s1 != *s2)
return (0);
}
return (1);
}