Upload files to ''
This commit is contained in:
parent
d74b601c3c
commit
d65ae698c9
@ -1,13 +1,13 @@
|
||||
dotsfile = open('dots.txt', 'r+')
|
||||
wantedfile = open('wanted.txt', 'r+')
|
||||
dotsfile = open('dots.txt', 'r')
|
||||
wantedfile = open('wanted.txt', 'r')
|
||||
|
||||
def commandToArray(sentence):
|
||||
print(sentence)
|
||||
def commandStrip(sentence):
|
||||
for line in dotsfile:
|
||||
line=line.strip('\n')
|
||||
sentence = sentence.replace(line, "")
|
||||
print(sentence)
|
||||
return sentence
|
||||
|
||||
def searchKeyWords(sentence):
|
||||
found = []
|
||||
for line in wantedfile:
|
||||
line=line.strip('\n')
|
||||
@ -18,10 +18,10 @@ def commandToArray(sentence):
|
||||
return found
|
||||
return 1
|
||||
|
||||
def arrayToShit(array):
|
||||
print("I have found words: " + " ".join(array))
|
||||
return 0
|
||||
temp = commandStrip("Guten tag, ich want you to pick up big red triangle.")
|
||||
temp = searchKeyWords(temp)
|
||||
if temp!=1:
|
||||
print("I have found words: " + " ".join(temp))
|
||||
|
||||
array = commandToArray("HEHEHEHHEHEHEHEHELLO, I want you to give me an eye!?!!")
|
||||
if array!=1:
|
||||
arrayToShit(array)
|
||||
dotsfile.close()
|
||||
wantedfile.close()
|
Loading…
Reference in New Issue
Block a user