-
Notifications
You must be signed in to change notification settings - Fork 2
/
ft_tolower.c
27 lines (24 loc) · 1.22 KB
/
ft_tolower.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
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ft_tolower.c :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: adiaz-lo <marvin@42.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2019/11/19 11:25:25 by adiaz-lo #+# #+# */
/* Updated: 2020/01/13 09:13:18 by adiaz-lo ### ########.fr */
/* */
/* ************************************************************************** */
/*
** The function checks if the character received as an argument is an uppercase,
** it converts to lowercase, otherwise, it returns it without change.
** For further information, please check the standard C library function
** 'tolower(int c)'
*/
#include "libft.h"
int ft_tolower(int c)
{
if (c >= 'A' && c <= 'Z')
return (c + 32);
return (c);
}