Search
 
SCRIPT & CODE EXAMPLE
 

CPP

how to run a c++ file from terminal linux

// compile the cpp file
g++ main.cpp -o main

// run the executable
./main
Comment

run a c++ file in terminal

c:hello>cl /EHsc hello.cpp
Microsoft (R) C/C++ Optimizing Compiler Version 19.10.25017 for x86
Copyright (C) Microsoft Corporation.  All rights reserved.

hello.cpp
Microsoft (R) Incremental Linker Version 14.10.25017.0
Copyright (C) Microsoft Corporation.  All rights reserved.

/out:hello.exe
hello.obj
Comment

PREVIOUS NEXT
Code Example
Cpp :: malloc in c++ 
Cpp :: how to use string variable in switch case in c++ 
Cpp :: opencv rgb to gray c++ 
Cpp :: how to check if a value is inside an array in c++ 
Cpp :: return by reference in cpp 
Cpp :: arduino buildin let 
Cpp :: how to split a string into words c++ 
Cpp :: maximum int c++ 
Cpp :: c++ char to uppercase 
Cpp :: c++ code for quicksort 
Cpp :: how to make a random number in c++ 
Cpp :: c++ struct with default values 
Cpp :: how to put bitset into a string in c++ 
Cpp :: arguments to a class instance c++ 
Cpp :: c++ vector loop delete 
Cpp :: if vector is empty c++ 
Cpp :: find in string c++ 
Cpp :: c++ segmented sieve primes 
Cpp :: read comma separated text file in c++ 
Cpp :: remove element from array c++ 
Cpp :: glew32.dll was not found 
Cpp :: update variable in const function C++ 
Cpp :: convert decimal to binary in c++ 
Cpp :: c++ inherit from class template 
Cpp :: cudamemcpy 
Cpp :: cpp string slice 
Cpp :: How to write into files in C++ 
Cpp :: c++ insert into map 
Cpp :: max in c++ 
Cpp :: new c++ 
ADD CONTENT
Topic
Content
Source link
Name
3+5 =