Optimisation de "resolv_bl()"
This commit is contained in:
parent
25669da340
commit
332c571b71
@ -96,12 +96,7 @@ def resolv_bl(liste, lettres):
|
||||
for lettre in lettres:
|
||||
if lettre in mot:
|
||||
MotsSuppr.append(mot)
|
||||
for mot in MotsSuppr:
|
||||
try:
|
||||
liste.pop(liste.index(mot))
|
||||
except ValueError:
|
||||
pass
|
||||
return liste
|
||||
return [mot for mot in liste if not mot in MotsSuppr]
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
|
Loading…
Reference in New Issue
Block a user