-
Notifications
You must be signed in to change notification settings - Fork 1
/
ft_isprint.c
26 lines (23 loc) · 1.1 KB
/
ft_isprint.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
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ft_isprint.c :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: mcombeau <marvin@42.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2021/11/22 13:50:49 by mcombeau #+# #+# */
/* Updated: 2021/12/02 14:42:17 by mcombeau ### ########.fr */
/* */
/* ************************************************************************** */
/*
DESCRIPTION :
The function ft_isprint checks whether c is a printable character or not.
RETURN VALUE :
Non-zero if c is printable, zero if not.
*/
int ft_isprint(int c)
{
if (c >= ' ' && c <= '~')
return (c);
return (0);
}