正則表達式,如何過濾[email protected]:
到[email protected]
沒有:
?正則表達式,如何過濾任何@任何:任何@任何沒有'':''?
我需要一個Python的正則表達式代碼,用來單詞列表更新2.7,我想過濾任何郵件即:
[email protected]:
[email protected]:
最終結果:
[email protected]
[email protected]
我有以下的正則表達式 -
(^[[email protected]#$%^&*.,?][email protected][a-zA-Z0-9-]+\.[a-zA-Z0-9-.]+$)
哪個過濾器[email protected]
[email protected]
[email protected]
,而不是
[email protected]:
是':'總是結束? – itzMEonTV
如果它始終位於結果字符串的末尾,爲什麼不移除它(或將其替換爲空字符串)? – Isxek
您不需要正則表達式,只需使用rstrip作爲@Padraic坎寧安建議如下。 – suvayu