Commas in numbers!
This commit is contained in:
parent
cdb9187809
commit
7a025bb18d
@ -73,7 +73,7 @@ def main():
|
||||
chapter_status = status_by_chapter.get(chapter_number)
|
||||
|
||||
print(
|
||||
'chapter {}: {} words{}'.format(
|
||||
'chapter {}: {:,} words{}'.format(
|
||||
chapter_number,
|
||||
chapter_word_count,
|
||||
' ({})'.format(chapter_status) if chapter_status else '',
|
||||
@ -86,12 +86,12 @@ def main():
|
||||
if act_number is None:
|
||||
continue
|
||||
|
||||
print('act {}: {} words (~{}%)'.format(act_number, act_word_count, act_word_count * 100 // total_word_count))
|
||||
print('act {}: {:,} words (~{}%)'.format(act_number, act_word_count, act_word_count * 100 // total_word_count))
|
||||
|
||||
for status, status_word_count in word_count_by_status.items():
|
||||
print('{}: {} words (~{}%)'.format(status, status_word_count, status_word_count * 100 // total_word_count))
|
||||
print('{}: {:,} words (~{}%)'.format(status, status_word_count, status_word_count * 100 // total_word_count))
|
||||
|
||||
print('total: {} words'.format(total_word_count))
|
||||
print('total: {:,} words'.format(total_word_count))
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
|
Loading…
x
Reference in New Issue
Block a user