blob: a806312d4c1a3cdf5834301c0d2a6c7e827e5d14 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ft_strchr.c :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: kdx <kdx @student.42angouleme.fr +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2022/09/27 23:37:56 by kdx #+# #+# */
/* Updated: 2022/09/27 23:41:04 by kdx ### ########.fr */
/* */
/* ************************************************************************** */
#include "libft.h"
char *ft_strchr(const char *s, int c)
{
while (*s != c)
{
if (*s == '\0')
return (NULL);
s++;
}
return ((char *)s);
}
|