fork(1) download
  1. import re
  2.  
  3. tempprices = "0.0, 82.00.0,...., 82.0\n"
  4. cells = tempprices.split(',')
  5. temp =[]
  6. for t in cells:
  7. mObj = re.search(r'-?\d+\.\d{1,2}', t)
  8. if mObj:
  9. temp.append(float(mObj.group()))
  10. print(temp)
  11.  
Success #stdin #stdout 0.01s 9016KB
stdin
Standard input is empty
stdout
[0.0, 82.0, 82.0]