-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathft_strequ.c
25 lines (24 loc) · 1.06 KB
/
ft_strequ.c
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ft_strequ.c :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: alaulom <[email protected]> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2014/11/12 11:50:49 by alaulom #+# #+# */
/* Updated: 2014/11/12 11:58:55 by alaulom ### ########.fr */
/* */
/* ************************************************************************** */
int ft_strequ(const char *s1, const char *s2)
{
if (s1 && s2)
{
while (*s1 && *s2)
if (*s1++ != *s2++)
return (0);
if (*s1 != *s2)
return (0);
return (1);
}
return (0);
}