remove inputs

This commit is contained in:
2024-12-02 12:32:14 +01:00
commit 60acac0231
247 changed files with 9071 additions and 0 deletions

28
libft/ft_memchr.c Executable file
View File

@ -0,0 +1,28 @@
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ft_memchr.c :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: tomoron <marvin@42.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2023/10/30 13:35:44 by tomoron #+# #+# */
/* Updated: 2023/11/02 11:28:37 by tomoron ### ########.fr */
/* */
/* ************************************************************************** */
#include "libft.h"
void *ft_memchr(const void *s, int c, size_t n)
{
unsigned long int i;
unsigned char *p;
i = 0;
p = (unsigned char *) s;
while (i < n)
{
if (p[i] == (unsigned char)c)
return ((char *)p + i);
i++;
}
return (0);
}