【发布时间】:2020-10-19 02:42:27
【问题描述】:
<div class="bb-fl" style="background:Tomato;width:0.63px" title="10"></div>,
<div class="bb-fl" style="background:SkyBlue;width:0.19px" title="3"></div>,
<div class="bb-fl" style="background:Tomato;width:1.14px" title="18"></div>,
<div class="bb-fl" style="background:SkyBlue;width:0.19px" title="3"></div>,
<div class="bb-fl" style="background:Tomato;width:1.52px" title="24"></div>,
我目前有一个列表中的上述 html 代码。我希望使用 python,以便它可以输出以下内容,然后附加到列表中:
10
3
18
3
24
【问题讨论】:
-
你尝试过做什么?
-
@adrianp 我尝试使用正则表达式来清理文本。我尝试使用正则表达式删除文本
-
如果这些解决方案中的任何一个解决了您的问题,请接受它。
标签: python html regex web-scraping text