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

ϸϸƷζPHP³ÌÐòµÄËã·¨

http://prato.bokele.com/?ArticleID=15302
    ÔÚÒ»°ãµÄÓ¦ÓÃÖУ¬PHPµÄ³ÌÐòÔ±»á±È½ÏÉÙµÄ×¢Òâµ½php³ÌÐòµÄϸ΢Ëã·¨¶ÔÐÔÄÜÓ°ÏìµÄÎÊÌ⣬µ«ÔÚ´¦ÀíһЩ±È½ÏÕ¼ÓÃ×ÊÔ´µÄ¶«Î÷µÄʱºò£¬Êʵ±µ÷ÕûËã·¨£¬»áÈóÌÐòµÄÐÔÄÜÕû±¶µÄÌá¸ß¡£
    Õ⼸Ì죬ÎÒÔÚÑо¿·Ö´ÊµÄËã·¨£¬Èç¹û²»Ô¤ÏÈÔØÈë´ÊµäµÄ»°£¬ÄÇÖÖÔËËãËٶȼòÖ±²Ò²»È̶ã¬Òò´ËÎÒ¿¼ÂÇÁËÔ¤ÏÈÔØÈë´ÊµäÔÚÒ»¸öÊý×éÖеÄ×ö·¨£¬ÎÒÊÖÉÏÓÐÒ»¸öÊ®¶àÍò´Ê»ãµÄ´Êµä£¬¿ªÊ¼µÄʱºò£¬ÓÃÕâÑùµÄ·½Ê½ÔØÈ룺
$fp = fopen(dirname(__FILE__)."/mydic.txt","r");
while($wd = fgets($fp,1024)){
 $ws = split("`",trim($wd));
 $m_dic[$ws[0]][$ws[1]] = $ws[2];
}
fclose($fp);
ÕâÑùÒ»²âÊÔ£¬·¢ÏÖ·ÖÎöʱºòÂýÍÌÍ̵ģ¬ºóÀ´Í¨¹ý¼ì²âÖ´ÐÐʱ¼ä²Å·¢ÏÖ£¬Ô­À´ÔØÈë´Êµä¾ÓÈ»ÓÃÁË 1.5 Ãë¶à£¬Ò²Äѹ֣¡
Êý¾Ý¸ñʽΪ£º
0ÁУºÇ°Á½´ÊµÄÆ´Òô£¬1ÁÐΪ£º´Ê£¬2ÁÐΪ£º´ÊµÄ³¤¶È
È磺
al`°ÂÁÖÆ¥¿ËÔ˶¯»á`14
al`°¢À­²®µÄÀÍÂ×˹`14
as`°£Èû¶í±ÈÑǸßÔ­`14
wp`ÍúÆÌ×âÊÛ`8  
wq`ÍøÇòÍõ×Ó`8  
wq`ÍâÆó·þÎñ`8
ÎÒÊÔһϲ»×÷ÈÎÔË×÷Ë㣬ֻ¶ÁÒ»±éÊý¾ÝÎļþ£º
$fp = fopen(dirname(__FILE__)."/mydic.txt","r");
while($wd = fgets($fp,24)){
 //$ws = split("`",trim($wd));
 //$m_dic[$ws[0]][$ws[1]] = $ws[2];
}
fclose($fp);
¾­²âÊÔÖ»ÓÃÁË£º0.18 Ã룬ÏÔÈ»ÕæÕýÕ¼ÓÃʱ¼äµÄ´úÂëÊÇ£º
$ws = split("`",trim($wd));
$m_dic[$ws[0]][$ws[1]] = $ws[2];
ÕâÁ½ÐдúÂ룬ÎÒ°ÑËü»»³ÉÕâ¸öÑù×Ó£º
$fp = fopen(dirname(__FILE__)."/mydic.txt","r");
while($wd = fgets($fp,24)){
 $WordEnd = strpos($wd,"`",3);
 $m_dic[$wd[0].$wd[1]][substr($wd,3,$WordEnd-3)] = ($WordEnd-3)*2;
}
fclose($fp);
ÕâÑù²âÊÔ¾ÍÖ»ÓÐ 0.7 Ãë¶à£¬È»ºó°Ñ´ÊµäÖдʵij¤¶ÈÈ¥³ý£¬±äΪ£º
$fp = fopen(dirname(__FILE__)."/mydic.txt","r");
while($wd = fgets($fp,18)){
 $WordEnd = strlen($wd)-2;// 2ÊÇ" "µÄ³¤¶È
 $m_dic[$wd[0].$wd[1]][substr($wd,3,$WordEnd-3)] = ($WordEnd-3)*2;
}
fclose($fp);
ÓÖ¿ìÁË 0.07 Ãë×óÓÒ£¬ËÙ¶ÈÔÚ 0.63 ÃëÖÐÅÇ»²£¬ÕâºÍÔ­À´µÄ 1.5 ÊǶà´óµÄ²î±ðѽ£¡


Ïà¹ØÎĵµ£º

PHPÖ®¸¸£º¿ª·ÅºÍ»¥¶¯ÊÇÍøÕ¾³É¹¦µÄ»ù´¡


PHPÖ®¸¸Rasmus LerdorfÔÚ»¥ÁªÍø¼¼Êõ¾«Ó¢ÂÛ̳Éϱíʾ£¬¿ª·¢ºÍ»¥¶¯ÊÇÍøÕ¾³É¹¦µÄ»ù´¡¡£
¡¡¡¡RasmusÒÔÑÇÂíÑ·ºÍÑÅ»¢¾ÙÀý£¬“ÕâЩÍøÕ¾Èç¹ûûÓÐÓû§µÄ»°£¬×öµÃÔÙƯÁÁҲʲô¶¼²»ÊÇ”¡£RasmusÈÏΪ£¬ÍøÕ¾Ò»¿ªÊ¼Ó뱨ֽһÑù£¬½ö½öÊÇ“µ¥Ïò½»Á÷”ÌṩÐÅÏ¢£¬ÓÐÈËÀ´¿´¼´¿É¡£
¡¡¡¡“µ«ÊǶÔÏÖ´úµÄÍøÕ¾À´Ëµ£¬ÕâÒÑ ......

PHP ×°ÉÏAPCÖ®ºóµÄÎÊÌâ:

Ô­Ìù:http://www.162cm.com/archives/433.html


Blog
ÁªÏµÎÒ
about
PHP ×°ÉÏAPCÖ®ºóµÄÎÊÌâ:
APCÓÉÓÚÄܹ»»º´æÎļþÉÏ´«½ø¶È,Òò´ËËãÊǽâ¾öÁËÒ»Ö±ÒÔÀ´À§ÄÓPHP¿ª·¢ÈËÔ±µÄÒ»¸öÀÏ´óÄÑ,ËùÒÔÎÒÒ²Ìرðϲ»¶ËûÁË¡£Èç¹û¶ÔphpʵÏÖÎļþÉÏ´«½ø¶ÈÌõÓÐÀ§ ÄÑ£¬¿ÉÒÔ¿´ÕâÀï
¡£
²»¹ý½ñÌì·¢ÏÖ,APCÐû³ÆµÄ¼ÓËÙ¹¦ÄÜ,ÆäʵҲÊÇÒ»ÖÖ»º´æ ......

ÈçºÎÀûÓÃAPC»º³åPHP½Å±¾À´Ìá¸ß·þÎñÆ÷ÐÔÄÜ

Ô­Ìù£ºhttp://www.phpchina.com/html/05/n-2005.html
ÈçºÎÀûÓÃAPC»º³åPHP½Å±¾À´Ìá¸ß·þÎñÆ÷ÐÔÄÜ
·¢²¼Ê±¼ä:2006-10-16 09:01 ¡¡¡¡×÷Õß: bulider.com.cn ¡¡¡¡ÐÅÏ¢À´Ô´:
bulider.com.cn¡¡¡¡[ÎÒÀ´ËµÁ½¾ä
(3765
Ìõ)]
ѧ»áÔõÑùÀûÓÃAPC
»º³åPHP
½Å±¾À´Ìá¸ß·þÎñÆ÷ÐÔÄÜ¡£
Ï£
ÍûÄúµÄWeb·þÎñÆ÷·¢»Ó×î´óµÄÐÔÄÜÂð£¿Èç¹ûÄúÕýÔÚÊ ......

Apache + PHP + MySql °²×°


ËùÐèÈí¼þ£¨×¢Òâ°æ±¾£¡£©£º
Apache2.2.3 
PHP5.1.5 
MySQL5.0.24
ÕâÈý¸öÈí¼þ¶¼ÊÇÃâ·ÑµÄ£¬¿É´Ó¹ÙÍøÉÏÏÂÔØ£¬Ä¿Ç°ÎÒËùÓеÄÈí¼þÃûΪ£º
apache_2.2.3-win32-x86-no_ssl.msi 
mysql-5.0.24-win32.zip 
php-5.1.5-Win32.zip
»ùÓÚwindows²Ù×÷ϵͳ£¬ÔÚWindows XPÏ°²×°Ê¹Óãº
1¡¢°²×°¹ý³Ì£º  ......

PHP³Á˼¼֮¹¤×÷Ä£ÐÍ

PHP³Á˼¼
¡¡¡¡¹¤×÷Ä£ÐÍ
¡¡¡¡PHPµÄ¹¤×÷Ä£Ðͷdz£ÌØÊâ¡£´ÓijÖ̶ֳÈÉÏ˵£¬PHPºÍASP¡¢ASP.NET¡¢JSP/ServletµÈÁ÷ÐеÄWeb¼¼Êõ£¬ÓÐ×ű¾ÖÊÉϵÄÇø±ð¡£
¡¡¡¡ÒÔJavaΪÀý£¬JavaÔÚWebÓ¦ÓÃÁìÓò£¬ÓÐÁ½ÖÖ¼¼Êõ£ºJava ServletºÍJSP£¨Java Server Page£©¡£Java ServletÊÇÒ»ÖÖÌØÊâÀàÐ͵ÄJava³ÌÐò£¬Ëüͨ¹ýʵÏÖÏà¹Ø½Ó¿Ú£¬´¦ÀíWeb·þÎñÆ÷·¢Ë͹ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ