Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- #include <math.h>
- int main () {
- char repeticao = 's';
- int op;
- do {
- printf("\n MENU ");
- printf("\n1 - NOVO");
- printf("\n2 - ABRIR");
- printf("\n3 - SALVAR");
- printf("\n4 - FECHAR");
- printf("\n\nEscolha uma opcao: ");
- scanf ("%d", &op);
- switch(op) {
- case 1: printf("\n NOVO!");
- break;
- case 2: printf("\n ABRIR!");
- break;
- case 3: printf("\n SALVAR!");
- break;
- case 4: printf("\n FECHAR!");
- break;
- default: printf("\n nao e valido seu arrombado!");
- }
- printf("\n\nDeseja executar o programa novamente? [S] , [N] \n");
- fflush(stdin);
- scanf("%c", &repeticao);
- } while ((repeticao == 's') || (repeticao == 'S'));
- getch();
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement