0
0
This commit is contained in:
Guy Baconniere
2021-08-20 10:02:38 +02:00
parent 5aa02c94b5
commit d30270c485
354 changed files with 0 additions and 0 deletions

View File

@@ -0,0 +1,22 @@
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ft_putstr.c :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: gbaconni <marvin@42lausanne.ch> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2021/08/13 09:16:54 by gbaconni #+# #+# */
/* Updated: 2021/08/13 09:21:15 by gbaconni ### ########.fr */
/* */
/* ************************************************************************** */
#include <unistd.h>
void ft_putstr(char *str)
{
char *p_str;
p_str = str;
while (*p_str != '\0')
write(1, p_str++, 1);
}

30
C_04/git_old/ex01/main.c Normal file
View File

@@ -0,0 +1,30 @@
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* main.c :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: gbaconni <marvin@42lausanne.ch> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2021/08/13 09:13:32 by gbaconni #+# #+# */
/* Updated: 2021/08/13 09:20:53 by gbaconni ### ########.fr */
/* */
/* ************************************************************************** */
#include <stdio.h>
#include <unistd.h>
#include <stdlib.h>
#include <string.h>
void ft_putstr(char *str);
int main(void)
{
char str[32];
printf("Input String [max 31]: ");
scanf("%s", str);
ft_putstr(str);
write(1, "\n", 1);
printf("str=%s (ft_putstr)\n", str);
return (0);
}

8
C_04/git_old/ex01/main.sh Executable file
View File

@@ -0,0 +1,8 @@
#!/bin/sh
set -e
#norminette -R CheckForbiddenSourceHeader ft_*.c
norminette -R CheckForbiddenSourceHeader
gcc -Wall -Wextra -Werror -o a.out *.c
echo $(basename $PWD):
./a.out
rm -f a.out