xxGIANxx

exemplo do while

Dec 19th, 2012
141
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.25 KB | None | 0 0
  1. #include <stdio.h>
  2. #include <stdlib.h>
  3.  
  4. main()
  5. {
  6.       int NUM;
  7.      
  8.       do
  9.       {
  10.           printf("Digite um numero entre 1 e 9:");
  11.           scanf("%d", &NUM);
  12.       }while(NUM<1 || NUM>9);
  13.      
  14.       system("pause");
  15. }
Advertisement
Add Comment
Please, Sign In to add comment