Archived
first commit
This commit is contained in:
1 parent
1fe062c970
commit
eb6b113e51
125 files changed
+2987
No files matched your search
@@ -0,0 +1,6 @@
|
||||
#include <stdio.h>
|
||||
|
||||
void ft_ft(int *nbr)
|
||||
{
|
||||
*nbr = 42;
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
#include <stdio.h>
|
||||
|
||||
void ft_ultimate_ft(int *********nbr)
|
||||
{
|
||||
*********nbr = 42;
|
||||
}
|
||||
@@ -0,0 +1,10 @@
|
||||
#include <stdio.h>
|
||||
|
||||
void ft_swap(int *a, int *b)
|
||||
{
|
||||
int f;
|
||||
|
||||
f = *a;
|
||||
*a = *b;
|
||||
*b = f;
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
#include <stdio.h>
|
||||
|
||||
void ft_div_mod(int a, int b, int *div, int *mod)
|
||||
{
|
||||
*div = a / b;
|
||||
*mod = a % b;
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
#include <stdio.h>
|
||||
|
||||
void ft_ultimate_div_mod(int *a, int *b)
|
||||
{
|
||||
int f;
|
||||
int g;
|
||||
|
||||
f = *a;
|
||||
g = *b;
|
||||
*a = f / g;
|
||||
*b = f % g;
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
#include <unistd.h>
|
||||
|
||||
void ft_putstr(char *str)
|
||||
{
|
||||
int i;
|
||||
|
||||
i = 0;
|
||||
while (str[i])
|
||||
{
|
||||
write(1, &str[i], 1);
|
||||
i++;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
int ft_strlen(char *str)
|
||||
{
|
||||
int i;
|
||||
|
||||
i = 0;
|
||||
while (str[i] != '\0')
|
||||
{
|
||||
i++;
|
||||
}
|
||||
return (i);
|
||||
}
|
||||
Reference in new issue
Block a user