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

The C Programming Language

To be continued...
µÚ8Õ UNIXϵͳ½Ó¿Ú
#include <stdio.h>
#include <fcntl.h>
#include "syscalls.h"
#defien PERMS 0666
void error(char *, ...);
/* cpº¯Êý: ½« f1 ¸´ÖƵ½ f2 */
int main(int argc, char *argv[])
{
    int f1, f2, n;
    char buf[BUFSIZ];
   
    if (argc != 3)
        error("Usage: c from to");
    if ((f1 = open(argv[1], O_RDONLY, 0)) == -1)
        error("cp: can't open %s", argv[1]);
    if ((f2 = creat(argv[2], PERMS)) == -1)
        error("cp: can't create %s, mode %03o", argv[2], PERMS);
    while ((n = read(f1, buf, BUFSIZ)) > 0)
        if (write(f2, buf, n) != n)
            error("cp: write error on file %s", argv[2]);
    return 0;
}
#include <stdio.h>
#include <stdarg.h>
/* errorº¯Êý: ´òÓ¡Ò»¸ö³ö´íÐÅÏ¢£¬È»ºóÖÕÖ¹ */
void error(char *fmt, ...)
{
    va_list args;
   
    va_start(args, fmt);
    fprintf(stderr, "error:");
    vfprintf(stderr, fmt, args);
    fprintf(stderr, "\n");
    va_end(args);
    exit (1);
}


Ïà¹ØÎĵµ£º

ÓÃCдµÄ3DÃÔ¹¬

          Boss˵£¬Òª¿´OpenGL£¬¿´ÁË¿ìÒ»¸öÔ£¬×ÜËã³öÁ˸öÏñÑùµÄ¶«Î÷£¬ÓÃCдÁ˸ö3DÃÔ¹¬£¬
ËäȻֻÓÐ350ÐÐ
       ´úÂ룬²»¹ý±ßѧ±ßд£¬×ã×ãдÁËÒ»ÖÜʱ¼ä£¬»¹ÊÇСÓгɾ͸еģ¬»î»î»î£¡
         &n ......

C#ÖÐһЩ×Ö·û´®²Ù×÷µÄ³£ÓÃÓ÷¨,c#±àÂëºÍ½âÂë

//»ñµÃºº×ÖµÄÇøλÂë
¡¡¡¡byte[] array = new byte[2];
¡¡¡¡array = System.Text.Encoding.Default.GetBytes("°¡");
int i1 = (short)(array[0] - ''\0'');
¡¡¡¡int i2 = (short)(array[1] - ''\0'');
//unicode½âÂ뷽ʽϵĺº×ÖÂë
¡¡¡¡array = System.Text.Encoding.Unicode.GetBytes("°¡");
¡¡¡¡i1 = (short)(arra ......

C#ÀàºÍC#½á¹¹ÌåµÄ¹Øϵ

C#ÀࣺÀàÊÇC# Öй¦ÄÜ×îΪǿ´óµÄÊý¾ÝÀàÐÍ£¬ÀàÒ²¶¨ÒåÁËÊý¾ÝÀàÐ͵ÄÊý¾ÝºÍÐÐΪ¡£È»ºó£¬³ÌÐòÔ±¿ÉÒÔ´´½¨×÷Ϊ´ËÀàµÄʵÀýµÄ¶ÔÏó¡£
C#½á¹¹Ì壺½á¹¹ÌåÊÇÇáÁ¿Ð͵ÄÀ࣬ʹÓÿªÏúÏà¶ÔÓÚÀà½ÏС¡£
C#ÀàºÍC#½á¹¹ÌåÁ½ÕߵĹØϵ£º
1.Êý¾ÝÀàÐÍ£ºÀàºÍ½á¹¹Ì嶼ÊÇÊý¾ÝÀàÐÍ£¬ÀàÊÇÒýÓÃÀàÐÍ£¬½á¹¹ÌåÊÇÖµÀàÐÍ¡£
2.¼Ì³ÐÐÔ£ºÀà¿ÉÒԼ̳кͱ»¼Ì³Ð£¬¶ø½á¹ ......

c/c++ ×óÖµ ÓÒÖµÌÖÂÛ

×óÖµÐÔ£¨lvalueness£©ÔÚC/C++ÖÐÊDZí´ïʽµÄÒ»¸öÖØÒªÊôÐÔ¡£Ö»ÓÐͨ¹ýÒ»¸ö×óÖµ±í´ïʽ²ÅÄÜÀ´ÒýÓü°¸ü¸ÄÒ»¸ö¶ÔÏó£¨object£©µÄÖµ¡££¨Ä³Ð©Çé¿öÏ£¬ÓÒÖµ±í´ïʽҲÄÜÒýÓã¨refer£©µ½Ä³Ò»¸ö¶ÔÏ󣬲¢ÇÒ¿ÉÄܼä½ÓÐ޸ĸöÔÏóµÄÖµ£¬ºóÊö£©¡£
    ºÎν¶ÔÏó£¿Èç¹ûûÓÐÃ÷ȷ˵Ã÷£¬ÕâÀï˵µÄ¶ÔÏ󣬺ÍÏÁÒåµÄÀà/¶ÔÏó£¨class/object£© ......

ÔÚVC6ÖÐʹÓÃc API·½Ê½Á¬½ÓMySQLÊý¾Ý¿â

ÔÚVC6ÖÐʹÓÃc API·½Ê½Á¬½ÓMySQLÊý¾Ý¿â
Ò»¡¢»·¾³ÅäÖÃ
1¡¢ÔÚMySqlµÄ¹Ù·½ÍøÕ¾ÏÂÔØmysql-connector-c-noinstall£¬²¢½«½âѹºóµÄbinºÍincludeÎļþ¼Ð¿½±´µ½MysqlµÄ°²×°Ä¿Â¼
2¡¢ÉèÖÃVC6»·¾³£¬ÔÚvc¹¤¾ß-Ñ¡Ïî-Ŀ¼£¬¼ÓÈë¸Õ²ÅµÄIncludeÎļþ¼ÐµÄ·¾¶£¬ÀýÈ磺C:\Program Files\MySQL\MySQL Server 5.1\include
¶þ¡¢¹¤³ÌÉèÖÃ
3¡¢½«li ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ