summaryrefslogtreecommitdiff
path: root/ft_isdigit.c
diff options
context:
space:
mode:
Diffstat (limited to 'ft_isdigit.c')
-rw-r--r--ft_isdigit.c18
1 files changed, 18 insertions, 0 deletions
diff --git a/ft_isdigit.c b/ft_isdigit.c
new file mode 100644
index 0000000..273bfa3
--- /dev/null
+++ b/ft_isdigit.c
@@ -0,0 +1,18 @@
+/* ************************************************************************** */
+/* */
+/* ::: :::::::: */
+/* ft_isdigit.c :+: :+: :+: */
+/* +:+ +:+ +:+ */
+/* By: dkaiser <dkaiser@student.42heilbronn.de +#+ +:+ +#+ */
+/* +#+#+#+#+#+ +#+ */
+/* Created: 2024/03/04 21:07:03 by dkaiser #+# #+# */
+/* Updated: 2024/03/04 21:18:00 by dkaiser ### ########.fr */
+/* */
+/* ************************************************************************** */
+
+int ft_isdigit(int c)
+{
+ if (c >= '0' && c <= '9')
+ return (1);
+ return (0);
+}