-
Notifications
You must be signed in to change notification settings - Fork 0
/
ft_isalnum.c
25 lines (22 loc) · 1.21 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
24
25
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ft_isalnum.c :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: ssandova <[email protected]> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2023/09/16 17:24:50 by ssandova #+# #+# */
/* Updated: 2023/10/07 13:06:46 by ssandova ### ########.fr */
/* */
/* ************************************************************************** */
/*The isalnum() function tests for any character for which isalpha(3) or
isdigit(3) is true. The value of the argument must be representable as an
unsigned char or the value of EOF.*/
#include "libft.h"
int ft_isalnum(int c)
{
if ((c >= 48 && c <= 57) || (c >= 65 && c <= 90) || (c >= 97 && c <= 122))
return (1);
else
return (0);
}