LinuxÒÁµéÔ°ÂÛ̳'s Archiver

AWAWO ·¢±íÓÚ 2006-12-13 16:23

¡¾ÇóÖú¡¿ÓÃgcc ±àÒë³ÌÐòÔÚÃüÁîÐÐÖÐÊäÈë²»ÔËÐÐ

ÄúºÃ!Ï£ÍûµÃµ½ÄúµÄ°ïÖú:
CBZR0[!r&[ ÈçϳÌÐò:,I9DF(mK{
#include <stdio.h>a.G{(Hb*Lua3z
main()
*cu`3Gq6K`9U_ {/v7Z-Dk5b7QF
char my_string[]="Hello World";
L8egt/j A"Db\       my_print(my_string);
H9v*d J,@2X~/e)h       my_print2(my_string);A5aKDxu+V
}
ID,[A5B6J int  my_print(char *string)
U['B5w.tf"lf.}S { printf("The string is %s\n",string);
Uw9MGi }
ME3C,E vk B int  my_print2(char *string)*@-~7AL&su?%P
{ char *string2;-I m:kOX$E4c
int size,size2,i;
+d4{)[%fw2|Q q size=strlen(string);
&x!mc"Wart size2=size-1;
Q9K:y5~8W,o string2=(char *)malloc(size+1);
L'?8tXJG~8v for(i=0;i<size;i++)%V1FK IYxc
string2[size2-i]=string[i];d7oEtF.|Z
string2[size]='\0';.G*Kw!U }Rk
printf("the string printed backward is %s\n",string2);FDP0l+d0J4f
}
w8jmm;]7ha*D/E ÓÃVI±à¼­ºÃºó´æÔÚ/home/font,ÎļþÃûhello.c,ÓÃGCC±àÒë:
NEA i] c y3r#X [font@localhost.font]$gcc -o hello hello.c
U&q2h"W?"~'p ]p ÔÙÊäÈë
+^ ?5k w-DV [font@localhost.font]$hello
B&B1nP2se0\s ½á¹û:a*~!]2r%n ~;c+k
-bash:hello:command not found
A|K"a+YB8l+[ ÇëÎÊΪʲôhello³ÌÐòÎÞ·¨ÔËÐÐ?лл!

flag ·¢±íÓÚ 2006-12-13 17:49

Ë­¸æËßÄã¿ÉÒÔÕâÑùÔËÐÐÃüÁîµÄ£¿

deepsource ·¢±íÓÚ 2006-12-16 23:11

ÈýÖÖ½â¾ö·½·¨:
@f/DE(Y ? TV%{:? (1)°ÑÄ㵱ǰµÄ¹¤×÷·¾¶Ìí¼Óµ½»·¾³±äÁ¿ÖÐ
$Z9ag6AFo0E"l (2)°ÑÄãµÄ±àÒëºÃµÄ³ÌÐò¸´ÖƵ½/usr/binĿ¼ÖÐ
{dd${d3BP(N1Pi (3)ÆäʵÔËÐÐ ./hello¾Í¿ÉÒÔÁË

wannachan ·¢±íÓÚ 2007-1-16 20:58

°Ñ .: Ìí¼Óµ½PATHÖÐ
;`@u?!^T2q-i »òÕßÖ±½Ó./hello

czgjw ·¢±íÓÚ 2007-1-23 09:06

·¹ý£¬ÎÞÓïÁË¡£

Äæ·ã·ÉÑï ·¢±íÓÚ 2007-2-7 01:54

Èç¹û¿ÉÖ´ÐÐÎļþĿ¼ÏÂÓà ./hello  ¾Í¿ÉÒÔÖ´ÐÐÁË£¬./ µÄº¬ÒåÊǵ±Ç°Ä¿Â¼£¬Èç¹û²»ÊÇhelloĿ¼ÏÂÔËÐУ¬ÒªÓà ·¾¶+ÎļþÃû Ö´ÐС£

chayedan ·¢±íÓÚ 2007-3-7 15:33

¶Ô°¡£¬Ö±½Ó./hello£¬ÎÒ¸Õ¿ªÊ¼Ò²ÊÇÕâÑù£¬²»¹ýÊéÉÏÓ¦¸ÃÓÐдµÄ°¡£¬ºÇºÇ£¬¼ÓÓÍ

Ò³: [1]

Powered by Discuz! Archiver 6.1.0  © 2001-2007 Comsenz Inc.