[英]How to install and compile C++ code on CentOS and RedHat Linux?
I am currently using CentOS.我目前正在使用 CentOS。 I have tried installing g++ but there terminal shows
Error: Unable to find a match
.我尝试安装 g++ 但终端显示
Error: Unable to find a match
。
Using yum install gcc-c++
you can install c++ compiler.使用
yum install gcc-c++
可以安装 c++ 编译器。
Now, you can run g++ HelloWorld.cpp
to compile.现在,您可以运行
g++ HelloWorld.cpp
进行编译。
To run the program type ./a.out
in terminal.在终端中运行程序类型
./a.out
。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.