本人空间所有文章如没有声明转载,则均为本人原创.
comsyschen@163.com
GCC&G++ 下的HELLO WORLD
上一篇 /
下一篇 2008-02-12 22:31:41
/ 个人分类:GCC&G++
IXPUB技术博客\P3y1jus.r9ZPY*l温习一下GCC&G++IXPUB技术博客 `&^C9TxkfJS)D
n7hyJ3B#O"W)P0GCC* hello.c - Canonical "Hello, World!" program
F4`,DZU0IXPUB技术博客5B:na3bj3H
#include <stdio.h>
%w+f(`+EA!@0int main(void)IXPUB技术博客Zqcv^D^
k
{IXPUB技术博客7Lr!I
Tf
printf("Hello,Linux programming world!\n");IXPUB技术博客bY8f(E6SI
return 0;IXPUB技术博客's9\{)Zz?0[N(M U.@)j
}IXPUB技术博客*\8hK[bp#Xy!~6e+g
IXPUB技术博客3A0V7n7y*C
编译
#gcc hello.c -o hello.o
执行
./hello.o
Hello,Linux programming world!
G++IXPUB技术博客'm:x
Eg\
///////////////////helloWorld.cppIXPUB技术博客wPb3To'GP
#include <iostream>
&ZZ
Ri:Z0using namespace std;
#kxAL({
ly0int main () IXPUB技术博客&g