system("ANYTHING");

so i am working on a pretty basic text based RPG. and i made another post with my previous code. i have greatly revised it since then to actually use more then just 1 function (int main ())
this can be found here:
http://www.cplusplus.com/forum/beginner/115197/

but now i am wondering, why should i not be using 'system("");' commands? i have been using system("cls"); to clear the console screen and it works perfectly fine.

can someone explain what is wrong with doing that and also what would be an alternative to clear the screen?
Have some articles!

Article on why system() is evil: http://www.cplusplus.com/articles/j3wTURfi/
Article on how you can clear the screen: http://www.cplusplus.com/articles/4z18T05o/

Many thanks to Duoas for writing these~

-Albatross
closed account (Dy7SLyTq)
so ive been meaning to ask this anyways and this seems like a good place to do it:
what is the best way to run exes/elfs inside another process. i would prefer cross platform but will take solutions for either *nix or windows
closed account (S6k9GNh0)
Boost has a Process library.

POSIX which has a layer on just about any major platform can uses exec ( http://pubs.opengroup.org/onlinepubs/9699919799/functions/exec.html )
Last edited on
Thank you very much for the links Albatross!
Topic archived. No new replies allowed.