How Do I Run Cpp on Ubuntu?
Contents

How do I run a CPP file in Linux?

to compile and run a c++ program in ubuntu follow these simple steps:

  1. open terminal window.
  2. type “gedit” .
  3. A gedit window will appear whereyou can write your program.
  4. save your program as “filename. cpp” on desktop, “. …
  5. open terminal again and type “cd Desktop”.
  6. In second line type “g++ filename. …
  7. Type “./a.

11 дек. 2017 г.

How do I run a CPP file in Terminal?

cpp file that you want to compile, follow the following instructions to compile and run it. Step 1 − Open a new terminal window or cmd if you are on windows. Step 3 − Now enter the following command to compile the source file using g++. In place of replace it by any name like myprogram, etc.

Chloe Bennett

Chloe Bennett

Culture, Media & Entertainment Columnist

Chloe Bennett explores the intersection of pop culture, streaming entertainment, digital trends, and contemporary lifestyle. Her weekly commentary reaches thousands of culture enthusiasts.

Share this article
Twitter Facebook Pinterest