Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /* function system() example:
- system() makes a system call. To say easily, if you use function system("Command_in_Shell") like this, your programme will give a Command_in_Shell command to your shell during running.
- This example continuously makes a command "clear", so your screen will be cleared whenever the loop is made as if you command clear while you are on shell.
- */
- #include <iostream>
- #include <stdlib.h> //standard library header, this includes function system()
- using namespace std;
- int main(void){
- int input;
- while(1){
- cout << "This programme just get input and input endlessly, Input: "
- cin >> input;
- system("clear");}
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement