-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathft_isalpha.c
More file actions
executable file
·42 lines (36 loc) · 1.19 KB
/
ft_isalpha.c
File metadata and controls
executable file
·42 lines (36 loc) · 1.19 KB
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
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ft_isalpha.c :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: gyong-si <marvin@42.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2023/09/06 13:00:42 by gyong-si #+# #+# */
/* Updated: 2023/09/14 11:20:25 by gyong-si ### ########.fr */
/* */
/* ************************************************************************** */
#include "libft.h"
int ft_isalpha(int c)
{
if ((c >= 'a' && c <= 'z') || (c >= 'A' && c <= 'Z'))
{
return (1);
}
return (0);
}
/*
#include <stdio.h>
int main(void)
{
int c;
c = 'I';
if (ft_isalpha(c) == 0)
{
printf("%c is not an alphabet.", c);
}
else
{
printf("%c is an alphabet.", c);
}
return (0);
} */