-1
I’m having trouble passing the name changed if it comes to a certain value CODE:
import threading
import time
from random import randint
def worker(message):
f = open('addresses_0.csv', 'r')
inicio = time.time()
contador = 0
for line in f:
if contador >= 100000:
lista = randint(0,9)
return
else:
separa = line.split(',')
dd = separa[0].strip().replace('"','')
numero = separa[1].strip().replace('"','')
print(lista)
aprovadas = open('lista'+lista+'.txt', 'a')
aprovadas.write('%s|%s\n' %(dd,numero))
aprovadas.close()
contador = contador+1
t = threading.Thread(target=worker,args=("thread sendo executada5",))
t.start()