Why is this first loop running only once?
I only know that this line is what causes this:
unchecked = text.pop(0)
how to fix it?
def search(text):
text=list(text)
pat=[]
history=[]
for char in text:
print(char)
negative=[]
pat.append(char)
for i in range(int(len(text)/len(pat))):
for char in pat:
unchecked = text.pop(0)
if unchecked == char:
history.append(unchecked)