LaTeX Change chapter numbering into words instead of numbers in Latex

Qatawna blitz
Messages
3
Reaction score
0
TL;DR
I need to write chapter names as (Chapter One, Chapter Two,...) instead of (Chapter 1, Chapter 2, ...), how can I do that?
I need to write chapter names as (Chapter One, Chapter Two,...) instead of (Chapter 1, Chapter 2, ...), how can I do that?
 
Physics news on Phys.org
One common technique (in C and other languages) is to define an array with text elements that correspond to the index number into the array. That way you can convert from the number to the word.

https://opentextbc.ca/pressbooks/chapter/arrays/
 
Here's a simple illustration in Python:
Python:
chapters5 = ["Zero", "One", "Two", "Three", "Four", "Five"]
print(chapters5)
for index in range(1,6):
    print("Chapter", chapters5[index])

Output:
['Zero', 'One', 'Two', 'Three', 'Four', 'Five']
Chapter One
Chapter Two
Chapter Three
Chapter Four
Chapter Five

Process finished with exit code 0
 

Similar threads

  • · Replies 2 ·
Replies
2
Views
2K
  • · Replies 4 ·
Replies
4
Views
2K
  • · Replies 12 ·
Replies
12
Views
3K
  • · Replies 1 ·
Replies
1
Views
3K
  • · Replies 2 ·
Replies
2
Views
2K
  • · Replies 1 ·
Replies
1
Views
4K
  • · Replies 4 ·
Replies
4
Views
3K
  • · Replies 3 ·
Replies
3
Views
2K
  • · Replies 8 ·
Replies
8
Views
3K
Replies
2
Views
655