Bonjour
j'ai commencé à faire un programme qui compte le nombre de caractère dans une phrase car on vient d'apprendre comment manipuler la bibliothèque "string.h"
j'aimerai maintenant qui compte les mots mais je n'arrive pas à voir comment, une boucle for sans doute mais je suis un peu bloqué, pouvez vous m'aider svpCode:
1
2
3
4
5
6
7
8
9
10
11
12 #include<stdio.h> #include<stdlib.h> #include<string.h> int main() { char phrase1[100]="jaime bien ma phrase"; printf("%d",strlen(phrase1)); return EXIT_SUCCESS; }
merci