-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathft_toupper.c
33 lines (31 loc) · 1.14 KB
/
ft_toupper.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
28
29
30
31
32
33
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ft_toupper.c :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: sde-silv <sde-silv@student.42berlin.de> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2023/05/05 16:08:14 by sde-silv #+# #+# */
/* Updated: 2023/06/12 14:47:03 by sde-silv ### ########.fr */
/* */
/* ************************************************************************** */
#include "libft.h"
/*
#include<ctype.h>
#include<stdio.h>
*/
int ft_toupper(int c)
{
if ('a' <= c && c <= 'z')
return (c - 32);
else
return (c);
}
/*
int main(void)
{
printf("toupper: %c\n", toupper('a'));
printf("ft_toupper: %c\n", ft_toupper('a'));
return (0);
}
*/