29 lines
1.1 KiB
C
29 lines
1.1 KiB
C
/* ************************************************************************** */
|
|
/* */
|
|
/* ::: :::::::: */
|
|
/* ft_strcpy.c :+: :+: :+: */
|
|
/* +:+ +:+ +:+ */
|
|
/* By: erey-bet <marvin@42.fr> +#+ +:+ +#+ */
|
|
/* +#+#+#+#+#+ +#+ */
|
|
/* Created: 2022/07/17 19:03:49 by erey-bet #+# #+# */
|
|
/* Updated: 2023/03/26 23:56:14 by erey-bet ### ########.fr */
|
|
/* */
|
|
/* ************************************************************************** */
|
|
|
|
#include "utils.h"
|
|
|
|
void ft_strcpy(char *dest, const char *src)
|
|
{
|
|
int i;
|
|
|
|
if (!dest || !src)
|
|
return ;
|
|
i = 0;
|
|
while (src[i] != '\0')
|
|
{
|
|
dest[i] = src[i];
|
|
i++;
|
|
}
|
|
dest[i] = '\0';
|
|
}
|