在线观看不卡亚洲电影_亚洲妓女99综合网_91青青青亚洲娱乐在线观看_日韩无码高清综合久久

鍍金池/ 問答/Python/ python正則的使用詳情。

python正則的使用詳情。

00:00:00    2982199073774412    [360安全衛(wèi)士]    8 3    download.it.com.cn/softweb/software/firewall/antivirus/20067/17938.html
00:00:00    07594220010824798    [哄搶救災(zāi)物資]    1 1    news.21cn.com/social/daqian/2008/05/29/4777194_1.shtml
00:00:00    5228056822071097    [75810部隊(duì)]    14 5    www.greatoo.com/greatoo_cn/list.asp?link_id=276&title=%BE%DE%C2%D6%D0%C2%CE%C5
00:00:00    6140463203615646    [繩藝]    62 36    www.jd-cd.com/jd_opus/xx/200607/706.html
00:00:00    8561366108033201    [汶川地震原因]    3 2    www.big38.net/
00:00:00    23908140386148713    [莫衷一是的意思]    1 2    www.chinabaike.com/article/81/82/110/2007/2007020724490.html
00:00:00    1797943298449139    [星夢(mèng)緣全集在線觀看]    8 5    www.6wei.net/dianshiju/????\xa1\xe9|????do=index
00:00:00    00717725924582846    [閃字吧]    1 2    www.shanziba.com/
00:00:00    41416219018952116    [霍震霆與朱玲玲照片]    2 6    bbs.gouzai.cn/thread-698736.html
00:00:00    9975666857142764    [電腦創(chuàng)業(yè)]    2 2    ks.cn.yahoo.com/question/1307120203719.html
00:00:00    21603374619077448    [111aa圖片]    1 6    www.fotolog.com.cn/tags/aa111
00:00:00    7423866288265172    [豆腐的制成]    3 13    ks.cn.yahoo.com/question/1406051201894.html
00:00:00    0616877776407358    [tudou.com+禁播電影]    2 9    topic.bindou.com/1487/
00:00:00    3933365481995287    [最佳受孕時(shí)間]    6 3    ks.cn.yahoo.com/question/1407051001276.html
00:00:00    8242389147671512    [捷克民歌土風(fēng)舞++教案]    2 3    shwamlys.blog.sohu.com/76558184.html

對(duì)于這段數(shù)據(jù),我按行讀取。
但是只需要第2,3,4列的數(shù)據(jù)
每列之間是TAB鍵 而且第四行中間是空格鍵
該怎么寫正則表達(dá)式呢?
求大佬指教!

回答
編輯回答
影魅
import re

with open('1.txt', 'r') as r:
    result = [re.split('\s+', i)[1:4] for i in r.readlines()]

print(result)
2017年6月29日 11:21