-
Notifications
You must be signed in to change notification settings - Fork 0
/
ft_putnbr_u.c
26 lines (24 loc) · 1.1 KB
/
ft_putnbr_u.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
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ft_putnbr_u.c :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: aarbaoui <[email protected]> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2022/10/23 10:51:56 by aarbaoui #+# #+# */
/* Updated: 2022/10/27 17:11:09 by aarbaoui ### ########.fr */
/* */
/* ************************************************************************** */
#include "ft_printf.h"
void ft_putnbr_u(unsigned int nbr, int *len)
{
if (nbr > 4294967295)
return ;
if (nbr < 10)
ft_putchar(nbr + '0', len);
else
{
ft_putnbr_u(nbr / 10, len);
ft_putchar((nbr % 10) + '0', len);
}
}