-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathft_tolower.c
More file actions
25 lines (24 loc) · 1.18 KB
/
ft_tolower.c
File metadata and controls
25 lines (24 loc) · 1.18 KB
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
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ft_tolower.c :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: jowagner <jowagner@student.42.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2024/11/12 14:03:13 by jowagner #+# #+# */
/* Updated: 2024/12/13 17:34:01 by jowagner ### ########.fr */
/* */
/* ************************************************************************** */
/**
* @brief Converts an uppercase letter to lowercase.
*
* @param c The character to be converted (typically an int).
* @return (The lowercase equivalent of c if it's an uppercase letter);
* otherwise, returns c unchanged.
*/
int ft_tolower(int c)
{
if (c >= 'A' && c <= 'Z')
return (c + 32);
return (c);
}