-
Notifications
You must be signed in to change notification settings - Fork 0
/
ft_isdigit.c
28 lines (26 loc) · 1.1 KB
/
ft_isdigit.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
28
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* isdigit.c :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: polmarti <[email protected]> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2023/09/13 12:29:28 by polmarti #+# #+# */
/* Updated: 2023/09/13 12:29:33 by polmarti ### ########.fr */
/* */
/* ************************************************************************** */
#include "libft.h"
int ft_isdigit(int c)
{
if (c >= 48 && c <= 57)
return (1);
return (0);
}
/*#include <libc.h>
#include <ctype.h>*/
/*int main(void)
{
printf("%d\n", ft_isdigit(48));
printf("%d\n", isdigit(48));
return (0);
}*/