-
Notifications
You must be signed in to change notification settings - Fork 0
/
ft_isalpha.c
26 lines (23 loc) · 1.2 KB
/
ft_isalpha.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
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ft_isalpha.c :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: oadewumi <[email protected]> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2023/10/24 15:12:40 by oadewumi #+# #+# */
/* Updated: 2023/12/13 11:30:55 by oadewumi ### ########.fr */
/* */
/* ************************************************************************** */
/*This function checks that the returned
character to the argument 'alf' is an alphabet*/
/* It returns 1 if it is true and 0 if its false */
/* This function imitates the standard Clibrary function 'isalpha' */
int ft_isalpha(int alf)
{
if ((alf >= 'A' && alf <= 'Z') || (alf >= 'a' && alf <= 'z'))
{
return (1);
}
return (0);
}