Last active
November 25, 2019 18:28
-
-
Save elvis-epx/cafaf9aebade599392a46d973e1e639a to your computer and use it in GitHub Desktop.
Resposta exercicio
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Programa gerador: | |
#include <stdio.h> | |
#include <stdlib.h> | |
int main(int argc, char*argv[]) | |
{ | |
int n = atoi(argv[1]); | |
for (int i = 0; i < (2 + n * 2); ++i) { | |
printf("%d ", n * 3 + i * 2); | |
} | |
printf("\n"); | |
} | |
Seqüência para n=6: | |
$ ./teste 6 | |
18 20 22 24 26 28 30 32 34 36 38 40 42 44 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment