Apr-28-2018, 03:42 AM
I need to find way to extract numbers from a string but the following not quick right. I need to get [98.15, 0.97, 1.00, 118506]
import re a = 'C.1 str 98.15 +0.97increase +1.00%increase 118,506 04/27/18' re.findall(r"([\d.]*\d+)", a)['.1', '98.15', '0.97', '1.00', '118', '506', '04', '27', '18']