From ca054b2d952b740c412ea926a96c316bcdf9ad89 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kha=C3=AFs=20COLIN?= Date: Mon, 14 Oct 2024 14:29:25 +0200 Subject: [PATCH] ft_isalpha: initial implementation --- ft_isalpha.c | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 ft_isalpha.c diff --git a/ft_isalpha.c b/ft_isalpha.c new file mode 100644 index 0000000..01b33d0 --- /dev/null +++ b/ft_isalpha.c @@ -0,0 +1,19 @@ +/* ************************************************************************** */ +/* */ +/* ::: :::::::: */ +/* ft_isalpha.c :+: :+: :+: */ +/* +:+ +:+ +:+ */ +/* By: kcolin +#+ +:+ +#+ */ +/* +#+#+#+#+#+ +#+ */ +/* Created: 2024/10/14 14:03:32 by kcolin #+# #+# */ +/* Updated: 2024/10/14 14:27:11 by kcolin ### ########.fr */ +/* */ +/* ************************************************************************** */ + +int ft_isalpha(int c) +{ + if ((c >= 'A' && c <= 'Z') || (c >= 'a' && c <= 'z')) + return (1); + else + return (0); +}