-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathft_isalnum.c
executable file
·23 lines (20 loc) · 1.06 KB
/
ft_isalnum.c
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ft_isalnum.c :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: ngouy <ngouy@student.42.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2014/11/05 11:27:02 by ngouy #+# #+# */
/* Updated: 2015/11/04 15:29:10 by ngouy ### ########.fr */
/* */
/* ************************************************************************** */
/*
** return 1 if c is a letter or a digit, 0 either
*/
#include "libft.h"
int ft_isalnum(int c)
{
return ((c >= 48 && c <= 57) || (c >= 65 && c <= 90)
|| (c >= 97 && c <= 122));
}