¶Á¡¶c³ÌÐòÉè¼ÆÓïÑÔ¡·Ò»Ð©¸ÐÊÜ
×î½üÔÚ¿´¡¶c³ÌÐòÉè¼ÆÓïÑÔ¡·£¬¾ÍÊÇÄDZ¾±»ÓþΪCÓïÑÔÊ¥¾µÄÊé¼®¡£¼¸Ìì¿´ÁËÒ»Õ£¬¸Ð´¥ºÜ´ó£¬¿ªÆª¾ÍÉæ¼°µ½ºÜ¶àʵÓóÌÐò£¬²»ÏñÌ·ºÆÇ¿ÄÇÑùÈÃÈËÉîÏÝÓ﷨ϸ½ÚÖ®ÖУ¬¶øÇÒѧÍêÌ·µÄÊé¸Ð¾õʲô¶¼²»ÄÜ×ö¡£ºÜ¶àÎÊÌâÌ·¶¼»Ø±ÜÁË¡£Ëùνרҵ¿´¿´c³ÌÐòÉè¼ÆÓïÑԵĴúÂëµÄ·ç¸ñ¾ÍÄܸÐÊܵ½£¬Ò»ÖÖ¾«Ðĵñ×ÁµÄÒÕÊõÆ·¡£µÚÒ»ÕÂÓÐÒ»¸ö¼òµ¥µÄÎÊÌ⣬¾ÍÊǰÑ×Ö·û´®Óжà¸ö¿Õ¸ñµÄÓÃÒ»¸ö¿Õ¸ñ´úÌæ£¬×Ô¼ºÐ´ÁËÒ»ÖÖ£¬ºóÀ´¿´Á˴𰸣¬¸Ð¾õ×Ô¼ºÆäʵ°Ñ¼òµ¥µÄÎÊÌ⸴ÔÓ»¯ÁË£¬Õâ»òÐí¾ÍÊÇ´óÅ£ÓëÎÒÕâÑù²ËÄñµÄ²î±ð¡£ÏÂÃæÊÇÎÒ×Ô¼ºµÄ³ÌÐò.#include<stdio.h>
int main(void)
{
int c;
int count;
while((c=getchar())!=EOF)
{
if(c==' ') count++;
else
{
putchar(c);
count==0;
}
if(count==1) putchar(' ');
}
}
Ïà¹ØÎĵµ£º
SQLite¹Ù·½ÍøÕ¾Àý×Ó£º
#include <stdio.h>
#include <sqlite3.h>
static int callback(void *NotUsed, int argc, char **argv, char **azColName){
int i;
for(i=0; i<argc; i++){
printf("%s = %s\n", azColName[i], argv[i] ? argv[i] : "NULL");
}
printf("\n");
return 0;
}
i ......
ÎÊÌâÃèÊö£ºÐ´Ò»¸öº¯Êý£¬½ÓÊÜÒ»¸öÕûÊý£¨¼Ù¶¨ÓÃint±íʾ£©£¬Êä³ö¸ÃÕûÊýµÄ×Ö·û´®ÐÎʽ¡£²ÉÓÃÈçϺ¯ÊýÔÐÍ£º
void itoa ( int val, char* buf );
ÕâÀï¼Ù¶¨buf×ã¹»´óÒÔÈÝÄÉÈκÎintÀàÐÍÊýÖµµÄ×Ö·û´®¡£
Õâ¸öÎÊÌ⣬³õ¿´ºÃÏñûÓÐʲôÄѶȡ£Èç¹ûÊÇ0£¬¾ÍÖ±½ÓÊä³ö'0'£»Èç¹ûÊÇÕýÊý£¬¾Íͨ¹ýȡģ(%)ºÍÇóÉÌ(/)ÔËËã¿ÉÒÔÖðλȡµÃ¸ÃÕûÊýµÄÊ ......
ʵÏÖÒ»¸öÁ´±í£¬Íê³ÉÁ´±íµÄ²åÈ룬²éÕÒ£¬É¾³ý
typedef struct _FIFO_M{
void *pdata;
struct _FIFO_M *pNext;
}FIFO_M,* pFIFO_M;
typedef struct _FIFO{
pFIFO_M head;
pFIFO_M tail;
pFIFO_M pos;
int mcount;//½Úµã¸öÊý
int max_count;//½Úµã×î´ó¸öÊý¡£
}FIFO,* pFIFO;
......
/*
title£ºÔ¼Éª·òÎÊÌâµÄÑ»·Á´±í½â·¨
author£ºcoolsky600
date£º2010 04 22
notice£ºcÓïÑÔ ÃæÏò¹ý³Ì
*/
#include<stdio.h>
#include<stdlib.h>
#include<conio.h>
int num; //È«¾Ö±äÁ¿Î§È¦ÈËÊý
int out; & ......
/*
============================================================================
Name : test.c
Author : alf
Version :
Copyright : Your copyright notice
  ......