TheRasVa

Задача 2,9

Feb 18th, 2015
252
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.42 KB | None | 0 0
  1. // Задача 2,9.cpp: определяет точку входа для консольного приложения.
  2. //
  3.  
  4. #include "stdafx.h"
  5. #include <iostream>
  6. using namespace std;
  7. int n, i, s;
  8.  
  9. int main()
  10. {
  11.     setlocale(LC_ALL, "russian");
  12.     i = 1;
  13.     s = 0;
  14.     cin >> n;
  15.     while (i <= n)
  16.     {
  17.         s = 0;
  18.         while (s < i)
  19.         {
  20.             cout << "^-^ ";
  21.             s++;
  22.         }
  23.         cout << endl;
  24.         i++;
  25.     }
  26.     system("PAUSE");
  27.     return 0;
  28. }
Advertisement
Add Comment
Please, Sign In to add comment