changed sign_f to also return zero
This commit is contained in:
10
srcs/ft_fsign.c
Normal file
10
srcs/ft_fsign.c
Normal file
@@ -0,0 +1,10 @@
|
||||
#include "libft.h"
|
||||
|
||||
int ft_fsign(double i)
|
||||
{
|
||||
if (i < 0)
|
||||
return (-1);
|
||||
else if (i == 0)
|
||||
return (0);
|
||||
return (1);
|
||||
}
|
||||
Reference in New Issue
Block a user