D

@dpascal

ft_print_params

C
2 years ago
#include <unistd.h> int main(int argc, char **argv) { int i; int j; i = 1; j = 0; while (i < argc)

ft_print_program_name

C
2 years ago
#include <unistd.h> int main(int argc, char **argv) { int i; i = 0; if (argc > 0) { while (argv[0][i])

ft_sqrt

C
2 years ago
#include <stdio.h> int ft_sqrt(int nb) { int i; int result; i = 0; result = 0; if (nb < 0)

ft_fibonacci

C
2 years ago
#include <stdio.h> int ft_fibonacci(int index) { if (index < 0) return (-1); else if (index == 0) return (0); else if (index == 1) return (1);

ft_recursive_power

C
2 years ago
#include <stdio.h> int ft_recursive_power(int nb, int power) { if (power == 0 || nb == 0) return (1); if (power < 0) return (0); return (nb * ft_recursive_power(nb, power - 1)); }

ft_iterative_power

C
2 years ago
#include <stdio.h> int ft_iterative_power(int nb, int power) { int i; int j; i = 1; j = nb; if (power < 0)

ft_recursive_factorial

C
2 years ago
#include <stdio.h> int ft_recursive_factorial(int nb) { if (nb == 0) return (1); if (nb < 0) return (0); return (nb * ft_recursive_factorial(nb - 1)); }

ft_iterative_factorial

C
2 years ago
#include <stdio.h> int ft_iterative_factorial(int nb) { int i; i = 1; if (nb < 0) return (0); while (nb > 1)

ft_sort_params

C
2 years ago
#include <unistd.h> void ft_putchar(char c) { write(1, &c, 1); } void ft_putstr(char *str) { int i;

ft_print_comb2

C
2 years ago
#include <unistd.h> int ft_print_comb2(int c) { int a; int b; a = '0'; while (a <= 98) { b = a + 1;

ft_print_comb

C
2 years ago
#include <unistd.h> void ft_print_comb(void) { char c; char d; char u; c = '0'; while (c <= '7')

ft_is_negative

C
2 years ago
#include <unistd.h> void ft_is_negative(int n) { if (n < 0) { write(1, "N", 1); } else {

ft_print_numbers

C
2 years ago
#include <unistd.h> void ft_print_numbers(void) { char c; c = '0'; while (c <= '9') { write(1, &c, 1);

ft_print_reverse_alphabet

C
2 years ago
#include <unistd.h> void ft_print_reverse_alphabet(void) { char l; l = 'z'; while (l >= 'a') { write(1, &l, 1);

ft_print_alphabet

C
2 years ago
#include <unistd.h> void ft_print_alphabet(void) { char l; l = 'a'; while (l <= 'z') { write(1, &l, 1);

ft_print_program_name

C
2 years ago
#include <unistd.h> int main(int argc, char **argv) { int i; i = 0; if (argc > 0) { while (argv[0][i])

ft_atoi

C
2 years ago
#include <stdio.h> int ft_atoi(char *str) { int i; int res; int sign; res = 0; i = 0;

ft_putnbr

C
2 years ago
#include <unistd.h> void ft_putchar(char c) { write(1, &c, 1); } void ft_putnbr(int nb) { if (nb == -2147483648)

ft_strlen

C
2 years ago
#include <stdio.h> int ft_strlen(char *str) { int len; len = 0; while (str[len] != '\0') { len++;

ft_strstr

C
2 years ago
#include <stdio.h> char *ft_strstr(char *str, char *to_find) { int i; int j; i = 0; j = 0; if (to_find[0] == '\0')