so the following code is meant to test every possible combination of characters untill it finds the one you typed, however at one point it says list index out of range, how do I fix this?
password = input()
chars = "abcdefghijklmnopqrstuvwxyz1234567890"
guess = ""
chars = list(chars)
chararray = []
for l in password:
chararray.append(0)
while guess != password:
guess = ""
for element in chararray:
guess = guess + chars[element]
chararray[len(chararray) - 1] += 1
i = 0
while i < len(chararray) - 1:
if i + 1 > len(chars):
chars[i + 1] = 0
chars[i] += 1
i += 1
print(guess)
the index out of range part is in the part that says
guess = guess + chars[element]