Answer the question
In order to leave comments, you need to log in
"Program" for writing and showing passwords in Python, how to fix errors?
Hello.
Task: make a password manager so that you can write and read passwords from a file.
Passwords are in txt file like this:
YaPythoner
vk - Nagibator228
discord - Nagibator1337
code: https://pastebin.com/BsXCZZEy
Gives errors:
IndexError: list assignment index out of range
TypeError: list indices must be integers or slices, not str
THANKS !
Answer the question
In order to leave comments, you need to log in
lines = f.readlines()
lines[int(numb)] = name + ' - ' + parol + '\n'
well, translate the mistakes and everything will become clear
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question