Dec-12-2019, 02:30 PM
That's not a good solution, you don't want to modify a list while you are looping over it.
If you haven't done list comprehensions, you can reconstruct a list with a for loop:
If you haven't done list comprehensions, you can reconstruct a list with a for loop:
new_pass = [] for site_pass in passwords: if site_pass[0] != websitetodelete: new_pass.append(site_pass) passwords = new_pass
Craig "Ichabod" O'Brien - xenomind.com
I wish you happiness.
Recommended Tutorials: BBCode, functions, classes, text adventures
I wish you happiness.
Recommended Tutorials: BBCode, functions, classes, text adventures