From 9a2b208985ac7d4644c718ada74770b98eeb4598 Mon Sep 17 00:00:00 2001 From: Charles Date: Mon, 29 Jul 2019 16:56:27 +0200 Subject: part 2 done (except putchar and putstr unicode) --- ft_striteri.c | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 ft_striteri.c (limited to 'ft_striteri.c') diff --git a/ft_striteri.c b/ft_striteri.c new file mode 100644 index 0000000..305138f --- /dev/null +++ b/ft_striteri.c @@ -0,0 +1,11 @@ +void ft_striteri(char *s, void (*f)(unsigned int, char *)) +{ + unsigned int i; + + i = 0; + while (s[i]) + { + (*f)(i, &s[i]); + i++; + } +} -- cgit