so i have made this:
#include <iostream>
#include <string>
using namespace std;
int main()
{
  while(true)
  {
     string x;
     string y;
     string an1[3] = {"quit","exit","leave"};
     double ver = 0.1;
     cout << "basic0.1% ";
     cin >> x;
    if (x == "upgrade")
     {
      system("yay -Syyu");
     }
     else if (x == "install")
     {
      cout << "What do you want to install?" << "\n";
      cin >> y;
      system(("sudo yay -S " + y).c_str());
     }
     else if (x == "version")
     {
       cout << "version: " << ver << "\n"; 
     }
     else if (x == "clear")
     {
       system("clear");
     }
     else if(x == "quit" || "leave" || "exit")
     {
       break;
     }
     else if(x == "ls")
     {
     }
  }
  return 0;
}
and in the else if(x == "ls"){} i wanted to show the output of the command,i tried putting system("ls");
but it just exits the program.
btw this should be a little terminal emulator for linux but i am not sure yet,i am just having some fun.
 
    