In the line, you can replace any character, for example ,, for example:
s = "Hi, I'm a string"
s_new = s.replace(",", "")
, , , , . , . - :
for word in split:
n = float(word.replace(",", ""))
with:
with open(fileName, 'r') as f:
for line in f:
string_wo_commas = line.replace(",", "")
- .