Posts by vitor Carvalho • 11 points
3 posts
-
0
votes0
answers158
viewsQ: persistent python Mysqldb connection
Because I have to keep opening and closing database connection memory consumption goes up? I wonder if I use an open connection always, I will have the advantage of decreasing memory consumption.…
-
1
votes1
answer96
viewsA: Filter a specific element within a stripe within another list
filaa = [(('vitor','5'), ('vitor', '4'))] def sadb(filadb,nome): l = [] if not (filadb): return None else: filadb_l = filadb[0] p = [(filadb_l.index(x), x.index(nome)) for x in filadb_l if nome in…
pythonanswered vitor Carvalho 11 -
0
votes1
answer96
viewsQ: Filter a specific element within a stripe within another list
I have a filter to find the index of a stripe inside another list (found in the author group Anderson Carlos) fila = [['vitor','5'], ['vitor', '4']] def sdb(filadb,nome,elemento): if not (filadb):…
pythonasked vitor Carvalho 11