Advertisement
Guest User

Untitled

a guest
Jun 28th, 2017
501
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.96 KB | None | 0 0
  1. #include <iostream>
  2. #include <string>
  3. #include "windows.h"
  4.  
  5. using namespace std;
  6.  
  7. int main()
  8. {
  9.     string grafik[6];
  10.     string mellan="";
  11.     int langd=0;
  12.     bool oka=true;
  13.  
  14.     grafik[0]="|       +----+   |";
  15.     grafik[1]="|       |    |   |";
  16.     grafik[2]="|       |    |   |";
  17.     grafik[3]="|       |    |   |";
  18.     grafik[4]="|       |    |   |";
  19.     grafik[5]="+----   +----+   +----";
  20.     for(int i=0; i<1;){
  21.  
  22.         system("cls");
  23.         cout<<endl;
  24.         for(int x=0; x<=5; x++){
  25.             cout<<mellan<<grafik[x]<<endl;
  26.         }
  27.         if(mellan=="                                                          "){
  28.             oka=false;
  29.         }else if(mellan==""){
  30.             oka=true;
  31.         }
  32.         if(oka==true){
  33.             langd=langd+1;
  34.         }else{
  35.             langd=langd-1;
  36.         }
  37.         mellan="";
  38.         for(int y=0; y<langd; y++){
  39.             mellan=mellan+" ";
  40.         }
  41.     }
  42.     return 0;
  43. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement