42_ft_printf/ft_isdigit.c

21 lines
996 B
C
Raw Normal View History

2022-10-06 20:30:03 -04:00
/* ************************************************************************** */
/* */
/* ::: :::::::: */
2022-10-23 13:01:50 -04:00
/* ft_isdigit.c :+: :+: :+: */
2022-10-06 20:30:03 -04:00
/* +:+ +:+ +:+ */
/* By: cchauvet <cchauvet@student.42angoulem +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
2022-10-23 13:01:50 -04:00
/* Created: 2022/10/11 16:34:14 by cchauvet #+# #+# */
/* Updated: 2022/10/11 16:35:40 by cchauvet ### ########.fr */
2022-10-06 20:30:03 -04:00
/* */
/* ************************************************************************** */
2022-10-23 13:01:50 -04:00
#include "ft_printf.h"
2022-10-06 20:30:03 -04:00
2022-10-23 13:01:50 -04:00
int ft_isdigit(int c)
2022-10-06 20:30:03 -04:00
{
2022-10-23 13:01:50 -04:00
if (c <= '9' && c >= '0')
return (1);
2022-10-10 13:33:47 -04:00
return (0);
2022-10-06 20:30:03 -04:00
}