-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathft_putunbr_fd.c
23 lines (20 loc) · 1.05 KB
/
ft_putunbr_fd.c
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ft_putunbr_fd.c :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: ylagtab <[email protected]> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2019/04/04 15:47:04 by ylagtab #+# #+# */
/* Updated: 2020/10/15 08:37:09 by ylagtab ### ########.fr */
/* */
/* ************************************************************************** */
#include "libft.h"
int ft_putunbr_fd(unsigned long long n, int fd)
{
int ret;
ret = 0;
if (n / 10)
ret += ft_putunbr(n / 10);
return (ret + ft_putchar_fd(n % 10 + '0', fd));
}