13#include "../includes/libft.h"
23char *
ft_substr(
char const *s,
unsigned int start,
size_t len)
33 if (len > s_len - start)
35 sub = (
char *)malloc(
sizeof(
char) * (len + 1));
char * ft_substr(char const *s, unsigned int start, size_t len)
Extracts a substring from a string.
char * ft_strdup(const char *s1)
Duplicates a C string into newly allocated memory.
size_t ft_strlen(const char *str)
Returns the length of a null-terminated string.
size_t ft_strlcpy(char *dest, const char *src, size_t size)
Copies a string into a bounded destination buffer.