Ci-dessous, les différences entre deux révisions de la page.
| Prochaine révision | Révision précédente | ||
| documentation:examples:sommevecvecseq.c [2013/02/06 16:37] – créée ltaulell | documentation:examples:sommevecvecseq.c [2023/01/13 09:38] (Version actuelle) – supprimée ccalugar | ||
|---|---|---|---|
| Ligne 1: | Ligne 1: | ||
| - | <code c SommeVecVecSEQ.c> | ||
| - | #include < | ||
| - | void main (void) | ||
| - | { | ||
| - | int i, | ||
| - | for(i=1; | ||
| - | { | ||
| - | A[i-1] = i; | ||
| - | B[i-1] = 10 - i; | ||
| - | } | ||
| - | |||
| - | printf ("Les deux vecteurs :\n"); | ||
| - | |||
| - | printf ("A = "); | ||
| - | for(i=1; | ||
| - | { | ||
| - | printf (" %d ", A[i-1]); | ||
| - | } | ||
| - | |||
| - | printf ("\nB = "); | ||
| - | for(i=1; | ||
| - | { | ||
| - | printf (" %d ", | ||
| - | } | ||
| - | |||
| - | for(i=1; | ||
| - | { | ||
| - | | ||
| - | } | ||
| - | |||
| - | printf ("\nLe vecteur somme : \n"); | ||
| - | printf ("C = "); | ||
| - | for(i=1; | ||
| - | { | ||
| - | printf (" %d ", | ||
| - | } | ||
| - | printf (" | ||
| - | |||
| - | } | ||
| - | </ | ||