a
This commit is contained in:
39
APL1.2/fichier/ab
Normal file
39
APL1.2/fichier/ab
Normal file
@@ -0,0 +1,39 @@
|
||||
#include<stdio.h>
|
||||
#include<stdlib.h>
|
||||
|
||||
int main(void){
|
||||
|
||||
int t1[2][5],t2[3][5],t3[5][5],compteurTableau,compteur,valeurTableau=0,compteurHorizontal=0;
|
||||
|
||||
|
||||
for(compteurTableau=0;compteurTableau<2;compteurTableau++){
|
||||
|
||||
for(compteur=0;compteur<5;compteur++){
|
||||
|
||||
t1[compteurTableau][compteur]=compteur+1;
|
||||
}
|
||||
}
|
||||
|
||||
printf("\n");
|
||||
|
||||
for(compteurTableau=0;compteurTableau<3;compteurTableau++){
|
||||
|
||||
for(compteur=0;compteur<5;compteur++){
|
||||
|
||||
t2[compteurTableau][compteur]=++valeurTableau;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
for(compteurTableau=0;compteurTableau<5;compteurTableau++){
|
||||
|
||||
for(compteur=1;compteur<=5;compteur++){
|
||||
|
||||
if(compteur>compteurTableau){
|
||||
t3[compteurTableau][compteur]=0;
|
||||
} else
|
||||
t3[compteurTableau][compteur]=compteur;
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user