Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR CPP

how to refresh multiple command lines in C++ stream

#include <iostream>
#include <stdio.h>
using namespace std;

int main() 
{
    for (int i=0; i<5; i++) {
            for (int j=0; j<5; j++) {
                    cout << "-";
            }
            cout << endl;
    }

    getchar();
    printf("33[2J");
    printf("33[%d;%dH", 0, 0);

    for (int i=0; i<5; i++) {
            for (int j=0; j<5; j++) {
                    cout << "x";
            }
            cout<<endl;
    }

    return 0;
}
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #refresh #multiple #command #lines #stream
ADD COMMENT
Topic
Name
6+7 =