-
Notifications
You must be signed in to change notification settings - Fork 0
/
ft_m1.c
37 lines (33 loc) · 1.11 KB
/
ft_m1.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
34
35
36
37
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ft_m1.c :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: bhagenlo <[email protected]. +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2022/05/04 13:09:42 by bhagenlo #+# #+# */
/* Updated: 2022/05/06 13:02:04 by bhagenlo ### ########.fr */
/* */
/* ************************************************************************** */
#include "libft.h"
int ft_abs(int n)
{
if (n < 0)
return (-n);
else
return (n);
}
int ft_min(int a, int b)
{
if (a < b)
return (a);
else
return (b);
}
int ft_max(int a, int b)
{
if (a < b)
return (b);
else
return (a);
}