-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathft_strcat.c
26 lines (23 loc) · 1.06 KB
/
ft_strcat.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_strcat.c :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: vbrazas <[email protected]> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2017/11/05 19:35:38 by vbrazas #+# #+# */
/* Updated: 2017/11/12 18:24:12 by vbrazas ### ########.fr */
/* */
/* ************************************************************************** */
#include "libft.h"
char *ft_strcat(char *dest, const char *src)
{
size_t i;
size_t j;
i = ft_strlen(dest);
j = 0;
while (src[j])
dest[i++] = src[j++];
dest[i] = '\0';
return (dest);
}