Advertisement
LightProgrammer000

Tabuadas [Infinitas]

Nov 29th, 2018
248
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 1.13 KB | None | 0 0
  1. /// Bibliotecas
  2. #include <stdlib.h>
  3. #include <locale.h>
  4. #include <iostream>
  5. using namespace std;
  6.  
  7. /// Programa
  8. int main ( int argc , char *argv[] )
  9. {
  10.     while(1)
  11.     {
  12.         int n = 1;
  13.         int i, j, qtd;
  14.  
  15.         // Sistemas
  16.         setlocale(LC_ALL, "");
  17.         system("cls & color E");
  18.  
  19.         // Apresentação
  20.         cout << " ========================== " << endl;
  21.         system("echo  - Usuario: %username%");
  22.         system("echo  - Computador: %computername%");
  23.         system("echo  - Hora: %time:~0,-3%");
  24.         system("echo  - Data: %date:/=-%");
  25.         cout << " ========================== \n" << endl;
  26.  
  27.         cout << " - Digite a Quantidade de Tabuadas que deseja: ";
  28.         cin >> qtd;
  29.  
  30.         system("cls & color A");
  31.         for ( j = 1; j <= qtd; j++ )
  32.         {
  33.             cout << "\n ---------- Tabuada " << n << " ---------- " << endl;
  34.             for ( i = 1 ; i <= 10; i++ )
  35.             {
  36.                 cout << " -> " << n <<" x " << i << " = " << (n * i) << endl;
  37.             }
  38.             n++;
  39.         }
  40.         cout << "\n";
  41.         system("pause");
  42.     }
  43.     return(0);
  44. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement