This commit is contained in:
Michał Jurgo 2016-11-03 08:50:42 +01:00
commit d74b601c3c
1 changed files with 27 additions and 0 deletions

27
projektkck.py Normal file
View File

@ -0,0 +1,27 @@
dotsfile = open('dots.txt', 'r+')
wantedfile = open('wanted.txt', 'r+')
def commandToArray(sentence):
print(sentence)
for line in dotsfile:
line=line.strip('\n')
sentence = sentence.replace(line, "")
print(sentence)
found = []
for line in wantedfile:
line=line.strip('\n')
if sentence.find(line) >= 0:
found.append(line)
if found:
return found
return 1
def arrayToShit(array):
print("I have found words: " + " ".join(array))
return 0
array = commandToArray("HEHEHEHHEHEHEHEHELLO, I want you to give me an eye!?!!")
if array!=1:
arrayToShit(array)