42_C_PISCINE/Rush/Rush02/ex00/ft_ctoa.c
Camille Chauvet 29ed24d567 init
2023-05-17 16:45:25 +00:00

24 lines
1.0 KiB
C

/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ft_ctoa.c :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: cchauvet <cchauvet@student.42angoulem +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2022/07/31 18:41:31 by cchauvet #+# #+# */
/* Updated: 2022/07/31 22:42:20 by cchauvet ### ########.fr */
/* */
/* ************************************************************************** */
#include "rush02.h"
char *ctoa(char c, unsigned int size)
{
char *str;
str = malloc(sizeof(char) * size);
str[0] = c;
str[1] = '\0';
return (str);
}