int isxdigit(int ch) : isxdigit « ctype.h « C / ANSI-C






int isxdigit(int ch)



//Declaration:  int isxdigit(int ch); 
//Return:       returns nonzero if ch is a hexadecimal digit; 
                otherwise zero is returned. 

  #include <ctype.h>
  #include <stdio.h>

  int main(void)
  {
    char ch;

    for(;;) {
      ch = getchar();
      if(ch == '.'){
          break;
      }
      if(isxdigit(ch))(){
          printf("%c is hexadecimal digit\n", ch);
      }
    }

    return 0;
  }

           
       








Related examples in the same category