ft_nm/subprojects/libft/ft_strlen.c

25 lines
1 KiB
C
Raw Permalink Normal View History

2019-05-10 18:29:21 +03:00
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ft_strlen.c :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: gtertysh <marvin@42.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2016/11/30 12:37:23 by gtertysh #+# #+# */
/* Updated: 2016/11/30 12:48:50 by gtertysh ### ########.fr */
/* */
/* ************************************************************************** */
#include "libft.h"
size_t ft_strlen(const char *s)
{
size_t len;
len = 0;
if (s)
while (*(unsigned char *)s++)
len++;
return (len);
}