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

C×Ö·û´®·´×ªËã·¨

Ò»¸öºÜ¼ò½àµÄËã·¨£º
void Reverse(char s[])
{
    for(int i = 0, j = strlen(s) - 1; i < j; ++i, --j) {
        char c = s[i];
        s[i] = s[j];
        s[j] = c;
    }
}
#¹ØÓÚa, b½»»»ÆäËüËã·¨£º
    a ^= b;
    b ^= a;
    a ^= b;
Ò»¸öÎåÖֽⷨµÄ°æ±¾£º
ת×Ô£ºhttp://www.cnblogs.com/Mainz/articles/1164602.html
ÕâÊÇÍøÂçÁ÷´«µÄMicrosoftµÄÃæÊÔÌâÄ¿Ö®Ò»£º“±àд·´×ª×Ö·û´®µÄ³ÌÐò£¬ÒªÇóÓÅ»¯Ëٶȡ¢ÓÅ»¯¿Õ¼ä”¡£ÒòΪ×î½üÒ»Ö±ºÜ¶à¹Ø×¢Ëã·¨·½ÃæµÄʵ¼ùºÍÑо¿£¬Òò´Ë¶ÔÕâ¸öÎÊÌâ½øÐÐÁËһЩ˼¿¼£¬¸ø³öÁË5ÖÖʵÏÖ·½·¨£¨ÓÐÁ½ÖֽⷨÏà¹ØÐԱȽϴ󣩡£
½â·¨Ò»£ºµÚÒ»´Î¿´µ½ÕâÌâÄ¿£¬Ïëµ½×î¼òµ¥¡¢×îÖ±¾õµÄ½â·¨¾ÍÊÇ£º±éÀú×Ö·û´®£¬½«µÚÒ»¸ö×Ö·ûºÍ×îºóÒ»¸ö½»»»£¬µÚ¶þ¸öºÍµ¹ÊýµÚ¶þ¸ö½»»»£¬ÒÀ´ÎÑ­»·£¬¼´¿É£¬ÓÚÊÇÓÐÁ˵ÚÒ»¸ö½â·¨£º
char* strrev1(const char* str)
{
       int len = strlen(str);
       char* tmp = new char[len + 1];
        strcpy(tmp,str);
       for (int i = 0; i < len/2; ++i)
       {
          char c = tmp[i];
           tmp[i] = tmp[len – i - 1];
           tmp[len – i - 1] = c;
        }
       return tmp;
}
ÕâÀïÊÇͨ¹ýÊý×éµÄϱ귽ʽ·ÃÎÊ×Ö·û´®µÄ×Ö·û£¬Êµ¼ÊÉÏÓÃÖ¸ÕëÖ±½Ó²Ù×÷¼´¿É¡£½â·¨¶þÕýÊÇ»ùÓÚ´Ë£¬ÊµÏÖ´úÂëΪ£º
char* strrev2(const char* str)
{
       char* tmp = new char[strlen(str) + 1];
        strcpy(tmp,str);
       char* ret = tmp;
       char* p =


Ïà¹ØÎĵµ£º

extern "C" ÔĶÁ±Ê¼Ç zz

·¢ÐÅÈË: RoachCock (·´¶¯Ñ§ÊõȨÍþ), ÐÅÇø: CPlusPlus
±ê  Ìâ: extern "C" ÔĶÁ±Ê¼Ç
·¢ÐÅÕ¾: ˮľÉçÇø (Fri Mar  7 00:22:47 2008), Õ¾ÄÚ
±¾ÒÔΪºÜ¼òµ¥£¬×ÐϸÔĶÁÁËһϠC++ ±ê×¼£¬·¢ÏÖÄÚÈÝ»¹²»ÉÙ¡£×ܽáÁËһϡ£
Òªµã£º
º¯ÊýÀàÐÍ£¬º¯ÊýÃû£¬±äÁ¿Ãû¾ßÓÐÓïÑÔÁ´½ÓÐÔ£¬language linkage¡£
ÓïÑÔÁ´½ÓÐÔ¿ÉÄÜ»áÓ°Ïìµ½ ......

¹ØÓÚ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.pre ......

keil C ´ÓÁãѧÆð ½Ìѵ1

#include<reg52.h>
#define uchar unsigned char
#define uint unsigned int
uchar num;
void main()
{
 TMOD=0x01;
 TH0=(65536-45872)/256;
 TL0=(65536-45872)%256;
 EA=1;
 ET0=1;
 TR0=1;
 P1=0xFF;
 while(1);
}
void T0_time() interrupt 1
{
  ......

GCC ±àÒëc³ÌÐòµÄ·½·¨¼°¹ý³Ì½âÎö

GCC ±àÒëc³ÌÐòµÄ·½·¨¼°¹ý³Ì½âÎö 
Justin.zp.Yang 2010.04.10
        Ä¿Ç° Linux ÏÂ×î³£ÓÃµÄ C ÓïÑÔ±àÒëÆ÷ÊÇ GCC £¨ GNU Compiler Collection £©£¬ËüÊÇ GNU ÏîÄ¿ÖзûºÏ ANSI C ±ê×¼µÄ±àÒëϵͳ£¬Äܹ»±àÒëÓà C ¡¢ C++ ºÍ Object C µÈÓïÑÔ±àдµÄ³ÌÐò¡£ GCC ²»½ö¹¦Äܷdz£Ç¿´ó£¬½á¹¹ ......

¹«ÀúתũÀúC³ÌÐò

×¢ÒâÖ»Äܵ½2049Ä꣡
 
#define uchar unsigned char
#define uint unsigned int
#include <intrins.h>
/*
¹«ÀúÄê¶ÔÓ¦µÄÅ©ÀúÊý¾Ý,ÿÄêÈý×Ö½Ú,
¸ñʽµÚÒ»×Ö½ÚBIT7-4 λ±íʾÈòÔÂÔ·Ý,ֵΪ0 ΪÎÞÈòÔÂ,BIT3-0 ¶ÔӦũÀúµÚ1-4 ÔµĴóС
µÚ¶þ×Ö½ÚBIT7-0 ¶ÔӦũÀúµÚ5-12 Ô´óС,µÚÈý×Ö½ÚBIT7 ±íʾũÀúµÚ13 ¸öÔ´óÐ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ