Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- #include <stdlib.h>
- int main(void)
- {
- FILE *fichier=fopen("/home/franck/Bureau/LangageC/Jeu_Du_Pendu/secret.hide", "r");
- int taille_max =0;
- int caractere=0;
- int i=0;
- do
- {
- i+=1;
- caractere=fgetc(fichier);
- }while(caractere != EOF);
- // i-1 car j'ai le caractère � qui s'ajoute à chaque fois (\0 ??)
- taille_max = i-1;
- printf("Taille : %d\n", taille_max);
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement