-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathft_isdigit.c
30 lines (28 loc) · 1.13 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
29
30
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ft_isdigit.c :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: mhiguera <[email protected]> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2023/01/21 19:10:42 by mhiguera #+# #+# */
/* Updated: 2023/03/20 17:12:37 by mhiguera ### ########.fr */
/* */
/* ************************************************************************** */
#include "libft.h"
int ft_isdigit(int a)
{
if (a > 47 && a < 58)
return (1);
else
return (0);
}
/*int main(void)
{
printf("%d", ft_isdigit(51));
printf("%c%d", '\n', isdigit(51));
return (0);
}*/
/*
* Si me pasan un número retorna 1 y sino retorna 0.
*/