Parcourir et afficher un tableau de caractère

Author:


Download


#include 

int main(void)
{
  char str[120]; //120 caractères maxi
  int i;

  printf("Tapez une chaîne de caractère (Inferieur à 120 caractère): ");
  gets(str);

  for(i = 0; str[i]; i++)
      printf("%c", str[i]);//Afficher la chaîne
  return 0;
}

Leave a Reply

Your email address will not be published. Required fields are marked *