Vérifier si un caractère est imprimable (equivalent à isalnum()&&ispunct())

Author:


Download


  #include 
  #include 

  int main(void)
  {
    char ch;

	printf("Tapez un caractère, 'q' pour quittern");
    for(;;) {
      ch = getchar();
      if(isgraph(ch)){
         printf("%c est un caractère imprimablen", ch);
      }
      if(ch == 'q'){
         break;
      }
    }
    return 0;
  }

Leave a Reply

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