1
0
Fork 0
mirror of https://codeberg.org/DansLeRuSH/c-plus-plus-exercises.git synced 2024-11-23 03:48:07 +00:00

Enter and display a string of characters

This commit is contained in:
Franck ALBARET 2018-10-22 07:23:30 +00:00
parent 5f2779d0aa
commit 27b881a5bb

22
EX07_afficher_texte.cpp Normal file
View file

@ -0,0 +1,22 @@
// Auteur : Franck ALBARET
#include <stdio.h>
#include <conio.h>
int main (void)
{
char Texte [80];
int i=0;
clrscr();
puts ("Veuillez taper votre texte :\n\n");
gets(Texte);
while (Texte [i]!='\o')
{
if (Texte [i]!=' ')
{
printf ("%c",Texte [i]);
}
i=i+1;
}
getch();
return 0;
}