I'm sure there is a command better than system("CLS") to clear the screen. I'm finding this very slow. Any help would be appreciated.
I'm sure there is a command better than system("CLS") to clear the screen. I'm finding this very slow. Any help would be appreciated.
Yes and no.
There is no portable way to clear the screen it totally depends upon your compiler and operating system. Read the FAQ. All the answers you seek are in there.
Free the weed!! Class B to class C is not good enough!!
And the FAQ is here :- http://faq.cprogramming.com/cgi-bin/smartfaq.cgi
> I'm finding this very slow.
So does everyone else.
>I'm sure there is a command better than system("CLS") to clear the screen.
It depends on what you are willing to sacrifice. If you can afford a loss of portability then you should use a system specific solution such as Borland's clrscr function, they tend to be considerably faster than the system function. If portability is your goal then you should figure out a way to avoid clearing the screen if it isn't absolutely necessary.
-Prelude
My best code is written with the delete key.
If you want a faster clear screen function you indeed probably
end up with a compiler specific and not portable function,
What's your compiler?
i'm using visual studios.