Browse Source

added some comments to poetry.py for clarity

master
crunk 5 years ago
parent
commit
30f50360b0
  1. 3
      poetry.py

3
poetry.py

@ -18,10 +18,11 @@ def poetry():
mediumwords.append(word)
else:
longwords.append(word)
print(shortwords)
# Pick one from each list of words
line = (random.choice(shortwords),
random.choice(mediumwords),
random.choice(longwords))
# Join into a sentence
result = " ".join(line)
return result

Loading…
Cancel
Save