Ò׽ؽØͼÈí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

¹ØÓÚc,c++Êä³ö¸ñʽ¿ØÖÆ

1.
printf("%.9lf\n",sum); 
//Êä³öСÊýµãºó9λ²»Ê¡È¥Ä©Î²¶àÓàµÄ0
2.
printf("%.10g\n",sum);
 //Êä³öСÊýµãºó9λ²»Ê¡È¥Ä©Î²¶àÓàµÄ0
3.
#include<iomanip>
cout<<setprecision(10)<<sum<<endl;
//Êä³öСÊýµãºó9λʡȥĩβ¶àÓàµÄ0
4. 
#include<iomanip>
cout.precision(9);
cout <<setiosflags(ios::scientific)<<sum<<endl;
//Êä³öСÊýµãºó9λʡȥĩβ¶àÓàµÄ0,²¢ÓÿÆѧ¼ÆÊý·¨±íʾ
5.
#include<iomanip>
cout.precision(9);
cout <<setiosflags(ios::fixed)<<sum<<endl;
//Êä³öСÊýµãºó9λ²»Ê¡È¥Ä©Î²¶àÓàµÄ0
6.
cout.precision(10);
cout.fixed;
cout<<sum<<endl;
//Êä³öСÊýµãºó9λʡȥĩβ¶àÓàµÄ0  
7.
cout.precision(9);
cout <<fixed<<sum<<endl;
//Êä³öСÊýµãºó9λ²»Ê¡È¥Ä©Î²¶àÓàµÄ0


Ïà¹ØÎĵµ£º

C ÓïÑÔµÄÃæÏò¶ÔÏó

C ÓïÑÔµÄÃæÏò¶ÔÏó
ÈçÇ°Ëù˵£¬ÃæÏò¶ÔÏóÊÇÒ»ÖÖÈí¼þÉè¼ÆµÄ˼Ï룬ÊÇÓïÑÔÎ޹صġ£ÔÚ±¾½ÚÖУ¬ÎÒ¾ÙÒ»¸öÁ´±í(list) µÄÀý×ÓÀ´ËµÃ÷ÈçºÎÔÚ C ÓïÑÔÖеÄÉè¼Æ³öÓÐÃæÏò¶ÔÏó·ç¸ñµÄ´úÂë¡£
¶¨Òå½Ó¿Ú
½Ó¿ÚÊÇÃæÏò¶ÔÏóÓïÑÔÖеÄÒ»¸ö±È½ÏÖØÒªµÄ¸ÅÄ½Ó¿ÚÖ»¶ÔÍⲿ³ÐŵʵÏָýӿڵÄʵÌå¿ÉÒÔÍê³ÉʲôÑùµÄ¹¦ÄÜ£¬µ«ÊDz»±©Â¶ÊµÏֵķ½Ê½¡£ÕâÑùµÄºÃ´¦ÊÇ ......

linuxÏÂCÓïÑÔ¶àÏ̱߳à³ÌʵÀý

ѧ¶«Î÷£¬ÍùÍùʵÀý²ÅÊÇ×îÈÃÈ˸ÐÐËȤµÄ£¬ÀÏÊÇѧ»ù´¡ÀíÂÛ£¬²»¶¯ÊÖ£¬¸Ð¾õûÓгɾ͸У¬ºÇºÇ¡£
ÏÂÃæÏÈÀ´Ò»¸öʵÀý¡£ÎÒÃÇͨ¹ý´´½¨Á½¸öÏß³ÌÀ´ÊµÏÖ¶ÔÒ»¸öÊýµÄµÝ¼Ó¡£
»òÐíÕâ¸öʵÀýûÓÐʵ¼ÊÔËÓõļÛÖµ£¬µ«ÊÇÉÔ΢¸Ä¶¯Ò»Ï£¬ÎÒÃǾͿÉÒÔÓõ½ÆäËûµØ·½È¥À­¡£
ÏÂÃæÊÇÎÒÃǵĴúÂ룺
/*thread_example.c :  c multiple thread programmi ......

ÀûÓÃÊÀ½ç×îС×î¿ìµÄC±àÒëÆ÷´òÔì×Ô¼ºµÄC±à¼­Æ÷

ÀûÓÃÊÀ½ç×îС×î¿ìµÄC±àÒëÆ÷´òÔì×Ô¼ºµÄC±à¼­Æ÷
¼ò½étinycc ÊÀ½çÉÏ×îС±àÒëËÙ¶È×î¿ìµÄCÓïÑÔ±àÒëÆ÷ ¸÷ÏÄܽø¹Ù·½È¥¿´
TCC¹Ù·½ÏÂÔصØÖ·£ºhttp://ftp.twaren.net/Unix/NonGNU/tinycc/tcc-0.9.25-win32-bin.zip
ÎÒÖªµÀ ´ó¼Ò»ù±¾É϶¼ÓùýWIN—TC°É ÌرðÊÇÉϹý´óѧµÄ CÓïÑÔÈëÃÅʱÓõĶ¼ÊÇ
ËûµÄ²Ù×÷½çÃæÈçͼ
¹þ¹þ ¿´ÏÂÍ ......

no acceptable C compiler found in $PATH

GCC°²×°³É¹¦,ËùÐèÎļþÓÐ:
libf2c-3.3.2-1.i386.rpm
libstdc++-devel-3.3.2-1.i386.rpm
glibc-kernheaders-2.4-8.36.i386.rpm
glibc-headers-2.3.2-101.i386.rpm
glibc-devel-2.3.2-101.i386.rpm
gcc-objc-3.3.2-1.i386.rpm
binutils-2.14.90.0.6-3.i386.rpm
gcc-3.3.2-1.i386.rpm
gcc-c++-3.3.2-1.i386.rpm
autom ......

¡ïÔõÑùѧϰCÓïÑÔ(Ï׸øÃÔãµÄC°®ºÃÕß)¡ï

Ò» £¬ÔõÑùѧϰCÓïÑÔ
     ºÜ¶àÈ˶ÔѧϰCÓïÑԸе½ÎÞ´ÓÏÂÊÖ£¬¾­³£ÎÊÎÒͬһ¸öÎÊÌ⣺¾¿¾¹ÔõÑùѧϰCÓïÑÔ£¿ÎÒÊÇÒ»¸ö½Ìʦ£¬ÒѾ­¿ª·¢Á˺ܶàÄêµÄ³ÌÐò£¬ºÍºÜ¶à¸Õ¸ÕÆð²½µÄÈËÒ»Ñù£¬Ñ§Ï°µÄµÚÒ»¸ö¼ÆËã»úÓïÑÔ¾ÍÊÇCÓïÑÔ¡£¾­¹ýÕâЩÄêµÄ¿ª·¢£¬ÎÒÉîÉîµÄÌå»áµ½CÓïÑÔ¶ÔÓÚÒ»¸ö³ÌÐòÉè¼ÆÈËÔ±¶àôµÄÖØÒª£¬Èç¹û²»¶®CÓ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ