Browse Source

Modifications

master
Geoffrey Frogeye 4 years ago
parent
commit
0c9e48cc41
3 changed files with 6 additions and 4 deletions
  1. +2
    -2
      TP3/E6.c
  2. +3
    -1
      TP3/E7.c
  3. +1
    -1
      TP3/Makefile

+ 2
- 2
TP3/E6.c View File

@@ -3,7 +3,7 @@
#include <stdio.h>
#include <math.h>

#define N 10
#define N 20

int length(char* c) {
int i, len = -1;
@@ -17,7 +17,7 @@ int length(char* c) {
}

int number(char c) {
return c-48;
return c - '0';
}

int atoiMaison(char* c) {


+ 3
- 1
TP3/E7.c View File

@@ -29,6 +29,8 @@ int main() {
char c[N];
printf("Entrez du texte : ");
scanf("%s", &c);
printf("Miroir : %s\n", miroir(c));
char* m = miroir(c);
printf("Miroir : %s (addresse : 0x%x)\n", m, &m);
return 0;
}


+ 1
- 1
TP3/Makefile View File

@@ -1,7 +1,7 @@
all: $(patsubst %.c,%.exe,$(shell ls *.c))

%.exe: %.c
gcc $< -o $@
gcc $< -o $@ -lm
.PHONY: all clean