Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
Download
7550 views
ubuntu2004
1
from parse_bible import bible, books
2
3
word_to_find = raw_input ("Enter a word you wish to find the first occurrence of: ")
4
5
found = False
6
7
for book in books:
8
chapter_num = 1
9
for chapter in bible[book]:
10
verse_num = 1
11
for verse in chapter:
12
if word_to_find in verse and not found:
13
print "First mention of {0} is in {1} {2}:{3}".format(word_to_find, book, chapter_num, verse_num)
14
found = True
15
16
verse_num = verse_num + 1
17
18
chapter_num = chapter_num + 1
19