-
Notifications
You must be signed in to change notification settings - Fork 0
/
ft_strcpy.c
executable file
·26 lines (23 loc) · 1.04 KB
/
ft_strcpy.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
26
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ft_strcpy.c :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: ioleksiu <marvin@42.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2016/12/01 19:16:01 by ioleksiu #+# #+# */
/* Updated: 2016/12/01 21:05:51 by ioleksiu ### ########.fr */
/* */
/* ************************************************************************** */
#include <string.h>
char *ft_strcpy(char *dst, const char *src)
{
char *d;
char *s;
d = dst;
s = (char*)src;
while (*s)
*d++ = *s++;
*d++ = '\0';
return (dst);
}