libft
|
#include "libft.h"
Go to the source code of this file.
Functions | |
char * | ft_strmap (char const *s, char(*f)(char)) |
Maps a function to characters of a string. More... | |
char* ft_strmap | ( | char const * | s, |
char(*)(char) | f | ||
) |
Maps a function to characters of a string.
Applies the function f
to each character of the string given as argument to create a “fresh” new string (with malloc
) resulting from the successive applications of f
.
s | The string to map. |
f | The function to apply to each character of s . |
f
, or NULL
if allocation fails. Definition at line 27 of file ft_strmap.c.