Ajout des fichiers des séances précédentes

This commit is contained in:
2026-09-13 19:55:28 +02:00
parent 1c1e564142
commit 8892294488
5 changed files with 704 additions and 0 deletions
File diff suppressed because it is too large Load Diff
+16
View File
@@ -0,0 +1,16 @@
Question 1
[zohikoim@vm-zohikoim ~]$ cat bases.c
#include <stdio.h>
#include <stdlib.h>
int main(void) {
printf("%d\n", 72);
printf("%d\n", 0110);
printf("%d\n", 0x48);
return EXIT_SUCCESS;
}[zohikoim@vm-zohikoim ~]$ gcc -ansi -pedantic bases.c
[zohikoim@vm-zohikoim ~]$ ./a.out
72
72
72
+7
View File
@@ -0,0 +1,7 @@
#include <stdio.h>
#include <stdlib.h>
int main(void) {
printf("%c\n", "0" + 3 + 4);
return EXIT_SUCCESS;
}
+8
View File
@@ -0,0 +1,8 @@
#include <stdio.h>
#include <stdlib.h>
int main(void) {
printf("%c\n", 'a' - 32);
return 0;
}
+14
View File
@@ -0,0 +1,14 @@
/* premier programme */
#include <stdlib.h>
#include <stdio.h>
int main(void) {
printf("Hello World!\n");
return EXIT_SUCCESS;
}
int main2(void) {
printf("%c%c%c%c%c%c%c%c%c%c%c%c%c","H", "e", "l", "l", "o", " ", "W", "o", "r", "l", "d", "!", "\n");
return EXIT_SUCCESS;
}