-
Notifications
You must be signed in to change notification settings - Fork 12
/
Copy pathft_isxdigit.c
27 lines (25 loc) · 1.17 KB
/
ft_isxdigit.c
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ft_isxdigit.c :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: apuchill <[email protected]> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2020/01/26 15:20:55 by apuchill #+# #+# */
/* Updated: 2020/10/30 19:56:10 by apuchill ### ########.fr */
/* */
/* ************************************************************************** */
/*
** LIBRARY: <ctype.h>
** SYNOPSIS: hexadecimal-digit character test
**
** DESCRIPTION:
** The isxdigit() function tests for any hexadecimal-digit character.
*/
int ft_isxdigit(int c)
{
if ((c >= '0' && c <= '9') || (c >= 'A' && c <= 'F') ||
(c >= 'a' && c <= 'f'))
return (1);
return (0);
}