IS there a c function...

Discussion in 'OT Technology' started by ranthal, Aug 29, 2008.

  1. ranthal

    ranthal i did what?

    Joined:
    Feb 8, 2007
    Messages:
    772
    Likes Received:
    0
    Location:
    Los Angeles
    that returns true if a character is hex (0-9, a-f) and false otherwise? thx
     
  2. ranthal

    ranthal i did what?

    Joined:
    Feb 8, 2007
    Messages:
    772
    Likes Received:
    0
    Location:
    Los Angeles
    whoops found it int isxdigit ( int c );
     
  3. CodeX

    CodeX Guest

    you mean one already written? You could easily implement that but...

    ctype.h:
    int isxdigit ( int c );

    *edit* omg did you get that from cplusplus.com? lol looks like we copied and pasted the same thing from the same place
     
  4. ranthal

    ranthal i did what?

    Joined:
    Feb 8, 2007
    Messages:
    772
    Likes Received:
    0
    Location:
    Los Angeles
    haha, i know, did a goodle search for c function ishex first, couldn't find anything, then after i posted started from isalpha and took me 2 mins :spank:
     
  5. ge0

    ge0 New Member

    Joined:
    Oct 31, 2005
    Messages:
    8,398
    Likes Received:
    0
    Location:
    JERSEY
    jsut use a reg expression [0-9][a-f][A-F]
     

Share This Page