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

python ²Ù×÷postgresqlµÄpgdb¿âµÄÎÊÌâ

ÈçºÎ»ñȡвåÈë¼Ç¼µÄij¸ö×ֶΡ£ÒÔusers±íΪÀý£¬±íÖÐÓÐ×Ö¶Îid£¨×ÔÔö£©£¬ÔÚ²åÈëÍê±ÏÖ®ºóÈçºÎ»ñÈ¡¸ÃÌõ¼Ç¼µÄid£¿
ÁíÄÄλÈÊÐÖÄܸøÎÒµãpgdbµÄ×ÊÁÏ£¬¿´ÁËÏÂÓ¢ÎĵÄ×ÊÁÏ£¬¸Ð¾õ²»ÊǺܺÃÀí½â....

ÒýÓÃ
û·ÖÈ¢²»µ½Ï±¸¾ Ä㻹¸Ò¸ø40£¡²»ÏëҪϱ¸¾À²£¡£¡

ÒªÊÇÄÜ°ïÎÒÕâ¸öÎÊÌâ¸ã¶¨£¬ÎÒ°Ñ·ÖÈ«É¢³öÈ¥£¬Ï±¸¾Ò²²»È¢ÁË¡£

ÎÒÊÇÀ´¶¥ÌùµÄ¡£¡£¡£

¶¥Æð


Ïà¹ØÎÊ´ð£º

python½Ì³ÌÖÐʹÓÃÔ´ÎļþµÄÎÊÌâ~~

ʹÓÃÔ´Îļþ

#!/usr/bin/python
# Filename : helloworld.py
print 'Hello World'

ÎÒÔõôҲ¿´²»¶®£¡Ö»ÊÇ×îºóÒ»ÐÐÎÒÖªµÀ~~Ç°ÃæÁ½ÐÐÊÇʲôÒâ˼ÄØ£¿
½Ì³ÌÉÏ˵Èç¹ûÄãʹÓÃIDLE£¬ÇëʹÓò˵ ......

[ÌáÎÊ]Python ÈçºÎºöÂÔ whitespace ¶ÁÈë

Ïñ C µÄ scanf() ÄÇÑù
±ÈÈç¶ÁÈë 1 2 3 a b c
ÿ´Î¶ÁÈëÒ»¸ö
ÏÂÃæÕâ¸öÓ¦¸ÃÊÇÄãÏëÒªµÄ°É£º
Python code:

>>> k = raw_input()
0 0123 ds dsl sd
>>> k
'0 0123 ds dsl sd'
>>> ......

pythonÕýÔò±í´ïʽ ÈçºÎÈ¡³öÒÔÏÂ×Ö·û´® ¶àл

s='aaa111aaa,bbb222,333ccc,444ddd444,555eee666,fff777ggg'
ÓÃÕýÔò±í´ïʽȡ³ö Ç°ºó×ÖĸÏàͬµÄÊý¾Ý ½á¹ûÈçÏÂ:
111 ddd
лл~
Python code:

import re
s='aaa111aaa,bbb222,333ccc,444ddd444,555eee666,ff ......

³ÏÕÐPython³ÌÐòÔ±²ÎÓë¼ÆËã»úÊé¼®³ö°æ

ÓźñµÄ¸å³ê£¬³ÏÕÐPython¼¼ÊõÈËÔ±²ÎÓë¸÷ÖÖ¼¼ÊõÊé¼®³ö°æ¡£ 
ͨ¹ý¸ÃÊé¼®£¬×÷Õß¿ÉÒԵõ½Èçϱ¨³ê£º 
1¡¢·áºñµÄ¸å³ê¡£ 
2¡¢Êé¼®Öø×÷µÄÊðÃûȨ¡£ 
3¡¢¶Ô×÷ÕߺÍÊé½øÐÐÐû´«£¬Ìá¸ß×÷ÕßÔÚ¼¼ÊõȦ×ÓÀ ......

pythonÈçºÎÉèÖÃCLOSE_WAIT״̬ռÓõĶ˿ÚÖØÓÃ

·¢ÏÖpython2.6
import httplib
conn=httplib.HTTPSConnection('x.x.x.x')
conn.request('','')
rd=conn.getresponse()
conn.close()
ÕâÑù½áÊøºó»á±ä³ÉCLOSE_WAIT״̬£¬ÎÒ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ