lem_in/Oglibft/libft/srcs/ft_round.c
Mthandazo Ndhlovu 1abb3fc566 invalid maps
2019-04-02 15:09:43 +02:00

21 lines
1015 B
C

/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ft_round.c :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: tmaze <tmaze@student.42.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2018/10/24 13:37:41 by tmaze #+# #+# */
/* Updated: 2018/10/24 13:37:52 by tmaze ### ########.fr */
/* */
/* ************************************************************************** */
#include "libft.h"
int ft_round(float x, float ind)
{
if ((x - (int)x) > ind)
return ((int)x + 1);
return ((int)x);
}