scripts for my gemini capsule
Diffstat (limited to 'chapterN.py')
| -rw-r--r-- | chapterN.py | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/chapterN.py b/chapterN.py new file mode 100644 index 0000000..0f11adf --- /dev/null +++ b/chapterN.py @@ -0,0 +1,12 @@ +import bible +import sys +def main(n, books): + for book in books: + cc = len(bible.find_book(book)[1]['verse_counts']) + if n <= cc: + return book + " " + str(n) + n = n - cc + + +if __name__ == '__main__': + print(main(int(sys.argv[1]), sys.argv[2:])) |