/
ft_swap.c
executable file
·22 lines (20 loc) · 998 Bytes
/
ft_swap.c
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ft_swap.c :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: jsalome <marvin@42.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2019/09/02 19:12:20 by jsalome #+# #+# */
/* Updated: 2019/09/29 16:19:26 by jsalome ### ########.fr */
/* */
/* ************************************************************************** */
void ft_swap(int *a, int *b)
{
int buff;
if (!a || !b)
return ;
buff = *b;
*b = *a;
*a = buff;
}