CµÄscanf()
ºÃ¾ÃûÉÏÀ´ÁË...Óеã¶Ô²»Æð×Ô¼ºµÄÁ¼ÐÄ...
»°ËµÕâ¶Îʱ¼ä¿ì¸øÕâ¸öº¯Êý¸ãËÀÁË...
ÎÒÕÒÕÒ...ÎÒÕÒÎÒÕÒ...ÎÒ¾ÍÊÇÒª°ÑËü¸ø¸ãÃ÷°×ÁË...
»°ËµÇ°¶Îʱ¼äÄǸöËÀÈËËÄÔòÔËËãÒ²°Ñ×Ô¼º¸ãµÃ°ëËÀÁË...¶î...ÏÖÔÚ»¹ÔÚÍ£¹¤×´Ì¬...ÔÎËÀ....
ÔÙ˵scanf(),ÉÏÍøÊÇ¿ÉÒÔÕÒµ½Ð©¶«Î÷....µ«ÊǶ¼²»ÔõôÃ÷°×...´òËã×Ô¼º¸ãÃ÷°×ÁËÔÙÉÏÀ´Ð´¸öÏêϸµãµÄ°É...
ÎÒÒ»¶¨Òª°ÑËü¸øÕÒ³öÀ´....ÏÂ×ÊÔ´È¥...
×ÜËã·ÁËÏÂCSDNÕÒµ½ÁË...ÓÐÒâ˼...¹ûÈ»ºÜ¿ì¾Í½â¾öÁË...²»¹ýÒÉ»ó»¹Ã»ÍêÈ«½â¾ö....ÔÙÈ¥¿´¶àµãÕâ¸öº¯ÊýµÄÌû×Ó....
PS½ñÍíµÄ´úÂë:
printf("?\t");
scanf("%f",&num);
while(num != -1)
{
if(num == -1)
{
break;
}
else
{
printf("?\t");
scanf("%f",&num);
average += num;
count = count + 1;
}
}
ÔÀ´ÊÇ×Ô¼ºÔÏÈÔÚscanf()ÀïÃæµÄ%fºó¼ÓÁ˻سµ....¸ÕÈ¥µôºó¾Í冇ÎÊÌâÁË...»¹Ã»È¥¿´Ïêϸ˵·¨...²»¹ýÒѾÓеã²ÂÏëÁË....
¿ÉÄÜÊÇscanf()ÔÚÊäÈëÁ÷Àï¾Í¼ÓÉÏÁËÒ»¸ö»Ø³µ...ËùÒÔʹµ½Ã¿´Î¼ÓÈë»Ø³µÊ±,ÊäÈëÁ÷×Ü»á¶Á¼ÓÒ»¸ö»Ø³µ...¶øÇÒ»¹°Ñµ±Ç°µÄÊäÈëÍϵ½ÏÂÒ»´ÎÊä³ö...Óлº³åµÄ¿ÉÒÉ...ÏÖÔÚ¾ÍÔÙÈ¥¿´Ïêϸ...¹þ¹þ¹þ
²¹ÉÏÔÚCSDNÀï¿´µ½µÄ²¿·ÖÄÚÈÝ:
scanf("%d%d%d\n",&a,&b,&c);ÐèÒªÊäÈëËĸöÕûÊý²ÅÄܽáÊø.
¼ÙÉèÂ¥Ö÷µÄÊäÈëΪ: 1 2 3
4;
Õâʱ²¢Ã»ÓÐÁ¢¼´´æ´¢µ½±äÁ¿À¶øÊÇÏȵ½¼üÅÌ»º³åÇøÀï¡£
È»ºóscanf¿ªÊ¼Æ¥Å乤×÷¡£µÚÒ»¸ö%dºöÂÔÇ°ÃæµÄ¿Õ×Ö·û£¬¿ªÊ¼Æ¥ÅäÊý×Ö1,
µ±Ëü³¢ÊÔÆ¥ÅäÏÂÒ»¸ö×Ö·û(Ϊ¿Õ¸ñ)µÄʱºò£¬·¢ÏÖËü²»ÊÇÊý×Ö£¬Æ¥Åä½áÊø£¬scanf½«¿Õ¸ñ·Å»Ø¼üÅÌ»º³åÇø.aµÄֵΪ1.´Ëºó£¬¼üÅÌ»º³åÇøÀïµÄÄÚÈÝΪ" 2 3
4&q
Ïà¹ØÎĵµ£º
1.ʱ¼ä±íʾ
ÔÚ³ÌÐòµ±ÖÐ,ÎÒÃǾ³£ÒªÊä³öϵͳµ±Ç°µÄʱ¼ä,±ÈÈçÎÒÃÇʹÓÃdateÃüÁîµÄÊä³ö½á¹û.Õâ¸öʱºòÎÒÃÇ¿ÉÒÔʹÓÃÏÂÃæÁ½¸öº¯Êý:
#include <sys/time.h>
time_t time(time_t *tloc);
char *ctime(const time_t *clock);
timeº¯Êý·µ»Ø´Ó1970Äê1ÔÂ1ÈÕ0 ......
Ñ¡Á½¸ö±È½ÏÓдú±íÐԵĺ¯Êý
Ê×ÏÈÏÂÔØ°²×°sdk£¬½«ÆäÖеÄsde.dll,pe.dllºÍsg.dll¿½±´¹ýÀ´
ʹÓÃÈçϵĴúÂ룬ָ¶¨dllºóÖ±½Óµ÷ÓÃÆäÖеĺ¯Êý£¬
/// <summary>
/// Sets the value for a small integer column.
/// </summary>
[DllImport(".\\sde91.dll", SetLastError = true, ......
ÔÎÄÁ´½ÓµØÖ·£ºhttp://hi.baidu.com/erfolgreich/blog/item/ce94dbad02c0c3f7faed5010.html
c ÓïÑÔʵÏÖ24λbmpͼƬ¼ÓÔØ£¬¶Áд£¬·Å´óËõС
¿ÉÓà microsoft visual c++ 6.0 ½¨Á¢Win32 Console Application ¹¤³Ì£¬Ìí¼ÓÈçÏÂ.cpp
2010-04-30 10:24
·¢ÏֺöàÈËÍøÉϲéÕÒc ÓïÑÔ°æ±¾µÄbmpͼÏñ¶ÁÈ¡£¬±£´æ£¬·Å´ó£¬ËõС³ÌÐò£¬ºÜÄÑÕÒµ ......
GDB
ÊÇ
GNU
¿ªÔ´×éÖ¯·¢²¼µÄÒ»¸öÇ¿´óµÄ
UNIX
ϵijÌÐòµ÷ÊÔ¹¤¾ß¡£»òÐí£¬¸÷λ±È½Ïϲ»¶ÄÇÖÖͼÐνçÃ淽ʽµÄ£¬Ïñ
VC
¡¢
BCB
µÈ
IDE
µÄµ÷ÊÔ£¬µ«Èç¹ûÄãÊÇÔÚ
UNIX
ƽ̨ÏÂ×öÈí¼þ£¬Äã»á·¢ÏÖ
GDB
Õâ¸öµ÷ÊÔ¹¤¾ßÓбÈ
VC
¡¢
BCB
µÄͼÐλ¯µ÷ÊÔÆ÷¸üÇ¿´óµÄ¹¦ÄÜ¡£Ëùν
“
´çÓÐËù³¤£¬³ßÓÐËù¶Ì
”
¾ÍÊÇÕâ¸öµÀÀí ......
clock()·µ»Øclock_tÀàÐÍ£»
ÔÚtime.hÍ·ÎļþÖУ¬¶¨ÒåÁË typedef long clock_t
clock()ÊÇÓÃÀ´¼ÆËãÁ½¸öʱ¼äµãÖ®¼äµÄʱ¼ä¼ä¸ô¡£ÈçϳÌÐò£º
#include <stdio.h>
int main()
{
int i = 0;
clock_t start_time, end_time;
start_time = clock(); //¿ªÊ¼¼Æʱ, start_time = 0
while( ......