aboutsummaryrefslogtreecommitdiff
path: root/exam_final/subjects/8-0-ft_split
diff options
context:
space:
mode:
authorCharles <sircharlesaze@gmail.com>2019-07-26 23:17:36 +0200
committerCharles <sircharlesaze@gmail.com>2019-07-26 23:17:36 +0200
commit8ec5431354bdb582455e8c32758098c5a0fdada2 (patch)
tree480c68814f822439850029df0e0249a2cafb8177 /exam_final/subjects/8-0-ft_split
parent475449dd4b1f3308bac6f72c34d87812216a0738 (diff)
downloadpiscine-8ec5431354bdb582455e8c32758098c5a0fdada2.tar.gz
piscine-8ec5431354bdb582455e8c32758098c5a0fdada2.tar.bz2
piscine-8ec5431354bdb582455e8c32758098c5a0fdada2.zip
exam final
Diffstat (limited to 'exam_final/subjects/8-0-ft_split')
-rw-r--r--exam_final/subjects/8-0-ft_split/subject.en.txt14
-rw-r--r--exam_final/subjects/8-0-ft_split/subject.fr.txt16
2 files changed, 30 insertions, 0 deletions
diff --git a/exam_final/subjects/8-0-ft_split/subject.en.txt b/exam_final/subjects/8-0-ft_split/subject.en.txt
new file mode 100644
index 0000000..97375e9
--- /dev/null
+++ b/exam_final/subjects/8-0-ft_split/subject.en.txt
@@ -0,0 +1,14 @@
+Assignment name : ft_split
+Expected files : ft_split.c
+Allowed functions: malloc
+--------------------------------------------------------------------------------
+
+Write a function that takes a string, splits it into words, and returns them as
+a NULL-terminated array of strings.
+
+A "word" is defined as a part of a string delimited either by spaces/tabs/new
+lines, or by the start/end of the string.
+
+Your function must be declared as follows:
+
+char **ft_split(char *str);
diff --git a/exam_final/subjects/8-0-ft_split/subject.fr.txt b/exam_final/subjects/8-0-ft_split/subject.fr.txt
new file mode 100644
index 0000000..acd1b41
--- /dev/null
+++ b/exam_final/subjects/8-0-ft_split/subject.fr.txt
@@ -0,0 +1,16 @@
+Assignment name : ft_split
+Expected files : ft_split.c
+Allowed functions: malloc
+--------------------------------------------------------------------------------
+
+Écrire une fonction qui prend en paramètre une chaîne de caractères et la
+découpe en mots, qui seront retournés sous la forme d'un tableau de chaînes
+terminé par NULL.
+
+On appelle "mot" une portion de chaîne de caractères délimitée soit par des
+espaces, des retours à la ligne et/ou des tabulations, soit par le début / fin
+de la chaîne.
+
+Votre fonction devra être prototypée de la façon suivante :
+
+char **ft_split(char *str);