Full Code of Apress/beginning-cpp20 for AI

main 8e99a6cee493 cached
1522 files
1.7 MB
534.9k tokens
2193 symbols
1 requests
Download .txt
Showing preview only (2,110K chars total). Download the full file or copy to clipboard to get everything.
Repository: Apress/beginning-cpp20
Branch: main
Commit: 8e99a6cee493
Files: 1522
Total size: 1.7 MB

Directory structure:
gitextract_vz438qf9/

├── .gitmodules
├── Contributing.md
├── Examples/
│   ├── Modules/
│   │   ├── Chapter 01/
│   │   │   ├── Ex1_01.cpp
│   │   │   └── Ex1_02.cpp
│   │   ├── Chapter 02/
│   │   │   ├── Ex2_01.cpp
│   │   │   ├── Ex2_02.cpp
│   │   │   ├── Ex2_03.cpp
│   │   │   ├── Ex2_03A.cpp
│   │   │   ├── Ex2_03B.cpp
│   │   │   ├── Ex2_03C.cpp
│   │   │   ├── Ex2_03D.cpp
│   │   │   ├── Ex2_04.cpp
│   │   │   ├── Ex2_05.cpp
│   │   │   ├── Ex2_06.cpp
│   │   │   ├── Ex2_06B.cpp
│   │   │   └── Ex2_07.cpp
│   │   ├── Chapter 03/
│   │   │   ├── Ex3_01.cpp
│   │   │   ├── Ex3_02.cpp
│   │   │   └── Ex3_03.cpp
│   │   ├── Chapter 04/
│   │   │   ├── Ex4_01.cpp
│   │   │   ├── Ex4_01A.cpp
│   │   │   ├── Ex4_02.cpp
│   │   │   ├── Ex4_02A.cpp
│   │   │   ├── Ex4_03.cpp
│   │   │   ├── Ex4_04.cpp
│   │   │   ├── Ex4_04A.cpp
│   │   │   ├── Ex4_05.cpp
│   │   │   ├── Ex4_06.cpp
│   │   │   ├── Ex4_07.cpp
│   │   │   ├── Ex4_08.cpp
│   │   │   ├── Ex4_09.cpp
│   │   │   └── Ex4_09A.cpp
│   │   ├── Chapter 05/
│   │   │   ├── Ex5_01.cpp
│   │   │   ├── Ex5_02.cpp
│   │   │   ├── Ex5_03.cpp
│   │   │   ├── Ex5_03A.cpp
│   │   │   ├── Ex5_04.cpp
│   │   │   ├── Ex5_04A.cpp
│   │   │   ├── Ex5_05.cpp
│   │   │   ├── Ex5_06.cpp
│   │   │   ├── Ex5_07.cpp
│   │   │   ├── Ex5_07A.cpp
│   │   │   ├── Ex5_08.cpp
│   │   │   ├── Ex5_09.cpp
│   │   │   ├── Ex5_10.cpp
│   │   │   ├── Ex5_11.cpp
│   │   │   ├── Ex5_12.cpp
│   │   │   ├── Ex5_12A.cpp
│   │   │   ├── Ex5_13.cpp
│   │   │   ├── Ex5_14.cpp
│   │   │   └── Ex5_15.cpp
│   │   ├── Chapter 06/
│   │   │   ├── Ex6_01.cpp
│   │   │   ├── Ex6_02.cpp
│   │   │   ├── Ex6_03.cpp
│   │   │   ├── Ex6_04.cpp
│   │   │   ├── Ex6_05.cpp
│   │   │   ├── Ex6_06.cpp
│   │   │   └── Ex6_07.cpp
│   │   ├── Chapter 08/
│   │   │   ├── Ex8_01.cpp
│   │   │   ├── Ex8_02.cpp
│   │   │   ├── Ex8_03.cpp
│   │   │   ├── Ex8_04.cpp
│   │   │   ├── Ex8_05.cpp
│   │   │   ├── Ex8_05A.cpp
│   │   │   ├── Ex8_06.cpp
│   │   │   ├── Ex8_06A.cpp
│   │   │   ├── Ex8_07.cpp
│   │   │   ├── Ex8_08.cpp
│   │   │   ├── Ex8_09A.cpp
│   │   │   ├── Ex8_09B.cpp
│   │   │   ├── Ex8_09C.cpp
│   │   │   ├── Ex8_10.cpp
│   │   │   ├── Ex8_11.cpp
│   │   │   ├── Ex8_12.cpp
│   │   │   ├── Ex8_13.cpp
│   │   │   ├── Ex8_14.cpp
│   │   │   ├── Ex8_15.cpp
│   │   │   ├── Ex8_16.cpp
│   │   │   └── Ex8_17.cpp
│   │   ├── Chapter 09/
│   │   │   ├── Ex9_01.cpp
│   │   │   ├── Ex9_02.cpp
│   │   │   ├── Ex9_03.cpp
│   │   │   └── Ex9_03A.cpp
│   │   ├── Chapter 10/
│   │   │   ├── Ex10_01.cpp
│   │   │   ├── Ex10_02.cpp
│   │   │   ├── Ex10_03.cpp
│   │   │   ├── Ex10_03A.cpp
│   │   │   └── Ex10_04.cpp
│   │   ├── Chapter 11/
│   │   │   ├── Ex11_01/
│   │   │   │   ├── Ex11_01.cpp
│   │   │   │   └── math.cppm
│   │   │   ├── Ex11_01A/
│   │   │   │   ├── Ex11_01A.cpp
│   │   │   │   └── math.cppm
│   │   │   ├── Ex11_01B/
│   │   │   │   ├── Ex11_01B.cpp
│   │   │   │   └── math.cppm
│   │   │   ├── Ex11_02/
│   │   │   │   ├── Ex11_02.cpp
│   │   │   │   ├── from_roman.cpp
│   │   │   │   ├── roman.cppm
│   │   │   │   └── to_roman.cpp
│   │   │   ├── Ex11_03/
│   │   │   │   ├── Ex11_03.cpp
│   │   │   │   ├── from_roman.cpp
│   │   │   │   ├── roman.cppm
│   │   │   │   └── to_roman.cpp
│   │   │   ├── Ex11_04/
│   │   │   │   ├── Ex11_04.cpp
│   │   │   │   ├── from_roman.cpp
│   │   │   │   ├── roman-internals.cpp
│   │   │   │   ├── roman.cppm
│   │   │   │   └── to_roman.cpp
│   │   │   ├── Ex11_05/
│   │   │   │   ├── Ex11_05.cpp
│   │   │   │   ├── from_roman.cpp
│   │   │   │   ├── roman-from.cppm
│   │   │   │   ├── roman-internals.cpp
│   │   │   │   ├── roman-to.cppm
│   │   │   │   └── roman.cppm
│   │   │   ├── Ex11_06/
│   │   │   │   └── Ex11_06.cpp
│   │   │   ├── Ex11_06A/
│   │   │   │   ├── Ex11_06A.cpp
│   │   │   │   └── squaring.cppm
│   │   │   ├── Ex11_06B/
│   │   │   │   ├── Ex11_06B.cpp
│   │   │   │   └── squaring.cppm
│   │   │   ├── Ex11_07/
│   │   │   │   ├── Ex11_07.cpp
│   │   │   │   ├── math.cpp
│   │   │   │   └── math.cppm
│   │   │   └── Ex11_08/
│   │   │       ├── Ex11_08.cpp
│   │   │       └── squaring.cppm
│   │   ├── Chapter 12/
│   │   │   ├── Ex12_01/
│   │   │   │   └── Ex12_01.cpp
│   │   │   ├── Ex12_01A/
│   │   │   │   └── Ex12_01A.cpp
│   │   │   ├── Ex12_02/
│   │   │   │   └── Ex12_02.cpp
│   │   │   ├── Ex12_03/
│   │   │   │   └── Ex12_03.cpp
│   │   │   ├── Ex12_04/
│   │   │   │   └── Ex12_04.cpp
│   │   │   ├── Ex12_05/
│   │   │   │   └── Ex12_05.cpp
│   │   │   ├── Ex12_05A/
│   │   │   │   └── Ex12_05A.cpp
│   │   │   ├── Ex12_06/
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex12_06.cpp
│   │   │   ├── Ex12_06A/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex12_06A.cpp
│   │   │   ├── Ex12_06B/
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex12_06B.cpp
│   │   │   ├── Ex12_07/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex12_07.cpp
│   │   │   ├── Ex12_08/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex12_08.cpp
│   │   │   ├── Ex12_09/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex12_09.cpp
│   │   │   ├── Ex12_10/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex12_10.cpp
│   │   │   ├── Ex12_11/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex12_11.cpp
│   │   │   ├── Ex12_12/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex12_12.cpp
│   │   │   ├── Ex12_13/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex12_13.cpp
│   │   │   ├── Ex12_14/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex12_14.cpp
│   │   │   ├── Ex12_15/
│   │   │   │   ├── CylindricalBox.cpp
│   │   │   │   ├── CylindricalBox.cppm
│   │   │   │   └── Ex12_15.cpp
│   │   │   ├── Ex12_16/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex12_16.cpp
│   │   │   ├── Ex12_17/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Ex12_17.cpp
│   │   │   │   ├── Package.cpp
│   │   │   │   ├── RandomBoxes.cppm
│   │   │   │   ├── SharedBox.cppm
│   │   │   │   ├── Truckload.cpp
│   │   │   │   └── Truckload.cppm
│   │   │   └── Ex12_18/
│   │   │       ├── Box.cppm
│   │   │       ├── Ex12_18.cpp
│   │   │       ├── RandomBoxes.cppm
│   │   │       ├── Truckload.cpp
│   │   │       └── Truckload.cppm
│   │   ├── Chapter 13/
│   │   │   ├── Ex13_01/
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex13_01.cpp
│   │   │   ├── Ex13_02/
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex13_02.cpp
│   │   │   ├── Ex13_03/
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex13_03.cpp
│   │   │   ├── Ex13_03A/
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex13_03A.cpp
│   │   │   ├── Ex13_04/
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex13_04.cpp
│   │   │   ├── Ex13_05/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex13_05.cpp
│   │   │   ├── Ex13_06/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex13_06.cpp
│   │   │   ├── Ex13_07/
│   │   │   │   ├── Ex13_07.cpp
│   │   │   │   └── Integer.cppm
│   │   │   ├── Ex13_08/
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex13_08.cpp
│   │   │   ├── Ex13_09/
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex13_09.cpp
│   │   │   ├── Ex13_10/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Ex13_10.cpp
│   │   │   │   ├── Truckload.cpp
│   │   │   │   └── Truckload.cppm
│   │   │   ├── Ex13_11/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Ex13_11.cpp
│   │   │   │   ├── Truckload.cpp
│   │   │   │   └── Truckload.cppm
│   │   │   ├── Ex13_12/
│   │   │   │   ├── Ex13_12.cpp
│   │   │   │   ├── Message.cpp
│   │   │   │   └── Message.cppm
│   │   │   ├── Ex13_12A/
│   │   │   │   ├── Ex13_12A.cpp
│   │   │   │   ├── Message.cpp
│   │   │   │   └── Message.cppm
│   │   │   └── Ex13_12B/
│   │   │       ├── Ex13_12B.cpp
│   │   │       ├── Message.cpp
│   │   │       └── Message.cppm
│   │   ├── Chapter 14/
│   │   │   ├── Ex14_01/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Carton.cppm
│   │   │   │   └── Ex14_01.cpp
│   │   │   ├── Ex14_01A/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Carton.cppm
│   │   │   │   └── Ex14_01A.cpp
│   │   │   ├── Ex14_02/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Carton.cppm
│   │   │   │   └── Ex14_02.cpp
│   │   │   ├── Ex14_03/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Carton.cppm
│   │   │   │   └── Ex14_03.cpp
│   │   │   ├── Ex14_04/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Carton.cppm
│   │   │   │   └── Ex14_04.cpp
│   │   │   ├── Ex14_04A/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Carton.cppm
│   │   │   │   └── Ex14_04A.cpp
│   │   │   ├── Ex14_04B/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Carton.cppm
│   │   │   │   └── Ex14_04B.cpp
│   │   │   ├── Ex14_04C/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Carton.cppm
│   │   │   │   └── Ex14_04C.cpp
│   │   │   ├── Ex14_05/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Carton.cppm
│   │   │   │   └── Ex14_05.cpp
│   │   │   ├── Ex14_06/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Carton.cppm
│   │   │   │   └── Ex14_06.cpp
│   │   │   ├── Ex14_07/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Carton.cppm
│   │   │   │   ├── CerealPack.cppm
│   │   │   │   ├── Ex14_07.cpp
│   │   │   │   └── FoodContainer.cppm
│   │   │   ├── Ex14_07A/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Carton.cppm
│   │   │   │   ├── CerealPack.cppm
│   │   │   │   ├── Ex14_07A.cpp
│   │   │   │   └── FoodContainer.cppm
│   │   │   └── Ex14_07B/
│   │   │       ├── Box.cppm
│   │   │       ├── Carton.cppm
│   │   │       ├── CerealPack.cppm
│   │   │       ├── Ex14_07B.cpp
│   │   │       └── FoodContainer.cppm
│   │   ├── Chapter 15/
│   │   │   ├── Ex15_01/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Boxes.cppm
│   │   │   │   ├── Ex15_01.cpp
│   │   │   │   └── ToughPack.cppm
│   │   │   ├── Ex15_02/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Boxes.cppm
│   │   │   │   ├── Carton.cppm
│   │   │   │   ├── Ex15_02.cpp
│   │   │   │   └── ToughPack.cppm
│   │   │   ├── Ex15_03/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Boxes.cppm
│   │   │   │   ├── Carton.cppm
│   │   │   │   ├── Ex15_03.cpp
│   │   │   │   └── ToughPack.cppm
│   │   │   ├── Ex15_04/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Boxes.cppm
│   │   │   │   ├── Carton.cppm
│   │   │   │   ├── Ex15_04.cpp
│   │   │   │   └── ToughPack.cppm
│   │   │   ├── Ex15_05/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Boxes.cppm
│   │   │   │   ├── Carton.cppm
│   │   │   │   ├── Ex15_05.cpp
│   │   │   │   └── ToughPack.cppm
│   │   │   ├── Ex15_06/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Boxes.cppm
│   │   │   │   ├── Carton.cppm
│   │   │   │   ├── Ex15_06.cpp
│   │   │   │   └── ToughPack.cppm
│   │   │   ├── Ex15_07/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Boxes.cppm
│   │   │   │   ├── Carton.cppm
│   │   │   │   ├── Ex15_07.cpp
│   │   │   │   └── ToughPack.cppm
│   │   │   ├── Ex15_07A/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Boxes.cppm
│   │   │   │   ├── Carton.cppm
│   │   │   │   ├── Ex15_07A.cpp
│   │   │   │   └── ToughPack.cppm
│   │   │   ├── Ex15_08/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Boxes.cppm
│   │   │   │   ├── Ex14_08.cpp
│   │   │   │   └── ToughPack.cppm
│   │   │   ├── Ex15_09/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Boxes.cppm
│   │   │   │   ├── Carton.cppm
│   │   │   │   └── Ex15_09.cpp
│   │   │   ├── Ex15_10/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Boxes.cppm
│   │   │   │   ├── Carton.cppm
│   │   │   │   ├── Ex15_10.cpp
│   │   │   │   └── ToughPack.cppm
│   │   │   └── Ex15_11/
│   │   │       ├── Box.cppm
│   │   │       ├── Boxes.cppm
│   │   │       ├── Can.cppm
│   │   │       ├── Carton.cppm
│   │   │       ├── Ex15_11.cpp
│   │   │       ├── ToughPack.cppm
│   │   │       └── Vessel.cppm
│   │   ├── Chapter 16/
│   │   │   ├── Ex16_01/
│   │   │   │   └── Ex16_01.cpp
│   │   │   ├── Ex16_02/
│   │   │   │   ├── Ex16_02.cpp
│   │   │   │   └── Troubles.cppm
│   │   │   ├── Ex16_03/
│   │   │   │   ├── Ex16_03.cpp
│   │   │   │   └── Troubles.cppm
│   │   │   ├── Ex16_04/
│   │   │   │   ├── Ex16_04.cpp
│   │   │   │   └── Troubles.cppm
│   │   │   ├── Ex16_05/
│   │   │   │   ├── Ex16_05.cpp
│   │   │   │   └── Troubles.cppm
│   │   │   ├── Ex16_06/
│   │   │   │   ├── Ex16_06.cpp
│   │   │   │   └── Troubles.cppm
│   │   │   ├── Ex16_07/
│   │   │   │   ├── Ex16_07.cpp
│   │   │   │   └── Troubles.cppm
│   │   │   ├── Ex16_07A/
│   │   │   │   ├── Ex16_07A.cpp
│   │   │   │   └── Troubles.cppm
│   │   │   ├── Ex16_07B/
│   │   │   │   ├── DoubleArrayRAII.cppm
│   │   │   │   ├── Ex16_07B.cpp
│   │   │   │   └── Troubles.cppm
│   │   │   ├── Ex16_07C/
│   │   │   │   ├── Ex16_07C.cpp
│   │   │   │   └── Troubles.cppm
│   │   │   ├── Ex16_07D/
│   │   │   │   ├── Ex16_07D.cpp
│   │   │   │   └── Troubles.cppm
│   │   │   └── Ex16_09/
│   │   │       ├── Box.cppm
│   │   │       ├── DimensionError.cppm
│   │   │       └── Ex16_09.cpp
│   │   ├── Chapter 17/
│   │   │   ├── Ex17_01/
│   │   │   │   ├── Array.cppm
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex17_01.cpp
│   │   │   ├── Ex17_01A/
│   │   │   │   ├── Array.cppm
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex17_01A.cpp
│   │   │   ├── Ex17_02/
│   │   │   │   ├── Array.cppm
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex17_02.cpp
│   │   │   ├── Ex17_02A/
│   │   │   │   ├── Array.cppm
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex17_02A.cpp
│   │   │   ├── Ex17_03/
│   │   │   │   ├── Array.cppm
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex17_03.cpp
│   │   │   ├── Ex17_04/
│   │   │   │   ├── Ex17_04.cpp
│   │   │   │   └── Stack.cppm
│   │   │   ├── Ex17_04A/
│   │   │   │   ├── Ex17_04A.cpp
│   │   │   │   └── Stack.cppm
│   │   │   ├── Ex17_04B/
│   │   │   │   ├── Ex17_04B.cpp
│   │   │   │   └── Stack.cppm
│   │   │   ├── Ex17_05/
│   │   │   │   ├── Ex17_05A.cpp
│   │   │   │   ├── Ex17_05B.cpp
│   │   │   │   └── Ex17_05C.cpp
│   │   │   └── Ex17_06/
│   │   │       └── Ex17_06.cpp
│   │   ├── Chapter 18/
│   │   │   ├── Ex18_01/
│   │   │   │   ├── Array.cppm
│   │   │   │   └── Ex18_01.cpp
│   │   │   ├── Ex18_02/
│   │   │   │   ├── Array.cppm
│   │   │   │   └── Ex18_02.cpp
│   │   │   ├── Ex18_03/
│   │   │   │   ├── Array.cppm
│   │   │   │   └── Ex18_03.cpp
│   │   │   ├── Ex18_04/
│   │   │   │   ├── Array.cppm
│   │   │   │   └── Ex18_04.cpp
│   │   │   ├── Ex18_05A/
│   │   │   │   ├── Array.cppm
│   │   │   │   └── Ex18_05A.cpp
│   │   │   ├── Ex18_05B/
│   │   │   │   ├── Array.cppm
│   │   │   │   └── Ex18_05B.cpp
│   │   │   ├── Ex18_06/
│   │   │   │   ├── Array.cppm
│   │   │   │   └── Ex18_06.cpp
│   │   │   └── Ex18_07/
│   │   │       ├── Array.cppm
│   │   │       └── Ex18_07.cpp
│   │   ├── Chapter 19/
│   │   │   ├── Ex19_01/
│   │   │   │   └── Ex19_01.cpp
│   │   │   ├── Ex19_02/
│   │   │   │   ├── Ex19_02.cpp
│   │   │   │   └── Optimum.cppm
│   │   │   ├── Ex19_03/
│   │   │   │   ├── Ex19_03.cpp
│   │   │   │   ├── Less.cppm
│   │   │   │   └── Optimum.cppm
│   │   │   ├── Ex19_03A/
│   │   │   │   ├── Ex19_03A.cpp
│   │   │   │   └── Optimum.cppm
│   │   │   ├── Ex19_04/
│   │   │   │   ├── Ex19_04.cpp
│   │   │   │   ├── Nearer.cppm
│   │   │   │   └── Optimum.cppm
│   │   │   ├── Ex19_05/
│   │   │   │   ├── Ex19_05.cpp
│   │   │   │   └── Optimum.cppm
│   │   │   ├── Ex19_05A/
│   │   │   │   ├── Ex19_05A.cpp
│   │   │   │   └── Optimum.cppm
│   │   │   ├── Ex19_06/
│   │   │   │   ├── Ex19_06.cpp
│   │   │   │   └── Optimum.cppm
│   │   │   ├── Ex19_07/
│   │   │   │   ├── Ex19_07.cpp
│   │   │   │   ├── Finder.cpp
│   │   │   │   ├── Finder.cppm
│   │   │   │   └── Optimum.cppm
│   │   │   └── Ex19_08/
│   │   │       └── Ex19_08.cpp
│   │   ├── Chapter 20/
│   │   │   ├── Ex20_01/
│   │   │   │   └── Ex20_01.cpp
│   │   │   ├── Ex20_02/
│   │   │   │   └── Ex20_02.cpp
│   │   │   ├── Ex20_03/
│   │   │   │   └── Ex20_03.cpp
│   │   │   ├── Ex20_04/
│   │   │   │   └── Ex20_04.cpp
│   │   │   ├── Ex20_05/
│   │   │   │   └── Ex20_05.cpp
│   │   │   ├── Ex20_06/
│   │   │   │   └── Ex20_06.cpp
│   │   │   ├── Ex20_07/
│   │   │   │   └── Ex20_07.cpp
│   │   │   ├── Ex20_08/
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex20_08.cpp
│   │   │   ├── Ex20_09/
│   │   │   │   └── Ex20_09.cpp
│   │   │   ├── Ex20_10/
│   │   │   │   └── Ex20_10.cpp
│   │   │   ├── Ex20_11/
│   │   │   │   └── Ex20_11.cpp
│   │   │   ├── Ex20_11A/
│   │   │   │   └── Ex20_11A.cpp
│   │   │   ├── Ex20_12/
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex20_12.cpp
│   │   │   ├── Ex20_12A/
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex20_12A.cpp
│   │   │   ├── Ex20_13/
│   │   │   │   └── Ex20_13.cpp
│   │   │   ├── Ex20_13A/
│   │   │   │   └── Ex20_13A.cpp
│   │   │   ├── Ex20_13B/
│   │   │   │   └── Ex20_13B.cpp
│   │   │   ├── Ex20_14/
│   │   │   │   └── Ex20_14.cpp
│   │   │   ├── Ex20_14A/
│   │   │   │   └── Ex20_14A.cpp
│   │   │   ├── Ex20_14B/
│   │   │   │   └── Ex20_14B.cpp
│   │   │   ├── Ex20_15/
│   │   │   │   └── Ex20_15.cpp
│   │   │   ├── Ex20_15A/
│   │   │   │   └── Ex20_15A.cpp
│   │   │   ├── Ex20_16/
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex20_16.cpp
│   │   │   ├── Ex20_17/
│   │   │   │   └── Ex20_17.cpp
│   │   │   └── Ex20_18/
│   │   │       └── Ex20_18.cpp
│   │   └── Chapter 21/
│   │       ├── Ex21_01/
│   │       │   └── Ex21_01.cpp
│   │       ├── Ex21_02/
│   │       │   └── Ex21_02.cpp
│   │       ├── Ex21_03/
│   │       │   ├── Array.cppm
│   │       │   └── Ex21_03.cpp
│   │       └── Ex21_04/
│   │           └── Ex21_04.cpp
│   ├── NoModules/
│   │   ├── Appendix A/
│   │   │   ├── ExA_01/
│   │   │   │   └── ExA_01.cpp
│   │   │   ├── ExA_02/
│   │   │   │   └── ExA_02.cpp
│   │   │   ├── ExA_02A/
│   │   │   │   └── ExA_02A.cpp
│   │   │   ├── ExA_03/
│   │   │   │   └── ExA_03.cpp
│   │   │   ├── ExA_04/
│   │   │   │   └── ExA_04.cpp
│   │   │   ├── ExA_05/
│   │   │   │   ├── ExA_05.cpp
│   │   │   │   └── inclusivity.quote
│   │   │   ├── ExA_06/
│   │   │   │   └── ExA_06.cpp
│   │   │   ├── ExA_07/
│   │   │   │   ├── ExA_07.cpp
│   │   │   │   └── Power.cpp
│   │   │   ├── ExA_07A/
│   │   │   │   ├── ExA_07A.cpp
│   │   │   │   ├── Power.cpp
│   │   │   │   └── Power.h
│   │   │   ├── ExA_08/
│   │   │   │   ├── ExA_08.cpp
│   │   │   │   ├── Power.cpp
│   │   │   │   └── Range.cpp
│   │   │   ├── ExA_08A/
│   │   │   │   ├── ExA_08A.cpp
│   │   │   │   ├── Power.cpp
│   │   │   │   └── Range.cpp
│   │   │   ├── ExA_09/
│   │   │   │   ├── ExA_09.cpp
│   │   │   │   └── Power.cpp
│   │   │   ├── ExA_09A/
│   │   │   │   ├── ExA_09A.cpp
│   │   │   │   └── Power.cpp
│   │   │   ├── ExA_10/
│   │   │   │   ├── BadMath.h
│   │   │   │   └── ExA_10.cpp
│   │   │   ├── ExA_10A/
│   │   │   │   ├── BetterMath.h
│   │   │   │   └── ExA_10A.cpp
│   │   │   ├── ExA_11/
│   │   │   │   ├── BetterMath.h
│   │   │   │   ├── ExA_11.cpp
│   │   │   │   ├── Hypot.cpp
│   │   │   │   ├── Hypot.h
│   │   │   │   ├── Pow4.cpp
│   │   │   │   └── Pow4.h
│   │   │   ├── ExA_12/
│   │   │   │   ├── ExA_12.cpp
│   │   │   │   ├── Hypot.cpp
│   │   │   │   ├── Hypot.h
│   │   │   │   ├── Pow4.cpp
│   │   │   │   ├── Pow4.h
│   │   │   │   └── ProperMath.h
│   │   │   ├── ExA_13/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.h
│   │   │   │   └── ExA_13.cpp
│   │   │   └── ExA_13A/
│   │   │       ├── Box.h
│   │   │       └── ExA_13A.cpp
│   │   ├── Chapter 01/
│   │   │   ├── Ex1_01.cpp
│   │   │   └── Ex1_02.cpp
│   │   ├── Chapter 02/
│   │   │   ├── Ex2_01.cpp
│   │   │   ├── Ex2_02.cpp
│   │   │   ├── Ex2_03.cpp
│   │   │   ├── Ex2_03A.cpp
│   │   │   ├── Ex2_03B.cpp
│   │   │   ├── Ex2_03C.cpp
│   │   │   ├── Ex2_03D.cpp
│   │   │   ├── Ex2_04.cpp
│   │   │   ├── Ex2_05.cpp
│   │   │   ├── Ex2_06.cpp
│   │   │   ├── Ex2_06B.cpp
│   │   │   └── Ex2_07.cpp
│   │   ├── Chapter 03/
│   │   │   ├── Ex3_01.cpp
│   │   │   ├── Ex3_02.cpp
│   │   │   └── Ex3_03.cpp
│   │   ├── Chapter 04/
│   │   │   ├── Ex4_01.cpp
│   │   │   ├── Ex4_01A.cpp
│   │   │   ├── Ex4_02.cpp
│   │   │   ├── Ex4_02A.cpp
│   │   │   ├── Ex4_03.cpp
│   │   │   ├── Ex4_04.cpp
│   │   │   ├── Ex4_04A.cpp
│   │   │   ├── Ex4_05.cpp
│   │   │   ├── Ex4_06.cpp
│   │   │   ├── Ex4_07.cpp
│   │   │   ├── Ex4_08.cpp
│   │   │   ├── Ex4_09.cpp
│   │   │   └── Ex4_09A.cpp
│   │   ├── Chapter 05/
│   │   │   ├── Ex5_01.cpp
│   │   │   ├── Ex5_02.cpp
│   │   │   ├── Ex5_03.cpp
│   │   │   ├── Ex5_03A.cpp
│   │   │   ├── Ex5_04.cpp
│   │   │   ├── Ex5_04A.cpp
│   │   │   ├── Ex5_05.cpp
│   │   │   ├── Ex5_06.cpp
│   │   │   ├── Ex5_07.cpp
│   │   │   ├── Ex5_07A.cpp
│   │   │   ├── Ex5_08.cpp
│   │   │   ├── Ex5_09.cpp
│   │   │   ├── Ex5_10.cpp
│   │   │   ├── Ex5_11.cpp
│   │   │   ├── Ex5_12.cpp
│   │   │   ├── Ex5_12A.cpp
│   │   │   ├── Ex5_13.cpp
│   │   │   ├── Ex5_14.cpp
│   │   │   └── Ex5_15.cpp
│   │   ├── Chapter 06/
│   │   │   ├── Ex6_01.cpp
│   │   │   ├── Ex6_02.cpp
│   │   │   ├── Ex6_03.cpp
│   │   │   ├── Ex6_04.cpp
│   │   │   ├── Ex6_05.cpp
│   │   │   ├── Ex6_06.cpp
│   │   │   └── Ex6_07.cpp
│   │   ├── Chapter 07/
│   │   │   ├── Ex7_01.cpp
│   │   │   ├── Ex7_01A.cpp
│   │   │   ├── Ex7_02.cpp
│   │   │   ├── Ex7_02A.cpp
│   │   │   ├── Ex7_03.cpp
│   │   │   ├── Ex7_04.cpp
│   │   │   ├── Ex7_05.cpp
│   │   │   ├── Ex7_06.cpp
│   │   │   └── Ex7_07.cpp
│   │   ├── Chapter 08/
│   │   │   ├── Ex8_01.cpp
│   │   │   ├── Ex8_02.cpp
│   │   │   ├── Ex8_03.cpp
│   │   │   ├── Ex8_04.cpp
│   │   │   ├── Ex8_05.cpp
│   │   │   ├── Ex8_05A.cpp
│   │   │   ├── Ex8_06.cpp
│   │   │   ├── Ex8_06A.cpp
│   │   │   ├── Ex8_07.cpp
│   │   │   ├── Ex8_08.cpp
│   │   │   ├── Ex8_09A.cpp
│   │   │   ├── Ex8_09B.cpp
│   │   │   ├── Ex8_09C.cpp
│   │   │   ├── Ex8_10.cpp
│   │   │   ├── Ex8_11.cpp
│   │   │   ├── Ex8_12.cpp
│   │   │   ├── Ex8_13.cpp
│   │   │   ├── Ex8_14.cpp
│   │   │   ├── Ex8_15.cpp
│   │   │   ├── Ex8_16.cpp
│   │   │   └── Ex8_17.cpp
│   │   ├── Chapter 09/
│   │   │   ├── Ex9_01.cpp
│   │   │   ├── Ex9_02.cpp
│   │   │   ├── Ex9_03.cpp
│   │   │   └── Ex9_03A.cpp
│   │   ├── Chapter 10/
│   │   │   ├── Ex10_01.cpp
│   │   │   ├── Ex10_02.cpp
│   │   │   ├── Ex10_03.cpp
│   │   │   ├── Ex10_03A.cpp
│   │   │   └── Ex10_04.cpp
│   │   ├── Chapter 11/
│   │   │   ├── Ex11_06/
│   │   │   │   └── Ex11_06.cpp
│   │   │   ├── Ex11_07/
│   │   │   │   ├── Ex11_07.cpp
│   │   │   │   ├── math.cpp
│   │   │   │   └── math.h
│   │   │   └── Ex11_08/
│   │   │       ├── Ex11_08.cpp
│   │   │       └── squaring.h
│   │   ├── Chapter 12/
│   │   │   ├── Ex12_01/
│   │   │   │   └── Ex12_01.cpp
│   │   │   ├── Ex12_01A/
│   │   │   │   └── Ex12_01A.cpp
│   │   │   ├── Ex12_02/
│   │   │   │   └── Ex12_02.cpp
│   │   │   ├── Ex12_03/
│   │   │   │   └── Ex12_03.cpp
│   │   │   ├── Ex12_04/
│   │   │   │   └── Ex12_04.cpp
│   │   │   ├── Ex12_05/
│   │   │   │   └── Ex12_05.cpp
│   │   │   ├── Ex12_05A/
│   │   │   │   └── Ex12_05A.cpp
│   │   │   ├── Ex12_06/
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex12_06.cpp
│   │   │   ├── Ex12_06A/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex12_06A.cpp
│   │   │   ├── Ex12_06B/
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex12_06B.cpp
│   │   │   ├── Ex12_07/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex12_07.cpp
│   │   │   ├── Ex12_08/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex12_08.cpp
│   │   │   ├── Ex12_09/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex12_09.cpp
│   │   │   ├── Ex12_10/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex12_10.cpp
│   │   │   ├── Ex12_11/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex12_11.cpp
│   │   │   ├── Ex12_12/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex12_12.cpp
│   │   │   ├── Ex12_13/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex12_13.cpp
│   │   │   ├── Ex12_14/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex12_14.cpp
│   │   │   ├── Ex12_15/
│   │   │   │   ├── CylindricalBox.cpp
│   │   │   │   ├── CylindricalBox.h
│   │   │   │   └── Ex12_15.cpp
│   │   │   ├── Ex12_16/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex12_16.cpp
│   │   │   ├── Ex12_17/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Ex12_17.cpp
│   │   │   │   ├── Package.h
│   │   │   │   ├── RandomBoxes.h
│   │   │   │   ├── SharedBox.h
│   │   │   │   ├── Truckload.cpp
│   │   │   │   └── Truckload.h
│   │   │   └── Ex12_18/
│   │   │       ├── Box.h
│   │   │       ├── Ex12_18.cpp
│   │   │       ├── RandomBoxes.h
│   │   │       ├── Truckload.cpp
│   │   │       └── Truckload.h
│   │   ├── Chapter 13/
│   │   │   ├── Ex13_01/
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex13_01.cpp
│   │   │   ├── Ex13_02/
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex13_02.cpp
│   │   │   ├── Ex13_03/
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex13_03.cpp
│   │   │   ├── Ex13_03A/
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex13_03A.cpp
│   │   │   ├── Ex13_04/
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex13_04.cpp
│   │   │   ├── Ex13_05/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex13_05.cpp
│   │   │   ├── Ex13_06/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex13_06.cpp
│   │   │   ├── Ex13_07/
│   │   │   │   ├── Ex13_07.cpp
│   │   │   │   └── Integer.h
│   │   │   ├── Ex13_08/
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex13_08.cpp
│   │   │   ├── Ex13_09/
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex13_09.cpp
│   │   │   ├── Ex13_10/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Ex13_10.cpp
│   │   │   │   ├── Truckload.cpp
│   │   │   │   └── Truckload.h
│   │   │   ├── Ex13_11/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Ex13_11.cpp
│   │   │   │   ├── Truckload.cpp
│   │   │   │   └── Truckload.h
│   │   │   ├── Ex13_12/
│   │   │   │   ├── Ex13_12.cpp
│   │   │   │   ├── Message.cpp
│   │   │   │   └── Message.h
│   │   │   ├── Ex13_12A/
│   │   │   │   ├── Ex13_12A.cpp
│   │   │   │   ├── Message.cpp
│   │   │   │   └── Message.h
│   │   │   └── Ex13_12B/
│   │   │       ├── Ex13_12B.cpp
│   │   │       ├── Message.cpp
│   │   │       └── Message.h
│   │   ├── Chapter 14/
│   │   │   ├── Ex14_01/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Carton.h
│   │   │   │   └── Ex14_01.cpp
│   │   │   ├── Ex14_01A/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Carton.h
│   │   │   │   └── Ex14_01A.cpp
│   │   │   ├── Ex14_02/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Carton.h
│   │   │   │   └── Ex14_02.cpp
│   │   │   ├── Ex14_03/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Carton.h
│   │   │   │   └── Ex14_03.cpp
│   │   │   ├── Ex14_04/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Carton.h
│   │   │   │   └── Ex14_04.cpp
│   │   │   ├── Ex14_04A/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Carton.h
│   │   │   │   └── Ex14_04A.cpp
│   │   │   ├── Ex14_04B/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Carton.h
│   │   │   │   └── Ex14_04B.cpp
│   │   │   ├── Ex14_04C/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Carton.h
│   │   │   │   └── Ex14_04C.cpp
│   │   │   ├── Ex14_05/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Carton.h
│   │   │   │   └── Ex14_05.cpp
│   │   │   ├── Ex14_06/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Carton.h
│   │   │   │   └── Ex14_06.cpp
│   │   │   ├── Ex14_07/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Carton.h
│   │   │   │   ├── CerealPack.h
│   │   │   │   ├── Ex14_07.cpp
│   │   │   │   └── FoodContainer.h
│   │   │   ├── Ex14_07A/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Carton.h
│   │   │   │   ├── CerealPack.h
│   │   │   │   ├── Ex14_07A.cpp
│   │   │   │   └── FoodContainer.h
│   │   │   └── Ex14_07B/
│   │   │       ├── Box.h
│   │   │       ├── Carton.h
│   │   │       ├── CerealPack.h
│   │   │       ├── Ex14_07B.cpp
│   │   │       └── FoodContainer.h
│   │   ├── Chapter 15/
│   │   │   ├── Ex15_01/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Ex15_01.cpp
│   │   │   │   └── ToughPack.h
│   │   │   ├── Ex15_02/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Carton.h
│   │   │   │   ├── Ex15_02.cpp
│   │   │   │   └── ToughPack.h
│   │   │   ├── Ex15_03/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Carton.h
│   │   │   │   ├── Ex15_03.cpp
│   │   │   │   └── ToughPack.h
│   │   │   ├── Ex15_04/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Carton.h
│   │   │   │   ├── Ex15_04.cpp
│   │   │   │   └── ToughPack.h
│   │   │   ├── Ex15_05/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Carton.h
│   │   │   │   ├── Ex15_05.cpp
│   │   │   │   └── ToughPack.h
│   │   │   ├── Ex15_06/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Carton.h
│   │   │   │   ├── Ex15_06.cpp
│   │   │   │   └── ToughPack.h
│   │   │   ├── Ex15_07/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Carton.h
│   │   │   │   ├── Ex15_07.cpp
│   │   │   │   └── ToughPack.h
│   │   │   ├── Ex15_07A/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Carton.h
│   │   │   │   ├── Ex15_07A.cpp
│   │   │   │   └── ToughPack.h
│   │   │   ├── Ex15_08/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Ex14_08.cpp
│   │   │   │   └── ToughPack.h
│   │   │   ├── Ex15_09/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Carton.h
│   │   │   │   └── Ex15_09.cpp
│   │   │   ├── Ex15_10/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Carton.h
│   │   │   │   ├── Ex15_10.cpp
│   │   │   │   └── ToughPack.h
│   │   │   └── Ex15_11/
│   │   │       ├── Box.h
│   │   │       ├── Can.h
│   │   │       ├── Carton.h
│   │   │       ├── Ex15_11.cpp
│   │   │       ├── ToughPack.h
│   │   │       └── Vessel.h
│   │   ├── Chapter 16/
│   │   │   ├── Ex16_01/
│   │   │   │   └── Ex16_01.cpp
│   │   │   ├── Ex16_02/
│   │   │   │   ├── Ex16_02.cpp
│   │   │   │   └── Troubles.h
│   │   │   ├── Ex16_03/
│   │   │   │   ├── Ex16_03.cpp
│   │   │   │   └── Troubles.h
│   │   │   ├── Ex16_04/
│   │   │   │   ├── Ex16_04.cpp
│   │   │   │   └── Troubles.h
│   │   │   ├── Ex16_05/
│   │   │   │   ├── Ex16_05.cpp
│   │   │   │   └── Troubles.h
│   │   │   ├── Ex16_06/
│   │   │   │   ├── Ex16_06.cpp
│   │   │   │   └── Troubles.h
│   │   │   ├── Ex16_07/
│   │   │   │   ├── Ex16_07.cpp
│   │   │   │   └── Troubles.h
│   │   │   ├── Ex16_07A/
│   │   │   │   ├── Ex16_07A.cpp
│   │   │   │   └── Troubles.h
│   │   │   ├── Ex16_07B/
│   │   │   │   ├── DoubleArrayRAII.h
│   │   │   │   ├── Ex16_07B.cpp
│   │   │   │   └── Troubles.h
│   │   │   ├── Ex16_07C/
│   │   │   │   ├── Ex16_07C.cpp
│   │   │   │   └── Troubles.h
│   │   │   ├── Ex16_07D/
│   │   │   │   ├── Ex16_07D.cpp
│   │   │   │   └── Troubles.h
│   │   │   └── Ex16_09/
│   │   │       ├── Box.h
│   │   │       ├── DimensionError.h
│   │   │       └── Ex16_09.cpp
│   │   ├── Chapter 17/
│   │   │   ├── Ex17_01/
│   │   │   │   ├── Array.h
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex17_01.cpp
│   │   │   ├── Ex17_01A/
│   │   │   │   ├── Array.h
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex17_01A.cpp
│   │   │   ├── Ex17_02/
│   │   │   │   ├── Array.h
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex17_02.cpp
│   │   │   ├── Ex17_02A/
│   │   │   │   ├── Array.h
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex17_02A.cpp
│   │   │   ├── Ex17_03/
│   │   │   │   ├── Array.h
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex17_03.cpp
│   │   │   ├── Ex17_04/
│   │   │   │   ├── Ex17_04.cpp
│   │   │   │   └── Stack.h
│   │   │   ├── Ex17_04A/
│   │   │   │   ├── Ex17_04A.cpp
│   │   │   │   └── Stack.h
│   │   │   ├── Ex17_04B/
│   │   │   │   ├── Ex17_04B.cpp
│   │   │   │   └── Stack.h
│   │   │   ├── Ex17_05/
│   │   │   │   ├── Ex17_05A.cpp
│   │   │   │   ├── Ex17_05B.cpp
│   │   │   │   └── Ex17_05C.cpp
│   │   │   └── Ex17_06/
│   │   │       └── Ex17_06.cpp
│   │   ├── Chapter 18/
│   │   │   ├── Ex18_01/
│   │   │   │   ├── Array.h
│   │   │   │   └── Ex18_01.cpp
│   │   │   ├── Ex18_02/
│   │   │   │   ├── Array.h
│   │   │   │   └── Ex18_02.cpp
│   │   │   ├── Ex18_03/
│   │   │   │   ├── Array.h
│   │   │   │   └── Ex18_03.cpp
│   │   │   ├── Ex18_04/
│   │   │   │   ├── Array.h
│   │   │   │   └── Ex18_04.cpp
│   │   │   ├── Ex18_05A/
│   │   │   │   ├── Array.h
│   │   │   │   └── Ex18_05A.cpp
│   │   │   ├── Ex18_05B/
│   │   │   │   ├── Array.h
│   │   │   │   └── Ex18_05B.cpp
│   │   │   ├── Ex18_06/
│   │   │   │   ├── Array.h
│   │   │   │   └── Ex18_06.cpp
│   │   │   └── Ex18_07/
│   │   │       ├── Array.h
│   │   │       └── Ex18_07.cpp
│   │   ├── Chapter 19/
│   │   │   ├── Ex19_01/
│   │   │   │   └── Ex19_01.cpp
│   │   │   ├── Ex19_02/
│   │   │   │   ├── Ex19_02.cpp
│   │   │   │   └── Optimum.h
│   │   │   ├── Ex19_03/
│   │   │   │   ├── Ex19_03.cpp
│   │   │   │   ├── Less.h
│   │   │   │   └── Optimum.h
│   │   │   ├── Ex19_03A/
│   │   │   │   ├── Ex19_03A.cpp
│   │   │   │   └── Optimum.h
│   │   │   ├── Ex19_04/
│   │   │   │   ├── Ex19_04.cpp
│   │   │   │   ├── Nearer.h
│   │   │   │   └── Optimum.h
│   │   │   ├── Ex19_05/
│   │   │   │   ├── Ex19_05.cpp
│   │   │   │   └── Optimum.h
│   │   │   ├── Ex19_05A/
│   │   │   │   ├── Ex19_05A.cpp
│   │   │   │   └── Optimum.h
│   │   │   ├── Ex19_06/
│   │   │   │   ├── Ex19_06.cpp
│   │   │   │   └── Optimum.h
│   │   │   ├── Ex19_07/
│   │   │   │   ├── Ex19_07.cpp
│   │   │   │   ├── Finder.cpp
│   │   │   │   ├── Finder.h
│   │   │   │   └── Optimum.h
│   │   │   └── Ex19_08/
│   │   │       └── Ex19_08.cpp
│   │   ├── Chapter 20/
│   │   │   ├── Ex20_01/
│   │   │   │   └── Ex20_01.cpp
│   │   │   ├── Ex20_02/
│   │   │   │   └── Ex20_02.cpp
│   │   │   ├── Ex20_03/
│   │   │   │   └── Ex20_03.cpp
│   │   │   ├── Ex20_04/
│   │   │   │   └── Ex20_04.cpp
│   │   │   ├── Ex20_05/
│   │   │   │   └── Ex20_05.cpp
│   │   │   ├── Ex20_06/
│   │   │   │   └── Ex20_06.cpp
│   │   │   ├── Ex20_07/
│   │   │   │   └── Ex20_07.cpp
│   │   │   ├── Ex20_08/
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex20_08.cpp
│   │   │   ├── Ex20_09/
│   │   │   │   └── Ex20_09.cpp
│   │   │   ├── Ex20_10/
│   │   │   │   └── Ex20_10.cpp
│   │   │   ├── Ex20_11/
│   │   │   │   └── Ex20_11.cpp
│   │   │   ├── Ex20_11A/
│   │   │   │   └── Ex20_11A.cpp
│   │   │   ├── Ex20_12/
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex20_12.cpp
│   │   │   ├── Ex20_12A/
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex20_12A.cpp
│   │   │   ├── Ex20_13/
│   │   │   │   └── Ex20_13.cpp
│   │   │   ├── Ex20_13A/
│   │   │   │   └── Ex20_13A.cpp
│   │   │   ├── Ex20_13B/
│   │   │   │   └── Ex20_13B.cpp
│   │   │   ├── Ex20_14/
│   │   │   │   └── Ex20_14.cpp
│   │   │   ├── Ex20_14A/
│   │   │   │   └── Ex20_14A.cpp
│   │   │   ├── Ex20_14B/
│   │   │   │   └── Ex20_14B.cpp
│   │   │   ├── Ex20_15/
│   │   │   │   └── Ex20_15.cpp
│   │   │   ├── Ex20_15A/
│   │   │   │   └── Ex20_15A.cpp
│   │   │   ├── Ex20_16/
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex20_16.cpp
│   │   │   ├── Ex20_17/
│   │   │   │   └── Ex20_17.cpp
│   │   │   └── Ex20_18/
│   │   │       └── Ex20_18.cpp
│   │   └── Chapter 21/
│   │       ├── Ex21_01/
│   │       │   └── Ex21_01.cpp
│   │       ├── Ex21_02/
│   │       │   └── Ex21_02.cpp
│   │       ├── Ex21_03/
│   │       │   ├── Array.h
│   │       │   └── Ex21_03.cpp
│   │       └── Ex21_04/
│   │           └── Ex21_04.cpp
│   └── README.md
├── Exercises/
│   ├── Modules/
│   │   ├── Chapter 01/
│   │   │   ├── Exer1_03.cpp
│   │   │   ├── Soln1_01.cpp
│   │   │   └── Soln1_02.cpp
│   │   ├── Chapter 02/
│   │   │   ├── Soln2_01A.cpp
│   │   │   ├── Soln2_01B.cpp
│   │   │   ├── Soln2_02A.cpp
│   │   │   ├── Soln2_02B.cpp
│   │   │   ├── Soln2_03.cpp
│   │   │   ├── Soln2_04.cpp
│   │   │   ├── Soln2_05.cpp
│   │   │   ├── Soln2_06.cpp
│   │   │   ├── Soln2_07.cpp
│   │   │   └── Soln2_08.cpp
│   │   ├── Chapter 03/
│   │   │   ├── Soln3_01.cpp
│   │   │   ├── Soln3_02.cpp
│   │   │   ├── Soln3_03.cpp
│   │   │   ├── Soln3_04.cpp
│   │   │   ├── Soln3_05.cpp
│   │   │   └── Soln3_06.cpp
│   │   ├── Chapter 04/
│   │   │   ├── Soln4_01.cpp
│   │   │   ├── Soln4_02.cpp
│   │   │   ├── Soln4_03.cpp
│   │   │   ├── Soln4_04.cpp
│   │   │   ├── Soln4_05.cpp
│   │   │   ├── Soln4_06.cpp
│   │   │   ├── Soln4_07.cpp
│   │   │   └── Soln4_08.cpp
│   │   ├── Chapter 05/
│   │   │   ├── Soln5_01.cpp
│   │   │   ├── Soln5_02.cpp
│   │   │   ├── Soln5_03.cpp
│   │   │   ├── Soln5_04.cpp
│   │   │   ├── Soln5_05.cpp
│   │   │   ├── Soln5_06.cpp
│   │   │   ├── Soln5_07.cpp
│   │   │   └── Soln5_08.cpp
│   │   ├── Chapter 06/
│   │   │   ├── Soln6_01.cpp
│   │   │   ├── Soln6_02.cpp
│   │   │   ├── Soln6_03.cpp
│   │   │   ├── Soln6_04.cpp
│   │   │   ├── Soln6_05.cpp
│   │   │   └── Soln6_06.cpp
│   │   ├── Chapter 08/
│   │   │   ├── Soln8_01.cpp
│   │   │   ├── Soln8_02.cpp
│   │   │   ├── Soln8_03.cpp
│   │   │   ├── Soln8_04.cpp
│   │   │   ├── Soln8_05.cpp
│   │   │   ├── Soln8_06.cpp
│   │   │   ├── Soln8_07.cpp
│   │   │   ├── Soln8_07A.cpp
│   │   │   ├── Soln8_08.cpp
│   │   │   └── Soln8_09.cpp
│   │   ├── Chapter 09/
│   │   │   ├── Soln9_01.cpp
│   │   │   ├── Soln9_02.cpp
│   │   │   ├── Soln9_03.cpp
│   │   │   ├── Soln9_04.cpp
│   │   │   ├── Soln9_05.cpp
│   │   │   └── Soln9_06.cpp
│   │   ├── Chapter 10/
│   │   │   ├── Soln10_01.cpp
│   │   │   ├── Soln10_02.cpp
│   │   │   ├── Soln10_03.cpp
│   │   │   ├── Soln10_04.cpp
│   │   │   ├── Soln10_05.cpp
│   │   │   └── Soln10_06.cpp
│   │   ├── Chapter 11/
│   │   │   ├── Soln11_01/
│   │   │   │   ├── Soln11_01.cpp
│   │   │   │   └── words.cppm
│   │   │   ├── Soln11_02/
│   │   │   │   ├── Soln11_02.cpp
│   │   │   │   ├── words.cpp
│   │   │   │   └── words.cppm
│   │   │   ├── Soln11_03/
│   │   │   │   ├── Soln11_03.cpp
│   │   │   │   ├── words.cppm
│   │   │   │   ├── words.sorting.cpp
│   │   │   │   ├── words.sorting.cppm
│   │   │   │   ├── words.utils.cpp
│   │   │   │   └── words.utils.cppm
│   │   │   ├── Soln11_04/
│   │   │   │   ├── Soln11_04.cpp
│   │   │   │   ├── internals.cpp
│   │   │   │   ├── words.cpp
│   │   │   │   └── words.cppm
│   │   │   ├── Soln11_05/
│   │   │   │   ├── Soln11_05.cpp
│   │   │   │   ├── alias.cppm
│   │   │   │   ├── internals.cpp
│   │   │   │   ├── sorting.cppm
│   │   │   │   ├── utils.cppm
│   │   │   │   └── words.cppm
│   │   │   └── Soln11_06/
│   │   │       ├── Soln11_06.cpp
│   │   │       ├── words.cpp
│   │   │       └── words.cppm
│   │   ├── Chapter 12/
│   │   │   ├── Soln12_01/
│   │   │   │   ├── Integer.cpp
│   │   │   │   ├── Integer.cppm
│   │   │   │   └── Soln12_01.cpp
│   │   │   ├── Soln12_02/
│   │   │   │   ├── Integer.cpp
│   │   │   │   ├── Integer.cppm
│   │   │   │   └── Soln12_02.cpp
│   │   │   ├── Soln12_03/
│   │   │   │   ├── Integer.cpp
│   │   │   │   ├── Integer.cppm
│   │   │   │   └── Soln12_03.cpp
│   │   │   ├── Soln12_04/
│   │   │   │   ├── Integer.cpp
│   │   │   │   ├── Integer.cppm
│   │   │   │   └── Soln12_04.cpp
│   │   │   ├── Soln12_05/
│   │   │   │   ├── Integer.cpp
│   │   │   │   ├── Integer.cppm
│   │   │   │   └── Soln12_05.cpp
│   │   │   ├── Soln12_06/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── RandomBoxes.cppm
│   │   │   │   ├── Soln12_06.cpp
│   │   │   │   ├── Truckload.cpp
│   │   │   │   └── Truckload.cppm
│   │   │   ├── Soln12_07/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── RandomBoxes.cppm
│   │   │   │   ├── Soln12_07.cpp
│   │   │   │   ├── Truckload.cpp
│   │   │   │   └── Truckload.cppm
│   │   │   └── Soln12_08/
│   │   │       ├── Box.cppm
│   │   │       ├── RandomBoxes.cppm
│   │   │       ├── Soln12_08.cpp
│   │   │       ├── Truckload.cpp
│   │   │       └── Truckload.cppm
│   │   ├── Chapter 13/
│   │   │   ├── Soln13_01/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Soln13_01.cpp
│   │   │   ├── Soln13_02/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Soln13_02.cpp
│   │   │   ├── Soln13_03/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Soln13_03.cpp
│   │   │   ├── Soln13_04/
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Soln13_04.cpp
│   │   │   ├── Soln13_05/
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Soln13_05.cpp
│   │   │   ├── Soln13_06/
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Soln13_06.cpp
│   │   │   ├── Soln13_07/
│   │   │   │   ├── Rational.cppm
│   │   │   │   └── Soln13_07.cpp
│   │   │   ├── Soln13_08/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── PRNG.cppm
│   │   │   │   └── Soln13_08.cpp
│   │   │   └── Soln13_09/
│   │   │       ├── Box.cppm
│   │   │       ├── Soln13_09.cpp
│   │   │       ├── Truckload.cpp
│   │   │       └── Truckload.cppm
│   │   ├── Chapter 14/
│   │   │   ├── Soln14_01/
│   │   │   │   ├── Animals.cppm
│   │   │   │   └── Soln14_01.cpp
│   │   │   ├── Soln14_02/
│   │   │   │   ├── Animals.cppm
│   │   │   │   └── Soln14_02.cpp
│   │   │   ├── Soln14_03/
│   │   │   │   ├── Animals.cpp
│   │   │   │   ├── Animals.cppm
│   │   │   │   └── Soln14_03.cpp
│   │   │   └── Soln14_04/
│   │   │       ├── Person.cpp
│   │   │       ├── Person.cppm
│   │   │       └── Soln14_04.cpp
│   │   ├── Chapter 15/
│   │   │   ├── Soln15_01/
│   │   │   │   ├── Animals.cpp
│   │   │   │   ├── Animals.cppm
│   │   │   │   ├── Soln15_01.cpp
│   │   │   │   ├── Zoo.cpp
│   │   │   │   └── Zoo.cppm
│   │   │   ├── Soln15_02/
│   │   │   │   ├── Animals.cpp
│   │   │   │   ├── Animals.cppm
│   │   │   │   ├── Soln15_02.cpp
│   │   │   │   ├── Zoo.cpp
│   │   │   │   └── Zoo.cppm
│   │   │   ├── Soln15_03/
│   │   │   │   ├── Animals.cpp
│   │   │   │   ├── Animals.cppm
│   │   │   │   ├── Soln15_03.cpp
│   │   │   │   ├── Zoo.cpp
│   │   │   │   └── Zoo.cppm
│   │   │   ├── Soln15_04/
│   │   │   │   ├── Animals.cpp
│   │   │   │   ├── Animals.cppm
│   │   │   │   ├── Soln15_04.cpp
│   │   │   │   ├── Zoo.cpp
│   │   │   │   └── Zoo.cppm
│   │   │   ├── Soln15_05/
│   │   │   │   ├── Animals.cpp
│   │   │   │   ├── Animals.cppm
│   │   │   │   ├── Soln15_05.cpp
│   │   │   │   ├── Zoo.cpp
│   │   │   │   └── Zoo.cppm
│   │   │   └── Soln15_06/
│   │   │       ├── Point.cppm
│   │   │       ├── Shapes.cppm
│   │   │       └── Soln15_06.cpp
│   │   ├── Chapter 16/
│   │   │   ├── Exer16_06/
│   │   │   │   ├── Customer.cpp
│   │   │   │   ├── Customer.cppm
│   │   │   │   ├── DB.cpp
│   │   │   │   ├── DB.h
│   │   │   │   ├── DBException.cppm
│   │   │   │   └── Exer16_06.cpp
│   │   │   ├── Soln16_01/
│   │   │   │   ├── Curveball.cppm
│   │   │   │   └── Soln16_01.cpp
│   │   │   ├── Soln16_02/
│   │   │   │   ├── Curveball.cppm
│   │   │   │   ├── Soln16_02.cpp
│   │   │   │   └── TooManyExceptions.cppm
│   │   │   ├── Soln16_03/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── RandomBoxes.cppm
│   │   │   │   ├── Soln16_03.cpp
│   │   │   │   ├── Truckload.cpp
│   │   │   │   └── Truckload.cppm
│   │   │   ├── Soln16_04/
│   │   │   │   └── Soln16_04.cpp
│   │   │   ├── Soln16_05/
│   │   │   │   ├── Curveball.cppm
│   │   │   │   ├── DomainExceptions.cppm
│   │   │   │   └── Soln16_05.cpp
│   │   │   └── Soln16_06/
│   │   │       ├── Customer.cpp
│   │   │       ├── Customer.cppm
│   │   │       ├── DB.cpp
│   │   │       ├── DB.h
│   │   │       ├── DBException.cppm
│   │   │       ├── DB_RAII.cppm
│   │   │       └── Soln16_06.cpp
│   │   ├── Chapter 17/
│   │   │   ├── Soln17_01/
│   │   │   │   ├── Array.cppm
│   │   │   │   └── Soln17_01.cpp
│   │   │   ├── Soln17_02/
│   │   │   │   ├── Pair.cppm
│   │   │   │   └── Soln17_02.cpp
│   │   │   ├── Soln17_03/
│   │   │   │   ├── Pair.cppm
│   │   │   │   └── Soln17_03.cpp
│   │   │   ├── Soln17_04/
│   │   │   │   ├── Pair.cppm
│   │   │   │   ├── Soln17_04.cpp
│   │   │   │   └── SparseArray.cppm
│   │   │   ├── Soln17_05/
│   │   │   │   ├── LinkedList.cppm
│   │   │   │   └── Soln17_05.cpp
│   │   │   ├── Soln17_06/
│   │   │   │   ├── LinkedList.cppm
│   │   │   │   ├── Pair.cppm
│   │   │   │   ├── Soln17_06.cpp
│   │   │   │   └── SparseArray.cppm
│   │   │   ├── Soln17_07/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── BoxFormatter.cppm
│   │   │   │   └── Soln17_07.cpp
│   │   │   └── Soln17_07A/
│   │   │       ├── Box.cppm
│   │   │       ├── BoxFormatter.cppm
│   │   │       └── Soln17_07A.cpp
│   │   ├── Chapter 18/
│   │   │   ├── Soln18_01/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── RandomBoxes.cppm
│   │   │   │   ├── Soln18_01.cpp
│   │   │   │   ├── Truckload.cpp
│   │   │   │   └── Truckload.cppm
│   │   │   ├── Soln18_02/
│   │   │   │   ├── LinkedList.cppm
│   │   │   │   └── Soln18_02.cpp
│   │   │   ├── Soln18_03/
│   │   │   │   ├── Customer.cpp
│   │   │   │   ├── Customer.cppm
│   │   │   │   ├── DB.cpp
│   │   │   │   ├── DB.h
│   │   │   │   ├── DBException.cppm
│   │   │   │   ├── DB_RAII.cppm
│   │   │   │   └── Soln18_03.cpp
│   │   │   ├── Soln18_04/
│   │   │   │   ├── Customer.cpp
│   │   │   │   ├── Customer.cppm
│   │   │   │   ├── DB.cpp
│   │   │   │   ├── DB.h
│   │   │   │   ├── DBException.cppm
│   │   │   │   ├── DB_RAII.cppm
│   │   │   │   └── Soln18_04.cpp
│   │   │   └── Soln18_05/
│   │   │       ├── Customer.cpp
│   │   │       ├── Customer.cppm
│   │   │       ├── DB.cpp
│   │   │       ├── DB.h
│   │   │       ├── DBException.cppm
│   │   │       ├── DB_RAII.cppm
│   │   │       └── Soln18_05.cpp
│   │   ├── Chapter 19/
│   │   │   ├── Soln19_01/
│   │   │   │   └── Soln19_01.cpp
│   │   │   ├── Soln19_02/
│   │   │   │   ├── Soln19_02.cpp
│   │   │   │   └── Sort.cppm
│   │   │   ├── Soln19_03/
│   │   │   │   ├── BubbleSort.cppm
│   │   │   │   ├── Quicksort.cppm
│   │   │   │   ├── Soln19_03.cpp
│   │   │   │   └── Sort.cppm
│   │   │   ├── Soln19_04/
│   │   │   │   ├── Collect.cppm
│   │   │   │   └── Soln19_04.cpp
│   │   │   └── Soln19_05/
│   │   │       ├── Box.cppm
│   │   │       ├── DeliveryTruck.cpp
│   │   │       ├── DeliveryTruck.cppm
│   │   │       ├── RandomBoxes.cppm
│   │   │       ├── Soln19_05.cpp
│   │   │       ├── Truckload.cpp
│   │   │       └── Truckload.cppm
│   │   ├── Chapter 20/
│   │   │   ├── Soln20_01/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── RandomBoxes.cppm
│   │   │   │   ├── Soln20_01.cpp
│   │   │   │   ├── Truckload.cpp
│   │   │   │   └── Truckload.cppm
│   │   │   ├── Soln20_02/
│   │   │   │   └── Soln20_02.cpp
│   │   │   ├── Soln20_03/
│   │   │   │   └── Soln20_03.cpp
│   │   │   ├── Soln20_03A/
│   │   │   │   └── Soln20_03A.cpp
│   │   │   ├── Soln20_04/
│   │   │   │   └── Soln20_04.cpp
│   │   │   ├── Soln20_05/
│   │   │   │   └── Soln20_05.cpp
│   │   │   ├── Soln20_06/
│   │   │   │   └── Soln20_06.cpp
│   │   │   ├── Soln20_07/
│   │   │   │   └── Soln20_07.cpp
│   │   │   ├── Soln20_08/
│   │   │   │   └── Soln20_08.cpp
│   │   │   ├── Soln20_09/
│   │   │   │   └── Soln20_09.cpp
│   │   │   ├── Soln20_10/
│   │   │   │   └── Soln20_10.cpp
│   │   │   ├── Soln20_11/
│   │   │   │   └── Soln20_11.cpp
│   │   │   ├── Soln20_12/
│   │   │   │   └── Soln20_12.cpp
│   │   │   ├── Soln20_13/
│   │   │   │   └── Soln20_13.cpp
│   │   │   └── Soln20_14/
│   │   │       └── Soln20_14.cpp
│   │   └── Chapter 21/
│   │       ├── Soln21_01/
│   │       │   └── Soln21_01.cpp
│   │       ├── Soln21_02/
│   │       │   └── Soln21_02.cpp
│   │       ├── Soln21_03/
│   │       │   └── Soln21_03.cpp
│   │       ├── Soln21_04/
│   │       │   └── Soln21_04.cpp
│   │       ├── Soln21_05/
│   │       │   └── Soln21_05.cpp
│   │       └── Soln21_06/
│   │           ├── Array.cppm
│   │           └── Soln21_06.cpp
│   ├── NoModules/
│   │   ├── Appendix A/
│   │   │   ├── SolnA_01/
│   │   │   │   ├── ASSERT.h
│   │   │   │   └── SolnA_01.cpp
│   │   │   ├── SolnA_02/
│   │   │   │   ├── ASSERT.h
│   │   │   │   └── SolnA_02.cpp
│   │   │   ├── SolnA_03/
│   │   │   │   ├── SmartException.cpp
│   │   │   │   ├── SmartException.h
│   │   │   │   └── SolnA_03.cpp
│   │   │   ├── SolnA_04/
│   │   │   │   ├── SmartException.h
│   │   │   │   └── SolnA_04.cpp
│   │   │   ├── SolnA_05/
│   │   │   │   ├── Print.cpp
│   │   │   │   ├── PrintThat.cpp
│   │   │   │   ├── PrintThat.h
│   │   │   │   ├── PrintThis.cpp
│   │   │   │   ├── PrintThis.h
│   │   │   │   └── SolnA_05.cpp
│   │   │   ├── SolnA_06/
│   │   │   │   ├── Print.h
│   │   │   │   ├── PrintThat.cpp
│   │   │   │   ├── PrintThat.h
│   │   │   │   ├── PrintThis.cpp
│   │   │   │   ├── PrintThis.h
│   │   │   │   └── SolnA_06.cpp
│   │   │   ├── SolnA_07A/
│   │   │   │   ├── Print.cpp
│   │   │   │   ├── PrintThat.cpp
│   │   │   │   ├── PrintThat.h
│   │   │   │   ├── PrintThis.cpp
│   │   │   │   ├── PrintThis.h
│   │   │   │   └── SolnA_07A.cpp
│   │   │   └── SolnA_07B/
│   │   │       ├── Print.h
│   │   │       ├── PrintThat.cpp
│   │   │       ├── PrintThat.h
│   │   │       ├── PrintThis.cpp
│   │   │       ├── PrintThis.h
│   │   │       └── SolnA_07B.cpp
│   │   ├── Chapter 01/
│   │   │   ├── Exer1_03.cpp
│   │   │   ├── Soln1_01.cpp
│   │   │   └── Soln1_02.cpp
│   │   ├── Chapter 02/
│   │   │   ├── Soln2_01A.cpp
│   │   │   ├── Soln2_01B.cpp
│   │   │   ├── Soln2_02A.cpp
│   │   │   ├── Soln2_02B.cpp
│   │   │   ├── Soln2_03.cpp
│   │   │   ├── Soln2_04.cpp
│   │   │   ├── Soln2_05.cpp
│   │   │   ├── Soln2_06.cpp
│   │   │   ├── Soln2_07.cpp
│   │   │   └── Soln2_08.cpp
│   │   ├── Chapter 03/
│   │   │   ├── Soln3_01.cpp
│   │   │   ├── Soln3_02.cpp
│   │   │   ├── Soln3_03.cpp
│   │   │   ├── Soln3_04.cpp
│   │   │   ├── Soln3_05.cpp
│   │   │   └── Soln3_06.cpp
│   │   ├── Chapter 04/
│   │   │   ├── Soln4_01.cpp
│   │   │   ├── Soln4_02.cpp
│   │   │   ├── Soln4_03.cpp
│   │   │   ├── Soln4_04.cpp
│   │   │   ├── Soln4_05.cpp
│   │   │   ├── Soln4_06.cpp
│   │   │   ├── Soln4_07.cpp
│   │   │   └── Soln4_08.cpp
│   │   ├── Chapter 05/
│   │   │   ├── Soln5_01.cpp
│   │   │   ├── Soln5_02.cpp
│   │   │   ├── Soln5_03.cpp
│   │   │   ├── Soln5_04.cpp
│   │   │   ├── Soln5_05.cpp
│   │   │   ├── Soln5_06.cpp
│   │   │   ├── Soln5_07.cpp
│   │   │   └── Soln5_08.cpp
│   │   ├── Chapter 06/
│   │   │   ├── Soln6_01.cpp
│   │   │   ├── Soln6_02.cpp
│   │   │   ├── Soln6_03.cpp
│   │   │   ├── Soln6_04.cpp
│   │   │   ├── Soln6_05.cpp
│   │   │   └── Soln6_06.cpp
│   │   ├── Chapter 07/
│   │   │   ├── Soln7_01.cpp
│   │   │   ├── Soln7_02.cpp
│   │   │   ├── Soln7_03.cpp
│   │   │   ├── Soln7_04.cpp
│   │   │   ├── Soln7_05.cpp
│   │   │   ├── Soln7_06.cpp
│   │   │   ├── Soln7_07.cpp
│   │   │   ├── Soln7_08A.cpp
│   │   │   ├── Soln7_08B.cpp
│   │   │   ├── Soln7_09A.cpp
│   │   │   └── Soln7_09B.cpp
│   │   ├── Chapter 08/
│   │   │   ├── Soln8_01.cpp
│   │   │   ├── Soln8_02.cpp
│   │   │   ├── Soln8_03.cpp
│   │   │   ├── Soln8_04.cpp
│   │   │   ├── Soln8_05.cpp
│   │   │   ├── Soln8_06.cpp
│   │   │   ├── Soln8_07.cpp
│   │   │   ├── Soln8_07A.cpp
│   │   │   ├── Soln8_08.cpp
│   │   │   └── Soln8_09.cpp
│   │   ├── Chapter 09/
│   │   │   ├── Soln9_01.cpp
│   │   │   ├── Soln9_02.cpp
│   │   │   ├── Soln9_03.cpp
│   │   │   ├── Soln9_04.cpp
│   │   │   ├── Soln9_05.cpp
│   │   │   └── Soln9_06.cpp
│   │   ├── Chapter 10/
│   │   │   ├── Soln10_01.cpp
│   │   │   ├── Soln10_02.cpp
│   │   │   ├── Soln10_03.cpp
│   │   │   ├── Soln10_04.cpp
│   │   │   ├── Soln10_05.cpp
│   │   │   └── Soln10_06.cpp
│   │   ├── Chapter 12/
│   │   │   ├── Soln12_01/
│   │   │   │   ├── Integer.cpp
│   │   │   │   ├── Integer.h
│   │   │   │   └── Soln12_01.cpp
│   │   │   ├── Soln12_02/
│   │   │   │   ├── Integer.cpp
│   │   │   │   ├── Integer.h
│   │   │   │   └── Soln12_02.cpp
│   │   │   ├── Soln12_03/
│   │   │   │   ├── Integer.cpp
│   │   │   │   ├── Integer.h
│   │   │   │   └── Soln12_03.cpp
│   │   │   ├── Soln12_04/
│   │   │   │   ├── Integer.cpp
│   │   │   │   ├── Integer.h
│   │   │   │   └── Soln12_04.cpp
│   │   │   ├── Soln12_05/
│   │   │   │   ├── Integer.cpp
│   │   │   │   ├── Integer.h
│   │   │   │   └── Soln12_05.cpp
│   │   │   ├── Soln12_06/
│   │   │   │   ├── Box.h
│   │   │   │   ├── RandomBoxes.h
│   │   │   │   ├── Soln12_06.cpp
│   │   │   │   ├── Truckload.cpp
│   │   │   │   └── Truckload.h
│   │   │   ├── Soln12_07/
│   │   │   │   ├── Box.h
│   │   │   │   ├── RandomBoxes.h
│   │   │   │   ├── Soln12_07.cpp
│   │   │   │   ├── Truckload.cpp
│   │   │   │   └── Truckload.h
│   │   │   └── Soln12_08/
│   │   │       ├── Box.h
│   │   │       ├── RandomBoxes.h
│   │   │       ├── Soln12_08.cpp
│   │   │       ├── Truckload.cpp
│   │   │       └── Truckload.h
│   │   ├── Chapter 13/
│   │   │   ├── Soln13_01/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.h
│   │   │   │   └── Soln13_01.cpp
│   │   │   ├── Soln13_02/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.h
│   │   │   │   └── Soln13_02.cpp
│   │   │   ├── Soln13_03/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.h
│   │   │   │   └── Soln13_03.cpp
│   │   │   ├── Soln13_04/
│   │   │   │   ├── Box.h
│   │   │   │   └── Soln13_04.cpp
│   │   │   ├── Soln13_05/
│   │   │   │   ├── Box.h
│   │   │   │   └── Soln13_05.cpp
│   │   │   ├── Soln13_06/
│   │   │   │   ├── Box.h
│   │   │   │   └── Soln13_06.cpp
│   │   │   ├── Soln13_07/
│   │   │   │   ├── Rational.h
│   │   │   │   └── Soln13_07.cpp
│   │   │   ├── Soln13_08/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.h
│   │   │   │   ├── PRNG.h
│   │   │   │   └── Soln13_08.cpp
│   │   │   └── Soln13_09/
│   │   │       ├── Box.h
│   │   │       ├── Soln13_09.cpp
│   │   │       ├── Truckload.cpp
│   │   │       └── Truckload.h
│   │   ├── Chapter 14/
│   │   │   ├── Soln14_01/
│   │   │   │   ├── Animals.cpp
│   │   │   │   ├── Animals.h
│   │   │   │   └── Soln14_01.cpp
│   │   │   ├── Soln14_02/
│   │   │   │   ├── Animals.cpp
│   │   │   │   ├── Animals.h
│   │   │   │   └── Soln14_02.cpp
│   │   │   ├── Soln14_03/
│   │   │   │   ├── Animals.cpp
│   │   │   │   ├── Animals.h
│   │   │   │   └── Soln14_03.cpp
│   │   │   └── Soln14_04/
│   │   │       ├── Person.cpp
│   │   │       ├── Person.h
│   │   │       └── Soln14_04.cpp
│   │   ├── Chapter 15/
│   │   │   ├── Soln15_01/
│   │   │   │   ├── Animals.cpp
│   │   │   │   ├── Animals.h
│   │   │   │   ├── Soln15_01.cpp
│   │   │   │   ├── Zoo.cpp
│   │   │   │   └── Zoo.h
│   │   │   ├── Soln15_02/
│   │   │   │   ├── Animals.cpp
│   │   │   │   ├── Animals.h
│   │   │   │   ├── Soln15_02.cpp
│   │   │   │   ├── Zoo.cpp
│   │   │   │   └── Zoo.h
│   │   │   ├── Soln15_03/
│   │   │   │   ├── Animals.cpp
│   │   │   │   ├── Animals.h
│   │   │   │   ├── Soln15_03.cpp
│   │   │   │   ├── Zoo.cpp
│   │   │   │   └── Zoo.h
│   │   │   ├── Soln15_04/
│   │   │   │   ├── Animals.cpp
│   │   │   │   ├── Animals.h
│   │   │   │   ├── Soln15_04.cpp
│   │   │   │   ├── Zoo.cpp
│   │   │   │   └── Zoo.h
│   │   │   ├── Soln15_05/
│   │   │   │   ├── Animals.cpp
│   │   │   │   ├── Animals.h
│   │   │   │   ├── Soln15_05.cpp
│   │   │   │   ├── Zoo.cpp
│   │   │   │   └── Zoo.h
│   │   │   └── Soln15_06/
│   │   │       ├── Point.h
│   │   │       ├── Shapes.h
│   │   │       └── Soln15_06.cpp
│   │   ├── Chapter 16/
│   │   │   ├── Exer16_06/
│   │   │   │   ├── Customer.cpp
│   │   │   │   ├── Customer.h
│   │   │   │   ├── DB.cpp
│   │   │   │   ├── DB.h
│   │   │   │   ├── DBException.h
│   │   │   │   └── Exer16_06.cpp
│   │   │   ├── Soln16_01/
│   │   │   │   ├── Curveball.h
│   │   │   │   └── Soln16_01.cpp
│   │   │   ├── Soln16_02/
│   │   │   │   ├── Curveball.h
│   │   │   │   ├── Soln16_02.cpp
│   │   │   │   └── TooManyExceptions.h
│   │   │   ├── Soln16_03/
│   │   │   │   ├── Box.h
│   │   │   │   ├── RandomBoxes.h
│   │   │   │   ├── Soln16_03.cpp
│   │   │   │   ├── Truckload.cpp
│   │   │   │   └── Truckload.h
│   │   │   ├── Soln16_04/
│   │   │   │   └── Soln16_04.cpp
│   │   │   ├── Soln16_05/
│   │   │   │   ├── Curveball.h
│   │   │   │   ├── DomainExceptions.h
│   │   │   │   └── Soln16_05.cpp
│   │   │   └── Soln16_06/
│   │   │       ├── Customer.cpp
│   │   │       ├── Customer.h
│   │   │       ├── DB.cpp
│   │   │       ├── DB.h
│   │   │       ├── DBException.h
│   │   │       ├── DB_RAII.h
│   │   │       └── Soln16_06.cpp
│   │   ├── Chapter 17/
│   │   │   ├── Soln17_01/
│   │   │   │   ├── Array.h
│   │   │   │   └── Soln17_01.cpp
│   │   │   ├── Soln17_02/
│   │   │   │   ├── Pair.h
│   │   │   │   └── Soln17_02.cpp
│   │   │   ├── Soln17_03/
│   │   │   │   ├── Pair.h
│   │   │   │   └── Soln17_03.cpp
│   │   │   ├── Soln17_04/
│   │   │   │   ├── Pair.h
│   │   │   │   ├── Soln17_04.cpp
│   │   │   │   └── SparseArray.h
│   │   │   ├── Soln17_05/
│   │   │   │   ├── LinkedList.h
│   │   │   │   └── Soln17_05.cpp
│   │   │   ├── Soln17_06/
│   │   │   │   ├── LinkedList.h
│   │   │   │   ├── Pair.h
│   │   │   │   ├── Soln17_06.cpp
│   │   │   │   └── SparseArray.h
│   │   │   ├── Soln17_07/
│   │   │   │   ├── Box.h
│   │   │   │   ├── BoxFormatter.h
│   │   │   │   └── Soln17_07.cpp
│   │   │   └── Soln17_07A/
│   │   │       ├── Box.h
│   │   │       ├── BoxFormatter.h
│   │   │       └── Soln17_07A.cpp
│   │   ├── Chapter 18/
│   │   │   ├── Soln18_01/
│   │   │   │   ├── Box.h
│   │   │   │   ├── RandomBoxes.h
│   │   │   │   ├── Soln18_01.cpp
│   │   │   │   ├── Truckload.cpp
│   │   │   │   └── Truckload.h
│   │   │   ├── Soln18_02/
│   │   │   │   ├── LinkedList.h
│   │   │   │   └── Soln18_02.cpp
│   │   │   ├── Soln18_03/
│   │   │   │   ├── Customer.cpp
│   │   │   │   ├── Customer.h
│   │   │   │   ├── DB.cpp
│   │   │   │   ├── DB.h
│   │   │   │   ├── DBException.h
│   │   │   │   ├── DB_RAII.h
│   │   │   │   └── Soln18_03.cpp
│   │   │   ├── Soln18_04/
│   │   │   │   ├── Customer.cpp
│   │   │   │   ├── Customer.h
│   │   │   │   ├── DB.cpp
│   │   │   │   ├── DB.h
│   │   │   │   ├── DBException.h
│   │   │   │   ├── DB_RAII.h
│   │   │   │   └── Soln18_04.cpp
│   │   │   └── Soln18_05/
│   │   │       ├── Customer.cpp
│   │   │       ├── Customer.h
│   │   │       ├── DB.cpp
│   │   │       ├── DB.h
│   │   │       ├── DBException.h
│   │   │       ├── DB_RAII.h
│   │   │       └── Soln18_05.cpp
│   │   ├── Chapter 19/
│   │   │   ├── Soln19_01/
│   │   │   │   └── Soln19_01.cpp
│   │   │   ├── Soln19_02/
│   │   │   │   ├── Soln19_02.cpp
│   │   │   │   └── Sort.h
│   │   │   ├── Soln19_03/
│   │   │   │   ├── Soln19_03.cpp
│   │   │   │   └── Sort.h
│   │   │   ├── Soln19_04/
│   │   │   │   ├── Collect.h
│   │   │   │   └── Soln19_04.cpp
│   │   │   └── Soln19_05/
│   │   │       ├── Box.h
│   │   │       ├── DeliveryTruck.cpp
│   │   │       ├── DeliveryTruck.h
│   │   │       ├── RandomBoxes.h
│   │   │       ├── Soln19_05.cpp
│   │   │       ├── Truckload.cpp
│   │   │       └── Truckload.h
│   │   ├── Chapter 20/
│   │   │   ├── Soln20_01/
│   │   │   │   ├── Box.h
│   │   │   │   ├── RandomBoxes.h
│   │   │   │   ├── Soln20_01.cpp
│   │   │   │   ├── Truckload.cpp
│   │   │   │   └── Truckload.h
│   │   │   ├── Soln20_02/
│   │   │   │   └── Soln20_02.cpp
│   │   │   ├── Soln20_03/
│   │   │   │   └── Soln20_03.cpp
│   │   │   ├── Soln20_03A/
│   │   │   │   └── Soln20_03A.cpp
│   │   │   ├── Soln20_04/
│   │   │   │   └── Soln20_04.cpp
│   │   │   ├── Soln20_05/
│   │   │   │   └── Soln20_05.cpp
│   │   │   ├── Soln20_06/
│   │   │   │   └── Soln20_06.cpp
│   │   │   ├── Soln20_07/
│   │   │   │   └── Soln20_07.cpp
│   │   │   ├── Soln20_08/
│   │   │   │   └── Soln20_08.cpp
│   │   │   ├── Soln20_09/
│   │   │   │   └── Soln20_09.cpp
│   │   │   ├── Soln20_10/
│   │   │   │   └── Soln20_10.cpp
│   │   │   ├── Soln20_11/
│   │   │   │   └── Soln20_11.cpp
│   │   │   ├── Soln20_12/
│   │   │   │   └── Soln20_12.cpp
│   │   │   ├── Soln20_13/
│   │   │   │   └── Soln20_13.cpp
│   │   │   └── Soln20_14/
│   │   │       └── Soln20_14.cpp
│   │   └── Chapter 21/
│   │       ├── Soln21_01/
│   │       │   └── Soln21_01.cpp
│   │       ├── Soln21_02/
│   │       │   └── Soln21_02.cpp
│   │       ├── Soln21_03/
│   │       │   └── Soln21_03.cpp
│   │       ├── Soln21_04/
│   │       │   └── Soln21_04.cpp
│   │       ├── Soln21_05/
│   │       │   └── Soln21_05.cpp
│   │       └── Soln21_06/
│   │           ├── Array.h
│   │           └── Soln21_06.cpp
│   └── README.md
├── LICENSE.txt
├── README.md
├── Workarounds/
│   ├── README.md
│   ├── format
│   └── ranges
└── errata.md

================================================
FILE CONTENTS
================================================

================================================
FILE: .gitmodules
================================================
[submodule "Workarounds/fmt"]
	path = Workarounds/fmt
	url = https://github.com/fmtlib/fmt.git
[submodule "Workarounds/range-v3"]
	path = Workarounds/range-v3
	url = https://github.com/ericniebler/range-v3


================================================
FILE: Contributing.md
================================================
# Contributing to Apress Source Code

Copyright for Apress source code belongs to the author(s). However, under fair use you are encouraged to fork and contribute minor corrections and updates for the benefit of the author(s) and other readers.

## How to Contribute

1. Make sure you have a GitHub account.
2. Fork the repository for the relevant book.
3. Create a new branch on which to make your change, e.g. 
`git checkout -b my_code_contribution`
4. Commit your change. Include a commit message describing the correction. Please note that if your commit message is not clear, the correction will not be accepted.
5. Submit a pull request.

Thank you for your contribution!

================================================
FILE: Examples/Modules/Chapter 01/Ex1_01.cpp
================================================
// A complete C++ program
import <iostream>;

int main()
{
  int answer {42};              // Defines answer with value 42

  std::cout << "The answer to life, the universe, and everything is "
            << answer
            << std::endl;

  return 0;
}


================================================
FILE: Examples/Modules/Chapter 01/Ex1_02.cpp
================================================
// Using escape sequences
import <iostream>;

int main()
{
  std::cout << "\"Least \'said\' \\\n\t\tsoonest \'mended\'.\"" << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 02/Ex2_01.cpp
================================================
// Writing values of variables to cout
import <iostream>;    // For user input and output through std::cin / cout

int main()
{
  int apple_count {15};                            // Number of apples
  int orange_count {5};                            // Number of oranges
  int total_fruit {apple_count + orange_count};    // Total number of fruit

  std::cout << "The value of apple_count is "  << apple_count  << std::endl;
  std::cout << "The value of orange_count is " << orange_count << std::endl;
  std::cout << "The value of total_fruit is "  << total_fruit  << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 02/Ex2_02.cpp
================================================
// Converting distances
import <iostream>;    // For user input and output through std::cin / cout

int main() 
{
  unsigned int yards {}, feet {}, inches {};
 
  // Convert a distance in yards, feet, and inches to inches
  std::cout << "Enter a distance as yards, feet, and inches "
            << "with the three values separated by spaces: "; 
  std::cin >> yards >> feet >> inches;

  const unsigned feet_per_yard {3};
  const unsigned inches_per_foot {12};
  
  unsigned total_inches {};
  total_inches = inches + inches_per_foot * (yards*feet_per_yard + feet);
  std::cout << "The distances corresponds to " << total_inches << " inches.\n";

  // Convert a distance in inches to yards feet and inches
  std::cout << "Enter a distance in inches: ";
  std::cin >> total_inches;
  feet   = total_inches / inches_per_foot;
  inches = total_inches % inches_per_foot;
  yards  = feet / feet_per_yard;
  feet   = feet % feet_per_yard;
  std::cout << "The distances corresponds to "
            << yards  << " yards " 
            << feet   << " feet "
            << inches << " inches." << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 02/Ex2_03.cpp
================================================
// Sizing a pond for happy fish
import <iostream>;
import <numbers>;   // For the pi constant

#include <cmath>    // For the square root function

int main()
{
  // 2 square feet pond surface for every 6 inches of fish
  const double fish_factor { 2.0/0.5 };  // Area per unit length of fish
  const double inches_per_foot { 12.0 };

  double fish_count {};            // Number of fish
  double fish_length {};           // Average length of fish

  std::cout << "Enter the number of fish you want to keep: ";
  std::cin >> fish_count;
  std::cout << "Enter the average fish length in inches: ";
  std::cin >> fish_length;
  fish_length /= inches_per_foot;  // Convert to feet
  std::cout << '\n';

  // Calculate the required surface area
  const double pond_area {fish_count * fish_length * fish_factor};

  // Calculate the pond diameter from the area
  const double pond_diameter {2.0 * std::sqrt(pond_area / std::numbers::pi)};

  std::cout << "Pond diameter required for " << fish_count << " fish is "
            << pond_diameter << " feet.\n";
}


================================================
FILE: Examples/Modules/Chapter 02/Ex2_03A.cpp
================================================
// Expressions with mixed variables types
// (The difference with the original example 
//  is the type of fish_count and inches_per_foot)
import <iostream>;
import <numbers>;   // For the pi constant

#include <cmath>    // For the square root function

int main()
{
  // 2 square feet pond surface for every 6 inches of fish
  const double fish_factor { 2.0/0.5 };       // Area per unit length of fish
  const unsigned int inches_per_foot { 12 };  // <-- Used to be of type double

  unsigned int fish_count {};  // Number of fish (used to be of type double as well)
  double fish_length {};       // Average length of fish

  std::cout << "Enter the number of fish you want to keep: ";
  std::cin >> fish_count;
  std::cout << "Enter the average fish length in inches: ";
  std::cin >> fish_length;
  fish_length /= inches_per_foot;  // Convert to feet
  std::cout << '\n';

  // Calculate the required surface area
  const double pond_area {fish_count * fish_length * fish_factor};

  // Calculate the pond diameter from the area
  const double pond_diameter {2.0 * std::sqrt(pond_area / std::numbers::pi)};

  std::cout << "Pond diameter required for " << fish_count << " fish is "
            << pond_diameter << " feet.\n";
}


================================================
FILE: Examples/Modules/Chapter 02/Ex2_03B.cpp
================================================
// Formatting text using std::format()
import <iostream>;
import <format>;
import <numbers>;   // For the pi constant

#include <cmath>    // For the square root function

int main()
{
  // 2 square feet pond surface for every 6 inches of fish
  const double fish_factor{ 2.0 / 0.5 };       // Area per unit length of fish
  const unsigned int inches_per_foot{ 12 };

  unsigned int fish_count{};  // Number of fish
  double fish_length{};       // Average length of fish

  std::cout << "Enter the number of fish you want to keep: ";
  std::cin >> fish_count;
  std::cout << "Enter the average fish length in inches: ";
  std::cin >> fish_length;
  fish_length /= inches_per_foot;  // Convert to feet
  std::cout << '\n';

  // Calculate the required surface area
  const double pond_area{ fish_count * fish_length * fish_factor };

  // Calculate the pond diameter from the area
  const double pond_diameter{ 2.0 * std::sqrt(pond_area / std::numbers::pi) };

  std::cout << std::format("Pond diameter required for {} fish is {} feet.\n",
                           fish_count, pond_diameter);
}


================================================
FILE: Examples/Modules/Chapter 02/Ex2_03C.cpp
================================================
// Format specifiers for std::format()
import <iostream>;
import <format>;
import <numbers>;   // For the pi constant

#include <cmath>    // For the square root function

int main()
{
  // 2 square feet pond surface for every 6 inches of fish
  const double fish_factor{ 2.0 / 0.5 };       // Area per unit length of fish
  const unsigned int inches_per_foot{ 12 };

  unsigned int fish_count{};  // Number of fish
  double fish_length{};       // Average length of fish

  std::cout << "Enter the number of fish you want to keep: ";
  std::cin >> fish_count;
  std::cout << "Enter the average fish length in inches: ";
  std::cin >> fish_length;
  fish_length /= inches_per_foot;  // Convert to feet
  std::cout << '\n';

  // Calculate the required surface area
  const double pond_area{ fish_count * fish_length * fish_factor };

  // Calculate the pond diameter from the area
  const double pond_diameter{ 2.0 * std::sqrt(pond_area / std::numbers::pi) };

  std::cout << std::format("Pond diameter required for {} fish is {:.2} feet.\n",
                           fish_count, pond_diameter);
}


================================================
FILE: Examples/Modules/Chapter 02/Ex2_03D.cpp
================================================
// Debugging format specifiers for std::format() using try/catch
import <iostream>;
import <format>;
import <numbers>;   // For the pi constant

#include <cmath>    // For the square root function

int main()
{
  // 2 square feet pond surface for every 6 inches of fish
  const double fish_factor{ 2.0 / 0.5 };       // Area per unit length of fish
  const unsigned int inches_per_foot{ 12 };

  unsigned int fish_count{};  // Number of fish
  double fish_length{};       // Average length of fish

  std::cout << "Enter the number of fish you want to keep: ";
  std::cin >> fish_count;
  std::cout << "Enter the average fish length in inches: ";
  std::cin >> fish_length;
  fish_length /= inches_per_foot;  // Convert to feet
  std::cout << '\n';

  // Calculate the required surface area
  const double pond_area{ fish_count * fish_length * fish_factor };

  // Calculate the pond diameter from the area
  const double pond_diameter{ 2.0 * std::sqrt(pond_area / std::numbers::pi) };

  try
  {
    std::cout << std::format("Pond diameter required for {:.2} fish is {:.2} feet.\n",
                             fish_count, pond_diameter);
  }
  catch (const std::format_error& error)
  {
    std::cout << error.what();  // Outputs "precision not allowed for this argument type"
  }
}

================================================
FILE: Examples/Modules/Chapter 02/Ex2_04.cpp
================================================
// Using explicit type conversions
import <iostream>;

int main()
{
  const unsigned feet_per_yard{ 3 };
  const unsigned inches_per_foot{ 12 };
  const unsigned inches_per_yard{ feet_per_yard * inches_per_foot };

  double length{};        // Length as decimal yards
  unsigned int yards{};   // Whole yards
  unsigned int feet{};    // Whole feet
  unsigned int inches{};  // Whole inches

  std::cout << "Enter a length in yards as a decimal: ";
  std::cin >> length;

  // Get the length as yards, feet, and inches
  yards = static_cast<unsigned int>(length);
  feet = static_cast<unsigned int>((length - yards) * feet_per_yard);
  inches = static_cast<unsigned int>(length * inches_per_yard) % inches_per_foot;

  std::cout << length << " yards converts to "
    << yards << " yards "
    << feet << " feet "
    << inches << " inches." << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 02/Ex2_05.cpp
================================================
// The width, alignment, fill, and 0 formatting options of std::format() 
import <iostream>;
import <format>;

int main()
{
  // Default alignment: right for numbers, left otherwise
  std::cout << std::format("{:7}|{:7}|{:7}|{:7}|{:7}\n", 1, -.2, "str", 'c', true);
  // Left and right alignment + custom fill character
  std::cout << std::format("{:*<7}|{:*<7}|{:*>7}|{:*>7}|{:*>7}\n", 1, -.2, "str", 'c', true);
  // Centered alignment + 0 formatting option for numbers
  std::cout << std::format("{:^07}|{:^07}|{:^7}|{:^7}|{:^7}\n", 1, -.2, "str", 'c', true);
}


================================================
FILE: Examples/Modules/Chapter 02/Ex2_06.cpp
================================================
// Formatting numeric values with std::format() 
import <iostream>;
import <format>;
import <numbers>;

int main()
{
  const double pi{ std::numbers::pi };
  std::cout << std::format("Default: {:.2}, fixed: {:.2f}, scientific: {:.2e}, "
    "general: {:.2g}\n", pi, pi, pi, pi);
  std::cout << std::format("Default: {}, binary: {:b}, hex.: {:x}\n", 314, 314, 314);
  std::cout << std::format("Default: {}, decimal: {:d}, hex.: {:x}\n", 'c', 'c', 'c');
  std::cout << std::format("Alternative hex.: {:#x}, binary: {:#b}, HEX.: {:#X}\n",
    314, 314, 314);
  std::cout << std::format("Forced sign: {:+}, space sign: {: }\n", 314, 314);
  std::cout << std::format("All together: {:*<+10.4f}, {:+#09x}\n", pi, 314);
}


================================================
FILE: Examples/Modules/Chapter 02/Ex2_06B.cpp
================================================
// Argument indices for std::format()
import <iostream>;
import <format>;
import <numbers>;

int main()
{
  const double pi{ std::numbers::pi };
  std::cout << std::format("Default: {:.2}, fixed: {:.2f}, scientific: {:.2e}, "
    "general: {:.2g}\n", pi, pi, pi, pi);
  std::cout << std::format("Default: {0}, binary: {0:b}, hex.: {0:x}\n", 314);
  std::cout << std::format("Default: {0}, decimal: {0:d}, hex.: {0:x}\n", 'c');
  std::cout << std::format("Alternative hex.: {0:#x}, binary: {0:#b}, HEX.: {0:#X}\n", 314);
  std::cout << std::format("Forced sign: {0:+}, space sign: {0: }\n", 314);
  std::cout << std::format("All together: {:*<+10.4f}, {:+#09x}\n", pi, 314);
}


================================================
FILE: Examples/Modules/Chapter 02/Ex2_07.cpp
================================================
// Finding maximum and minimum values for data types
import <iostream>;
import <limits>;
import <format>;

int main()
{
  std::cout
    << std::format("The range for type short is from {} to {}\n",
      std::numeric_limits<short>::min(), std::numeric_limits<short>::max())
    << std::format("The range for type unsigned int is from {} to {}\n",
      std::numeric_limits<unsigned int>::min(),
      std::numeric_limits<unsigned int>::max())
    << std::format("The range for type long is from {} to {}\n",
      std::numeric_limits<long>::min(), std::numeric_limits<long>::max())
    << std::format("The positive range for type float is from {} to {}\n",
      std::numeric_limits<float>::min(), std::numeric_limits<float>::max())
    << std::format("The full range for type float is from {} to {}\n",
      std::numeric_limits<float>::lowest(), std::numeric_limits<float>::max())
    << std::format("The positive range for type double is from {} to {}\n",
      std::numeric_limits<double>::min(),
      std::numeric_limits<double>::max())
    << std::format("The positive range for type long double is from {} to {}\n",
      std::numeric_limits<long double>::min(),
      std::numeric_limits<long double>::max());
}


================================================
FILE: Examples/Modules/Chapter 03/Ex3_01.cpp
================================================
// Using the bitwise operators
import <iostream>;
import <format>;

int main()
{
  const unsigned int red{ 0xFF0000u };   // Color red
  const unsigned int white{ 0xFFFFFFu }; // Color white - RGB all maximum

  std::cout << "Try out bitwise complement, AND and OR operators:\n";
  std::cout << std::format("Initial value:       red = {:08X}\n", red);
  std::cout << std::format("Complement:         ~red = {:08X}\n", ~red);

  std::cout << std::format("Initial value:     white = {:08X}\n", white);
  std::cout << std::format("Complement:       ~white = {:08X}\n", ~white);

  std::cout << std::format("Bitwise AND: red & white = {:08X}\n", red & white);
  std::cout << std::format("Bitwise  OR: red | white = {:08X}\n", red | white);

  std::cout << "\nNow try successive exclusive OR operations:\n";
  unsigned int mask{ red ^ white };
  std::cout << std::format("mask = red ^ white = {:08X}\n", mask);
  std::cout << std::format("        mask ^ red = {:08X}\n", mask ^ red);
  std::cout << std::format("      mask ^ white = {:08X}\n", mask ^ white);

  unsigned int flags{ 0xFF };            // Flags variable
  unsigned int bit1mask{ 0x1 };          // Selects bit 1
  unsigned int bit6mask{ 0b100000 };     // Selects bit 6
  unsigned int bit20mask{ 1u << 19 };    // Selects bit 20

  std::cout << "Use masks to select or set a particular flag bit:\n";
  std::cout << std::format("Select bit 1 from flags  : {:08X}\n", flags & bit1mask);
  std::cout << std::format("Select bit 6 from flags  : {:08X}\n", flags & bit6mask);
  std::cout << std::format("Switch off bit 6 in flags: {:08X}\n", flags &= ~bit6mask);
  std::cout << std::format("Switch on bit 20 in flags: {:08X}\n", flags |= bit20mask);
}


================================================
FILE: Examples/Modules/Chapter 03/Ex3_02.cpp
================================================
// Demonstrating scope, lifetime, and global variables
import <iostream>;

long count1{999L};         // Global count1
double count2{3.14};       // Global count2
int count3;                // Global count3 - default initialization

int main()
{ /* Function scope starts here */
  int count1{10};          // Hides global count1
  int count3{50};          // Hides global count3
  std::cout << "Value of outer count1 = "  << count1 << std::endl;
  std::cout << "Value of global count1 = " << ::count1 << std::endl;
  std::cout << "Value of global count2 = " << count2 << std::endl;

  { /* New block scope starts here... */
    int count1{20};        // This is a new variable that hides the outer count1
    int count2{30};        // This hides global count2
    std::cout << "\nValue of inner count1 = "<< count1 << std::endl;
    std::cout << "Value of global count1 = " << ::count1 << std::endl;
    std::cout << "Value of inner count2 = "  << count2 << std::endl;
    std::cout << "Value of global count2 = " << ::count2 << std::endl;

    count1 = ::count1 + 3;   // This sets inner count1 to global count1+3
    ++::count1;              // This changes global count1
    std::cout << "\nValue of inner count1 = " << count1 << std::endl;
    std::cout << "Value of global count1 = "  << ::count1 << std::endl;
    count3 += count2;        // Increments outer count3 by inner count2;

    int count4 {};
  } /* ...and ends here. */

// std::cout << count4 << std::endl;    // count4 does not exist in this scope!

  std::cout << "\nValue of outer count1 = "<< count1 << std::endl
            << "Value of outer count3 = "  << count3 << std::endl;
  std::cout << "Value of global count3 = " << ::count3 << std::endl;

  std::cout << "Value of global count2 = " << count2 << std::endl;
} /* Function scope ends here */


================================================
FILE: Examples/Modules/Chapter 03/Ex3_03.cpp
================================================
// Operations with enumerations
import <iostream>;
import <format>;

int main()
{
  enum class Day { Monday, Tuesday, Wednesday, Thursday, Friday, Saturday, Sunday };
  Day yesterday{ Day::Monday }, today{ Day::Tuesday }, tomorrow{ Day::Wednesday };
  const Day poets_day{ Day::Friday };

  enum class Punctuation : char { Comma = ',', Exclamation = '!', Question = '?' };
  Punctuation ch{ Punctuation::Comma };

  std::cout << std::format("yesterday's value is {}{} but poets_day's is {}{}\n",
    static_cast<int>(yesterday), static_cast<char>(ch),
    static_cast<int>(poets_day), static_cast<char>(Punctuation::Exclamation));

  today = Day::Thursday;        // Assign new ...
  ch = Punctuation::Question;   // ... enumerator values
  tomorrow = poets_day;         // Copy enumerator value

  std::cout << std::format("Is today's value({}) the same as poets_day({}){}\n",
    static_cast<int>(today), static_cast<int>(poets_day), static_cast<char>(ch));

  //   ch = tomorrow;             /* Uncomment any of these for an error */
  //   tomorrow = Friday;
  //   today = 6;
}


================================================
FILE: Examples/Modules/Chapter 04/Ex4_01.cpp
================================================
// Comparing data values
import <iostream>;

int main()
{
  char first {};      // Stores the first character
  char second {};     // Stores the second character

  std::cout << "Enter a character: ";
  std::cin >> first;

  std::cout << "Enter a second character: ";
  std::cin >> second;

  // std::cout << std::boolalpha;   /* Output true/false instead of 1/0 */

  std::cout << "The value of the expression " << first << '<' << second
            << " is " << (first < second) << std::endl;
  std::cout << "The value of the expression " << first << "==" << second
            << " is " << (first == second) << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 04/Ex4_01A.cpp
================================================
// Comparing data values (output using std::format())
import <iostream>;
import <format>;

int main()
{
  char first {};      // Stores the first character
  char second {};     // Stores the second character

  std::cout << "Enter a character: ";
  std::cin >> first;

  std::cout << "Enter a second character: ";
  std::cin >> second;

  std::cout << std::format("The value of the expression {} < {} is {}\n",
                           first, second, first < second);
  std::cout << std::format("The value of the expression {} == {} is {}\n",
                           first, second, first == second);
}


================================================
FILE: Examples/Modules/Chapter 04/Ex4_02.cpp
================================================
// Three-way comparison of integers
import <compare>;  // Required when using operator <=> (even for fundamental types)
import <format>;
import <iostream>;

int main()
{
  std::cout << "Please enter a number: ";

  int value;
  std::cin >> value;

  std::strong_ordering ordering{ value <=> 0 };

  std::cout << std::format("value < 0: {}\n", ordering == std::strong_ordering::less);
  std::cout << std::format("value > 0: {}\n", ordering == std::strong_ordering::greater);
  std::cout << std::format("value == 0: {}\n", ordering == std::strong_ordering::equal);
}


================================================
FILE: Examples/Modules/Chapter 04/Ex4_02A.cpp
================================================
// Using the named comparison functions
import <compare>;  // Required when using operator <=> (even for fundamental types)
import <format>;
import <iostream>;

int main()
{
  std::cout << "Please enter a number: ";

  int value;
  std::cin >> value;

  std::strong_ordering ordering{ value <=> 0 };

  std::cout << std::format("value < 0: {}\n", std::is_lt(ordering));  // is less than
  std::cout << std::format("value > 0: {}\n", std::is_gt(ordering));  // is greater than
  std::cout << std::format("value == 0: {}\n", std::is_eq(ordering)); // is equivalent
}


================================================
FILE: Examples/Modules/Chapter 04/Ex4_03.cpp
================================================
// Using an if statement
import <iostream>;

int main()
{
  std::cout << "Enter an integer between 50 and 100: ";

  int value {};
  std::cin >> value;

  if (value)
    std::cout << "You have entered a value that is different from zero." << std::endl;

  if (value < 50)
    std::cout << "The value is invalid - it is less than 50." << std::endl;

  if (value > 100)
    std::cout << "The value is invalid - it is greater than 100." << std::endl;

  std::cout << "You entered " << value << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 04/Ex4_04.cpp
================================================
// Using a nested if
import <iostream>;

int main()
{
  char letter {};                      // Store input here
  std::cout << "Enter a letter: ";     // Prompt for the input
  std::cin >> letter;

  if (letter >= 'A')
  {                                    // letter is 'A' or larger
    if (letter <= 'Z')
    {                                  // letter is 'Z' or smaller
      std::cout << "You entered an uppercase letter." << std::endl;
      return 0;
    }
  }

  if (letter >= 'a')                   // Test for 'a' or larger
    if (letter <= 'z')
    {                                  // letter is >= 'a' and <= 'z'
      std::cout << "You entered a lowercase letter." << std::endl;
      return 0;
    }
  std::cout << "You did not enter a letter." << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 04/Ex4_04A.cpp
================================================
// Using the std::isupper() / islower() character classification functions
import <iostream>;

#include <cctype>

int main()
{
  char letter {};                      // Store input here
  std::cout << "Enter a letter: ";     // Prompt for the input
  std::cin >> letter;

  if (std::isupper(letter))
  {
    std::cout << "You entered an uppercase letter." << std::endl;
    return 0;
  }

  if (std::islower(letter))
  {
    std::cout << "You entered a lowercase letter." << std::endl;
    return 0;
  }

  std::cout << "You did not enter a letter." << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 04/Ex4_05.cpp
================================================
// Using the if-else statement
import <iostream>;

int main()
{
  long number {};      // Stores input
  std::cout << "Enter an integer less than 2 billion: ";
  std::cin >> number;

  if (number % 2) // Test remainder after division by 2
  { // Here if remainder is 1
    std::cout << "Your number is odd." << std::endl;
  }
  else
  { // Here if remainder is 0
    std::cout << "Your number is even." << std::endl;
  }
}


================================================
FILE: Examples/Modules/Chapter 04/Ex4_06.cpp
================================================
// Combining logical operators for loan approval
import <iostream>;

int main()
{
  int age {};                  // Age of the prospective borrower
  int income {};               // Income of the prospective borrower
  int balance {};              // Current bank balance

  // Get the basic data for assessing the loan
  std::cout << "Please enter your age in years: ";
  std::cin  >> age;
  std::cout << "Please enter your annual income in dollars: ";
  std::cin  >> income;
  std::cout << "What is your current account balance in dollars: ";
  std::cin  >> balance;

  // We only lend to people who are at least 21 years of age,
  // who make over $25,000 per year,
  // or have over $100,000 in their account, or both.
  if (age >= 21 && (income > 25'000 || balance > 100'000))
  {
    // OK, you are good for the loan - but how much?
    // This will be the lesser of twice income and half balance
    int loan {};               // Stores maximum loan amount
    if (2*income < balance/2)
    {
      loan = 2*income;
    }
    else
    {
      loan = balance/2;
    }
    std::cout << "\nYou can borrow up to $" << loan << std::endl;
  }
  else     // No loan for you...
  {
    std::cout << "\nUnfortunately, you don't qualify for a loan." << std::endl;
  }
}


================================================
FILE: Examples/Modules/Chapter 04/Ex4_07.cpp
================================================
// Using the conditional operator to select output.
import <iostream>;
import <format>;

int main()
{
  int mice {};               // Count of all mice
  int brown {};              // Count of brown mice
  int white {};              // Count of white mice

  std::cout << "How many brown mice do you have? ";
  std::cin >> brown;
  std::cout << "How many white mice do you have? ";
  std::cin >> white;

  mice = brown + white;

  std::cout << 
    std::format("You have {} {} in total.\n", mice, mice == 1 ? "mouse" : "mice");
}


================================================
FILE: Examples/Modules/Chapter 04/Ex4_08.cpp
================================================
// Using the switch statement
import <iostream>;

int main()
{
  std::cout << "Your electronic recipe book is at your service.\n"
            << "You can choose from the following delicious dishes:\n"
            << "1. Boiled eggs\n"
            << "2. Fried eggs\n"
            << "3. Scrambled eggs\n"
            << "4. Coddled eggs\n\n"
            << "Enter your selection number: ";

  int choice {};  // Stores selection value
  std::cin >> choice;

  switch (choice)
  {
  case 1:
    std::cout << "Boil some eggs." << std::endl;
    break;
  case 2:
    std::cout << "Fry some eggs." << std::endl;
    break;
  case 3:
    std::cout << "Scramble some eggs." << std::endl;
    break;
  case 4:
    std::cout << "Coddle some eggs."  << std::endl;
    break;
  default:
    std::cout << "You entered a wrong number - try raw eggs." << std::endl;
  }
}


================================================
FILE: Examples/Modules/Chapter 04/Ex4_09.cpp
================================================
// Multiple case actions
import <iostream>;

#include <cctype>

int main()
{
  char letter {};
  std::cout << "Enter a letter: ";
  std::cin >> letter;

  if (std::isalpha(letter))
  {
    switch (std::tolower(letter))
    {
    case 'a': case 'e': case 'i': case 'o': case 'u':
      std::cout << "You entered a vowel." << std::endl;
      break;
    default:
      std::cout << "You entered a consonant." << std::endl;
      break;
    }
  }
  else
  {
    std::cout << "You did not enter a letter." << std::endl;
  }
}


================================================
FILE: Examples/Modules/Chapter 04/Ex4_09A.cpp
================================================
// Using a return statement to exit a switch statement
import <iostream>;

#include <cctype>

int main()
{
  char letter {};
  std::cout << "Enter a letter: ";
  std::cin >> letter;

  if (std::isalpha(letter))
  {
    switch (std::tolower(letter))
    {
    case 'a': case 'e': case 'i': case 'o': case 'u':
      std::cout << "You entered a vowel." << std::endl;
      return 0;                               // Ends the program
    }

    // We did not exit main() in the above switch, so letter is not a vowel:
    std::cout << "You entered a consonant." << std::endl;
  }
  else
  {
    std::cout << "You did not enter a letter." << std::endl;
  }
}


================================================
FILE: Examples/Modules/Chapter 05/Ex5_01.cpp
================================================
// Using a for loop with an array
import <iostream>;

int main()
{
  const unsigned size {6};                        // Array size
  unsigned height[size] {26, 37, 47, 55, 62, 75}; // An array of heights

  unsigned total {};                              // Sum of heights
  for (size_t i {}; i < size; ++i)
  {
    total += height[i];
  }

  const unsigned average {total/size};            // Calculate average height
  std::cout << "The average height is " << average << std::endl;

  unsigned count {};
  for (size_t i {}; i < size; ++i)
  {
    if (height[i] < average) ++count;
  }
  std::cout << count << " people are below average height." << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 05/Ex5_02.cpp
================================================
// Obtaining the number of array elements
import <iostream>;
import <array>;       // for std::size()

int main()
{
  int values[] {2, 3, 5, 7, 11, 13, 17, 19, 23, 29};

  std::cout << "There are " << std::size(values) << " elements in the array.\n";

  int sum {};
  const size_t old_school_size{ sizeof(values) / sizeof(values[0]) };
  for (size_t i {}; i < old_school_size; ++i)
  {
    sum += values[i];
  }
  std::cout << "The sum of the array elements is " << sum << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 05/Ex5_03.cpp
================================================
// Floating-point control in a for loop
import <format>;
import <iostream>;
import <numbers>;

int main()
{
  const size_t values_per_line {3}; // Outputs per line
  size_t values_current_line {};    // Number of outputs on current line
  for (double radius {0.2}; radius <= 3.0; radius += 0.2)
  {
    const auto area{ std::numbers::pi * radius * radius };
    std::cout << std::format("radius = {:4.2f}, area = {:5.2f}; ", radius, area);
    if (++values_current_line == values_per_line)  // When enough values written...
    {
      std::cout << std::endl;    // ...start a new line...
      values_current_line = 0;   // ...and reset the line counter
    }
  }
  std::cout << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 05/Ex5_03A.cpp
================================================
// Floating-point control in a for loop
import <format>;
import <iostream>;
import <numbers>;

int main()
{
  const size_t values_per_line {3}; // Outputs per line
  size_t values_current_line {};    // Number of outputs on current line
  for (double radius {0.2}; radius < 3.0 + 0.001; radius += 0.2)
  {
    const auto area{ std::numbers::pi * radius * radius };
    std::cout << std::format("radius = {:4.2f}, area = {:5.2f}; ", radius, area);
    if (++values_current_line == values_per_line)  // When enough values written...
    {
      std::cout << std::endl;    // ...start a new line...
      values_current_line = 0;   // ...and reset the line counter
    }
  }
  std::cout << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 05/Ex5_04.cpp
================================================
// Multiple initializations in a loop expression
import <iostream>;
import <format>;

int main()
{
  unsigned int limit {};
  std::cout << "This program calculates n! and the sum of the integers "
            << "up to n for values 1 to limit.\n";
  std::cout << "What upper limit for n would you like? ";
  std::cin >> limit;

  // The format string for all rows of the table
  const auto table_format{ "{:>8} {:>8} {:>20}\n" };
  
  // Output column headings
  std::cout << std::format(table_format, "integer", "sum", "factorial"); 

  for (unsigned long long n {1}, sum {}, factorial {1}; n <= limit; ++n)
  {
    sum += n;           // Accumulate sum to current n
    factorial *= n;     // Calculate n! for current n
    std::cout << std::format(table_format, n, sum, factorial);
  }
}


================================================
FILE: Examples/Modules/Chapter 05/Ex5_04A.cpp
================================================
// Multiple calculations in a loop expression's third control expression
// by using the comma operator
import <iostream>;
import <format>;

int main() 
{
  unsigned int limit {};
  std::cout << "This program calculates n! and the sum of the integers "
            << "up to n for values 1 to limit.\n";
  std::cout << "What upper limit for n would you like? ";
  std::cin >> limit;

  // The format string for all rows of the table
  const auto table_format{ "{:>8} {:>8} {:>20}\n" };
  
  // Output column headings
  std::cout << std::format(table_format, "integer", "sum", "factorial"); 

  for (unsigned long long n {1}, sum {1}, factorial {1}; n <= limit; 
                                  ++n, sum += n, factorial *= n)
  {
    std::cout << std::format(table_format, n, sum, factorial);
  }
}


================================================
FILE: Examples/Modules/Chapter 05/Ex5_05.cpp
================================================
// Using a while loop to calculate the sum of integers from 1 to n and n!
import <iostream>;
import <format>;

int main()
{
  unsigned int limit {};
  std::cout << "This program calculates n! and the sum of the integers "
            << "up to n for values 1 to limit.\n";
  std::cout << "What upper limit for n would you like? ";
  std::cin >> limit;

  // The format string for all rows of the table
  const auto table_format{ "{:>8} {:>8} {:>20}\n" };
  
  // Output column headings
  std::cout << std::format(table_format, "integer", "sum", "factorial"); 

  unsigned int n {};
  unsigned int sum {};
  unsigned long long factorial {1ULL};

  while (++n <= limit)
  {
    sum += n;                    // Accumulate sum to current n
    factorial *= n;              // Calculate n! for current n
    std::cout << std::format(table_format, n, sum, factorial);
  }
}


================================================
FILE: Examples/Modules/Chapter 05/Ex5_06.cpp
================================================
// Using a do-while loop to manage input
import <iostream>;

#include <cctype>                                  // For tolower() function

int main()
{
  char reply {};                                   // Stores response to prompt for input
  int count {};                                    // Counts the number of input values
  double temperature {};                           // Stores an input value
  double total {};                                 // Stores the sum of all input values
  do
  {
    std::cout << "Enter a temperature reading: ";  // Prompt for input
    std::cin >> temperature;                       // Read input value

    total += temperature;                          // Accumulate total of values
    ++count;                                       // Increment count

    std::cout << "Do you want to enter another? (y/n): ";
    std::cin >> reply;                             // Get response
  } while (std::tolower(reply) == 'y');

  std::cout << "The average temperature is " << total/count << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 05/Ex5_07.cpp
================================================
// Generating multiplication tables using nested loops
import <iostream>;
import <format>;

#include <cctype>

int main()
{
  size_t table {};              // Table size
  const size_t table_min {2};   // Minimum table size - at least up to the 2-times
  const size_t table_max {12};  // Maximum table size
  char reply {};                // Response to prompt

  do
  {
    std::cout << 
      std::format("What size table would you like ({} to {})? ", table_min, table_max);
    std::cin >> table;          // Get the table size
    std::cout << std::endl;

    // Make sure table size is within the limits
    if (table < table_min || table > table_max)
    {
      std::cout << "Invalid table size entered. Program terminated." << std::endl;
      return 1;
    }

    // Create the top line of the table
    std::cout << std::format("{:>6}", '|');
    for (size_t i {1}; i <= table; ++i)
    {
      std::cout << std::format(" {:3} |", i);
    }
    std::cout << std::endl;

    // Create the separator row
    for (size_t i {}; i <= table; ++i)
    {
      std::cout << "------";
    }
    std::cout << std::endl;

    for (size_t i {1}; i <= table; ++i)
    {    // Iterate over rows
      std::cout << std::format(" {:3} |", i);      // Start the row

      // Output the values in a row
      for (size_t j {1}; j <= table; ++j)
      {
        std::cout << std::format(" {:3} |", i*j);  // For each column
      }
      std::cout << std::endl;                      // End the row
    }

    // Check if another table is required
    std::cout << "\nDo you want another table (y or n)? ";
    std::cin >> reply;

  } while (std::tolower(reply) == 'y');
}


================================================
FILE: Examples/Modules/Chapter 05/Ex5_07A.cpp
================================================
// Generating multiplication tables using nested loops
// In this version an indefinite for loop is used, in combination with break statements.
import <iostream>;
import <format>;

#include <cctype>		// for std::tolower()

int main()
{
  size_t table {};              // Table size
  const size_t table_min {2};   // Minimum table size - at least up to the 2-times
  const size_t table_max {12};  // Maximum table size
  char reply {};                // Response to prompt

  const size_t max_tries{ 3 };   // Max. number of times a user can try entering a table size
  do
  {
    for (size_t count{ 1 }; ; ++count)  // Indefinite loop
    {
      std::cout <<
        std::format("What size table would you like ({} to {})? ", table_min, table_max);
      std::cin >> table; // Get the table size

      // Make sure table size is within the limits
      if (table >= table_min && table <= table_max)
      {
        break;      // Exit the input loop
      }
      else if (count < max_tries)
      {
        std::cout << "Invalid input - try again.\n";
      }
      else
      {
        std::cout << "Invalid table size entered - yet again!\nSorry, only "
          << max_tries << " allowed - program terminated." << std::endl;
        return 1;
      }
    }


    // Create the top line of the table
    std::cout << std::format("{:>6}", '|');
    for (size_t i {1}; i <= table; ++i)
    {
      std::cout << std::format(" {:3} |", i);
    }
    std::cout << std::endl;

    // Create the separator row
    for (size_t i {}; i <= table; ++i)
    {
      std::cout << "------";
    }
    std::cout << std::endl;

    for (size_t i {1}; i <= table; ++i)
    {    // Iterate over rows
      std::cout << std::format(" {:3} |", i);      // Start the row

      // Output the values in a row
      for (size_t j {1}; j <= table; ++j)
      {
        std::cout << std::format(" {:3} |", i*j);  // For each column
      }
      std::cout << std::endl;                      // End the row
    }

    // Check if another table is required
    std::cout << "\nDo you want another table (y or n)? ";
    std::cin >> reply;

  } while (std::tolower(reply) == 'y');
}


================================================
FILE: Examples/Modules/Chapter 05/Ex5_08.cpp
================================================
// Using the continue statement to display ASCII character codes
import <iostream>;
import <format>;

#include <cctype>

int main()
{
  const auto header_format{ "{:^11}{:^11}{:^11}\n" };    // 3 cols., 11 wide, centered (^)
  const auto body_format{ "{0:^11}{0:^11X}{0:^11d}\n" }; // Print same argument three times

  std::cout << std::format(header_format, "Character", "Hexadecimal", "Decimal");

  // Output 7-bit ASCII characters and corresponding codes
  char ch{};
  do
  {
    if (!std::isprint(ch))  // If it's not printable...
      continue;             // ...skip this iteration
    std::cout << std::format(body_format, ch);
  } while (ch++ < 127);
}


================================================
FILE: Examples/Modules/Chapter 05/Ex5_09.cpp
================================================
// Sorting an array in ascending sequence - using an indefinite while loop
import <iostream>;
import <format>;

int main()
{
  const size_t size {1000};     // Array size
  double x[size] {};            // Stores data to be sorted
  size_t count {};              // Number of values in array

  while (true)
  {
    double input {};            // Temporary store for a value
    std::cout << "Enter a non-zero value, or 0 to end: ";
    std::cin >> input;
    if (input == 0)
      break;

    x[count] = input;

    if (++count == size)
    {
      std::cout << "Sorry, I can only store " << size << " values.\n";
      break;
    }
  }

  if (count == 0)
  {
    std::cout << "Nothing to sort..." << std::endl;
    return 0;
  }

  std::cout << "Starting sort..." << std::endl;

  while (true)
  {
    bool swapped{ false };    // Becomes true when not all values are in order
    for (size_t i {}; i < count - 1; ++i)
    {
      if (x[i] > x[i + 1])    // Out of order so swap them
      {
        const auto temp{ x[i] };
        x[i] = x[i+1];
        x[i + 1] = temp;
        swapped = true;
      }
    }

    if (!swapped)    // If there were no swaps
      break;         // ...all values are in order...
  }                  // ...otherwise, go round again.

  std::cout << "Your data in ascending sequence:\n";
  const size_t perline {10};         // Number output per line
  size_t n {};                       // Number on current line
  for (size_t i {}; i < count; ++i)
  {
    std::cout << std::format("{:8.1f}", x[i]);
    if (++n == perline)              // When perline have been written...
    {
      std::cout << std::endl;        // Start a new line and...
      n = 0;                         // ...reset count on this line
    }
  }
  std::cout << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 05/Ex5_10.cpp
================================================
// Classifying the letters in a C-style string
import <iostream>;

#include <cctype>

int main()
{
  const int max_length {100};   // Array size
  char text[max_length] {};     // Array to hold input string

  std::cout << "Enter a line of text:" << std::endl;

  // Read a line of characters including spaces
  std::cin.getline(text, max_length);
  std::cout << "You entered:\n" << text << std::endl;

  size_t vowels {};            // Count of vowels
  size_t consonants {};        // Count of consonants
  for (int i {}; text[i] != '\0'; i++)
  {
    if (std::isalpha(text[i]))         // If it is a letter...
    {
      switch (std::tolower(text[i]))
      {                                // ...check lowercase...
        case 'a': case 'e': case 'i': case 'o': case 'u':
          ++vowels;                    // ...it is a vowel
          break;

        default:
          ++consonants;                    // ...it is a consonant
      }
    }
  }
  std::cout << "Your input contained " << vowels << " vowels and "
            << consonants << " consonants." << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 05/Ex5_11.cpp
================================================
// Working with strings in an array
import <iostream>;
import <array>; // for std::size()

int main()
{
  const size_t max_length{ 80 };      // Maximum string length (including \0)
  char stars[][max_length]{
                          "Fatty Arbuckle",  "Clara Bow",
                          "Lassie",          "Slim Pickens",
                          "Boris Karloff",   "Mae West",
                          "Oliver Hardy",    "Greta Garbo"
  };
  size_t choice{};

  std::cout << "Pick a lucky star! Enter a number between 1 and "
    << std::size(stars) << ": ";
  std::cin >> choice;

  if (choice >= 1 && choice <= std::size(stars))
  {
    std::cout << "Your lucky star is " << stars[choice - 1] << std::endl;
  }
  else
  {
    std::cout << "Sorry, you haven't got a lucky star." << std::endl;
  }
}


================================================
FILE: Examples/Modules/Chapter 05/Ex5_12.cpp
================================================
// Allocating an array at runtime
// This example does not work with some compilers (such as Visual C++)
// because dynamic arrays is not standard C++ (it is valid C though).
import <iostream>;
import <format>;

#ifdef _MSC_VER   // See Appendix A for an explanation of preprocessing macros
  #error Visual Studio does not support variable length arrays (not standard C++)
#endif

int main()
{
  size_t count {};
  std::cout << "How many heights will you enter? ";
  std::cin >> count;
  int height[count];            // Create the array of count elements

  // Read the heights
  size_t entered {};
  while (entered < count)
  {
    std::cout <<"Enter a height (in inches): ";
    std::cin >> height[entered];
    if (height[entered] > 0)    // Make sure value is positive
    {
      ++entered;
    }
    else
    {
      std::cout << "A height must be positive - try again.\n";
    }
  }

  // Calculate the sum of the heights
  unsigned int total {};
  for (size_t i {}; i < count; ++i)
  {
    total += height[i];
  }
  std::cout << std::format("The average height is {:.1f}\n",
                              static_cast<float>(total) / count);
}


================================================
FILE: Examples/Modules/Chapter 05/Ex5_12A.cpp
================================================
// Allocating an array at runtime (for loop merged into preceding while loop)
// This example does not work with some compilers (such as Visual C++)
// because dynamic arrays is not standard C++ (it is valid C though).
import <iostream>;
import <format>;

#ifdef _MSC_VER   // See Appendix A for an explanation of preprocessing macros
  #error Visual Studio does not support variable length arrays (not standard C++)
#endif

int main()
{
  size_t count {};
  std::cout << "How many heights will you enter? ";
  std::cin >> count;
  int height[count];            // Create the array of count elements

  // Read the heights
  unsigned int total {};
  size_t entered {};
  while (entered < count)
  {
    std::cout << "Enter a height (in inches): ";
    std::cin >> height[entered];
    if (height[entered] > 0)          // Make sure value is positive
    {
      total += height[entered++];
    }
    else
    {
      std::cout << "A height must be positive - try again.\n";
    }
  }

  std::cout << std::format("The average height is {:.1f}\n",
                              static_cast<float>(total) / count);
}


================================================
FILE: Examples/Modules/Chapter 05/Ex5_13.cpp
================================================
// Comparing array<> objects and plain arrays
import <iostream>;
import <array>;

int main()
{
  {
    std::cout << "First we try out the comparison operators for std::array<> objects:" << std::endl;
	
    std::array<double,4> these {1.0, 2.0, 3.0, 4.0};
    std::array<double,4> those {1.0, 2.0, 3.0, 4.0};
    std::array<double,4> them  {1.0, 1.0, 5.0, 5.0};

    if (these == those) std::cout << "these and those are equal."    << std::endl;
    if (those != them)  std::cout << "those and them are not equal." << std::endl;
    if (those > them)   std::cout << "those are greater than them."  << std::endl;
    if (them < those)   std::cout << "them are less than those."     << std::endl;
  }
  
  std::cout << std::endl;
  
  {
	  std::cout << "Next we repeat exactly the same comparisons with plain C++ arrays:" << std::endl;
    double these[4] {1.0, 2.0, 3.0, 4.0};
    double those[4] {1.0, 2.0, 3.0, 4.0};
    double them[4]  {1.0, 1.0, 5.0, 5.0};

    if (these == those) std::cout << "these and those are equal."    << std::endl;
    if (those != them)  std::cout << "those and them are not equal." << std::endl;
    if (those > them)   std::cout << "those are greater than them."  << std::endl;
    if (them < those)   std::cout << "them are less than those."     << std::endl;
  }
  
  /* The explanation of why this does not work as expected with plain arrays follows in Chapter 6 */
}



================================================
FILE: Examples/Modules/Chapter 05/Ex5_14.cpp
================================================
// Using array<T,N> to create Body Mass Index (BMI) table
// BMI = weight/(height*height)
// weight in kilograms, height in meters

import <iostream>;
import <format>;
import <array>;        // For array<T,N>

int main()
{
  const unsigned min_wt {100};     // Minimum weight in table (in pounds)
  const unsigned max_wt {250};     // Maximum weight in table
  const unsigned wt_step {10};
  const size_t wt_count {1 + (max_wt - min_wt) / wt_step};

  const unsigned min_ht {48};      // Minimum height in table (inches)
  const unsigned max_ht {84};      // Maximum height in table
  const unsigned ht_step {2};
  const size_t ht_count { 1 + (max_ht - min_ht) / ht_step };

  const double lbs_per_kg {2.2};   // Pounds per kilogram
  const double ins_per_m {39.37};  // Inches per meter
  std::array<unsigned, wt_count> weight_lbs {};
  std::array<unsigned, ht_count> height_ins {};

  // Create weights from 100lbs in steps of 10lbs
  for (unsigned i{}, w{ min_wt }; i < wt_count; w += wt_step, ++i)
  {
    weight_lbs[i] = w;
  }
  // Create heights from 48 inches in steps of 2 inches
  for (unsigned i{}, h{ min_ht }; h <= max_ht; h += ht_step)
  {
    height_ins.at(i++) = h;
  }
  // Output table headings
  std::cout << std::format("{:>8}", '|');
  for (auto w : weight_lbs)
    std::cout << std::format("{:^6}|", w);
  std::cout << std::endl;
  
  // Output line below headings
  for (unsigned i{1}; i < wt_count; ++i)
    std::cout << "--------";
  std::cout << std::endl;

  const unsigned int inches_per_foot {12U};
  for (auto h : height_ins)
  {
    const unsigned feet{ h / inches_per_foot };
    const unsigned inches{ h % inches_per_foot };
    std::cout << std::format("{:2}'{:2}\" |", feet, inches);

    const double h_m{ h / ins_per_m };     // Height in meter
    for (auto w : weight_lbs)
    {
      const double w_kg = w / lbs_per_kg; // Weight in kilogram
      const double bmi = w_kg / (h_m * h_m);
      std::cout << std::format(" {:2.1f} |", bmi);
    }
    std::cout << std::endl;
  }
  // Output line below table
  for (size_t i {1}; i < wt_count; ++i)
    std::cout << "--------";
  std::cout << "\nBMI from 18.5 to 24.9 is normal" << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 05/Ex5_15.cpp
================================================
// Sorting an array in ascending sequence - using a vector<T> container
import <iostream>;
import <format>;
import <vector>;

int main()
{
  std::vector<double> x;    // Stores data to be sorted

  while (true)
  {
    double input {};        // Temporary store for a value
    std::cout << "Enter a non-zero value, or 0 to end: ";
    std::cin >> input;
    if (input == 0)
      break;

    x.push_back(input);
  }

  if (x.empty())
  {
    std::cout << "Nothing to sort..." << std::endl;
    return 0;
  }

  std::cout << "Starting sort." << std::endl;

  while (true)
  {
    bool swapped{ false };   // Becomes true when not all values are in order
    for (size_t i {}; i < x.size() - 1; ++i)
    {
      if (x[i] > x[i + 1])   // Out of order so swap them
      {
        const auto temp{ x[i] };
        x[i] = x[i+1];
        x[i + 1] = temp;
        swapped = true;
      }
    }

    if (!swapped)   // If there were no swaps
      break;        // ...all values are in order...
  }                 // ...otherwise, go round again.

  std::cout << "Your data in ascending sequence:\n";
  const size_t perline {10};   // Number output per line
  size_t n {};                 // Number on current line
  for (size_t i {}; i < x.size(); ++i)
  {
    std::cout << std::format("{:8.1f}", x[i]);
    if (++n == perline)        // When perline have been written...
    {
      std::cout << std::endl;  // Start a new line and...
      n = 0;                   // ...reset count on this line
    }
  }
  std::cout << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 06/Ex6_01.cpp
================================================
// The size of pointers
import <iostream>;

int main()
{
  // Print out the size (in number of bytes) of some data types
  // and the corresponding pointer types:
  std::cout << sizeof(double)  << " > "  << sizeof(char16_t)  << std::endl;
  std::cout << sizeof(double*) << " == " << sizeof(char16_t*) << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 06/Ex6_02.cpp
================================================
// Dereferencing pointers
// Calculates the purchase price for a given quantity of items
import <iostream>;
import <format>;

int main()
{
  int unit_price {295};                // Item unit price in cents
  int count {};                        // Number of items ordered
  int discount_threshold {25};         // Quantity threshold for discount
  double discount {0.07};              // Discount for quantities over discount_threshold

  int* pcount {&count};                // Pointer to count
  std::cout << "Enter the number of items you want: ";
  std::cin >> *pcount;
  std::cout << std::format("The unit price is ${:.2f}\n", unit_price / 100.0);

  // Calculate gross price
  int* punit_price{ &unit_price };      // Pointer to unit_price
  int price{ *pcount * *punit_price };  // Gross price via pointers
  auto* pprice {&price};                // Pointer to gross price

  // Calculate net price in US$
  double net_price{};
  double* pnet_price {nullptr};
  pnet_price = &net_price;
  if (*pcount > discount_threshold)
  {
    std::cout << 
      std::format("You qualify for a discount of {:.0f} percent.\n", discount * 100);
    *pnet_price = price*(1 - discount) / 100;
  }
  else
  {
    net_price = *pprice / 100;
  }
  std::cout << std::format("The net price for {} items is ${:.2f}\n", *pcount, net_price);
}


================================================
FILE: Examples/Modules/Chapter 06/Ex6_03.cpp
================================================
// Initializing pointers with strings
import <iostream>;

int main()
{
  const char* pstar1 {"Fatty Arbuckle"};
  const char* pstar2 {"Clara Bow"};
  const char* pstar3 {"Lassie"};
  const char* pstar4 {"Slim Pickens"};
  const char* pstar5 {"Boris Karloff"};
  const char* pstar6 {"Mae West"};
  const char* pstar7 {"Oliver Hardy"};
  const char* pstar8 {"Greta Garbo"};
  const char* pstr {"Your lucky star is "};

  std::cout << "Pick a lucky star! Enter a number between 1 and 8: ";
  size_t choice {};
  std::cin >> choice;

  switch (choice)
  {
  case 1: std::cout << pstr << pstar1 << std::endl; break;
  case 2: std::cout << pstr << pstar2 << std::endl; break;
  case 3: std::cout << pstr << pstar3 << std::endl; break;
  case 4: std::cout << pstr << pstar4 << std::endl; break;
  case 5: std::cout << pstr << pstar5 << std::endl; break;
  case 6: std::cout << pstr << pstar6 << std::endl; break;
  case 7: std::cout << pstr << pstar7 << std::endl; break;
  case 8: std::cout << pstr << pstar8 << std::endl; break;
  default: std::cout << "Sorry, you haven't got a lucky star." << std::endl;
  }
}


================================================
FILE: Examples/Modules/Chapter 06/Ex6_04.cpp
================================================
// Using an array of pointers
import <iostream>;
import <array>;      // for std::size()

int main()
{
  const char* pstars[] {
                         "Fatty Arbuckle", "Clara Bow", "Lassie", 
                         "Slim Pickens", "Boris Karloff", "Mae West",
                         "Oliver Hardy", "Greta Garbo"
                       };

  std::cout << "Pick a lucky star! Enter a number between 1 and "
            << std::size(pstars) << ": ";
  size_t choice {};
  std::cin >> choice;

  if (choice >= 1 && choice <= std::size(pstars))
  {
    std::cout << "Your lucky star is " << pstars[choice - 1] << std::endl;
  }
  else
  {
    std::cout << "Sorry, you haven't got a lucky star." << std::endl;
  }
}


================================================
FILE: Examples/Modules/Chapter 06/Ex6_05.cpp
================================================
// Calculating primes using pointer notation
import <iostream>;
import <format>;

int main()
{
  const size_t max {100};    // Number of primes required
  long primes[max] {2L};     // First prime defined
  size_t count {1};          // Count of primes found so far
  long trial {3L};           // Candidate prime

  while (count < max)
  {
    bool isprime {true}; // Indicates when a prime is found

    // Try dividing the candidate by all the primes we have
    for (size_t i {}; i < count && isprime; ++i)
    {
      isprime = trial % *(primes + i) > 0;   // False for exact division
    }

    if (isprime)
    {                              // We got one...
      *(primes + count++) = trial; // ...so save it in primes array
    }

    trial += 2;                    // Next value for checking
  }

  // Output primes 10 to a line
  std::cout << "The first " << max << " primes are:" << std::endl;
  for (size_t i{}; i < max; ++i)
  {
    std::cout << std::format("{:7}", *(primes + i));
    if ((i+1) % 10 == 0)           // Newline after every 10th prime
      std::cout << std::endl;
  }
  std::cout << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 06/Ex6_06.cpp
================================================
// Calculating primes using dynamic memory allocation
import <iostream>;
import <format>;

#include <cmath>       // For square root function (std::sqrt())

int main()
{
  size_t max {};       // Number of primes required

  std::cout << "How many primes would you like? ";
  std::cin >> max;          // Read number required

  if (max == 0) return 0;   // Zero primes: do nothing

  auto* primes {new unsigned[max]};  // Allocate memory for max primes

  size_t count {1};         // Count of primes found
  primes[0] = 2;            // Insert first seed prime

  unsigned trial {3};       // Initial candidate prime

  while (count < max)
  {
    bool isprime {true};    // Indicates when a prime is found

    const auto limit = static_cast<unsigned>(std::sqrt(trial));
    for (size_t i {}; primes[i] <= limit && isprime; ++i)
    {
      isprime = trial % primes[i] > 0;  // False for exact division
    }

    if (isprime)                // We got one...
      primes[count++] = trial;  // ...so save it in primes array

    trial += 2;                 // Next value for checking
  }

  // Output primes 10 to a line
  for (size_t i{}; i < max; ++i)
  {
    std::cout << std::format("{:10}", primes[i]);
    if ((i + 1) % 10 == 0)      // After every 10th prime...
      std::cout << std::endl;   // ...start a new line
  }
  std::cout << std::endl;

  delete[] primes;              // Free up memory...
  primes = nullptr;             // ... and reset the pointer
}


================================================
FILE: Examples/Modules/Chapter 06/Ex6_07.cpp
================================================
// Using smart pointers
import <iostream>;
import <format>;
import <memory>;   // For smart pointers
import <vector>;   // For std::vector<> container

#include <cctype>  // For std::toupper()

int main()
{
  std::vector<std::shared_ptr<std::vector<double>>> records; // Temperature records by days
  size_t day{ 1 };       // Day number

  while (true)           // Collect temperatures by day
  {
    // Vector to store current day's temperatures created in the free store
    auto day_records{ std::make_shared<std::vector<double>>() };
    records.push_back(day_records);   // Save pointer in records vector

    std::cout << "Enter the temperatures for day " << day++
              << " separated by spaces. Enter 1000 to end:\n";

    while (true)
    { // Get temperatures for current day
      double t{};        // A temperature
      std::cin >> t;
      if (t == 1000.0) break;

      day_records->push_back(t);
    }

    std::cout << "Enter another day's temperatures (Y or N)? ";
    char answer{};
    std::cin >> answer;
    if (std::toupper(answer) != 'Y') break;
  }

  day = 1;

  for (auto record : records)
  {
    double total{};
    size_t count{};

    std::cout << std::format("\nTemperatures for day {}:\n", day++);
    for (auto temp : *record)
    {
      total += temp;
      std::cout << std::format("{:6.2f}", temp);
      if (++count % 5 == 0) std::cout << std::endl;
    }

    std::cout << std::format("\nAverage temperature: {:.2f}", total / count) << std::endl;
  }
}


================================================
FILE: Examples/Modules/Chapter 08/Ex8_01.cpp
================================================
// Calculating powers
import <iostream>;
import <format>;

// Function to calculate x to the power n
double power(double x, int n)
{
  double result{ 1.0 };
  if (n >= 0)
  {
    for (int i{ 1 }; i <= n; ++i)
      result *= x;
  }
  else // n < 0
  {
    for (int i{ 1 }; i <= -n; ++i)
      result /= x;
  }
  return result;
}

int main()
{
  // Calculate powers of 8 from -3 to +3
  for (int i{ -3 }; i <= 3; ++i)
    std::cout << std::format("{:10g}", power(8.0, i));

  std::cout << std::endl;
}



================================================
FILE: Examples/Modules/Chapter 08/Ex8_02.cpp
================================================
// Calculating powers - rearranged
import <iostream>;
import <format>;

//double power(double x, int n);               // Function prototype - uncomment for successful compilation

int main()
{
  // Calculate powers of 8 from -3 to +3
  for (int i{ -3 }; i <= 3; ++i)
    std::cout << std::format("{:10}", power(8.0, i));

  std::cout << std::endl;
}

// Function to calculate x to the power n
double power(double x, int n)
{
  double result{ 1.0 };
  if (n >= 0)
  {
    for (int i{ 1 }; i <= n; ++i)
      result *= x;
  }
  else // n < 0
  {
    for (int i{ 1 }; i <= -n; ++i)
      result /= x;
  }
  return result;
}



================================================
FILE: Examples/Modules/Chapter 08/Ex8_03.cpp
================================================
// Failing to modify the original value of a function argument
import <iostream>;

double changeIt(double value_to_be_changed);    // Function prototype

int main()  
{
  double it {5.0};
  double result {changeIt(it)};

  std::cout << "After function execution, it = " << it
            << "\nResult returned is " << result << std::endl;
}

// Function that attempts to modify an argument and return it
double changeIt(double it)
{
  it += 10.0;                       // This modifies the copy
  std::cout << "Within function, it = " << it << std::endl;
  return it;
}


================================================
FILE: Examples/Modules/Chapter 08/Ex8_04.cpp
================================================
// Modifying the value of a caller variable
import <iostream>;

double changeIt(double* pointer_to_it);    // Function prototype

int main()
{
  double it {5.0};
  double result {changeIt(&it)};      // Now we pass the address

  std::cout << "After function execution, it = " << it
            << "\nResult returned is " << result << std::endl;
}

// Function to modify an argument and return it
double changeIt(double* pit)
{
  *pit += 10.0;             // This modifies the original double
  std::cout << "Within function, *pit = " << *pit << std::endl;
  return *pit;
}


================================================
FILE: Examples/Modules/Chapter 08/Ex8_05.cpp
================================================
// Passing an array to a function
import <iostream>;
import <array>;          // For std::size()

double average(double array[], size_t count);   // Function prototype

int main()
{
  double values[] {1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0, 9.0, 10.0};
  std::cout << "Average = " << average(values, std::size(values)) << std::endl;
}

// Function to compute an average
double average(double array[], size_t count)
{
  double sum {};                       // Accumulate total in here
  for (size_t i {}; i < count; ++i)
    sum += array[i];                   // Sum array elements
  return sum / count;                  // Return average
}


================================================
FILE: Examples/Modules/Chapter 08/Ex8_05A.cpp
================================================
// Passing an array to a function - false expectations
// Note: with main() as defined in this file, 
// this program will likely either crash or produce garbage output!
import <iostream>;

double average10(double array[10]);        // Function prototype

int main()
{
 // double values[] { 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0, 9.0, 10.0 };
  double values[] { 1.0, 2.0, 3.0 };           // Only three values!!!
  std::cout << "Average = " << average10(values) << std::endl;
}

// Function to compute an average
double average10(double array[10])         /* The [10] does not mean what you might expect! */
{
  double sum{};                            // Accumulate total in here
  for (size_t i{} ; i < 10; ++i)
    sum += array[i];                       // Sum array elements
  return sum / 10;                         // Return average
}


================================================
FILE: Examples/Modules/Chapter 08/Ex8_06.cpp
================================================
// Passing a two-dimensional array to a function
import <iostream>;
import <array>;	          // For std::size()

double yield(const double values[][4], size_t n);

int main()
{
  double beans[3][4] {  { 1.0,   2.0,   3.0,   4.0},
                        { 5.0,   6.0,   7.0,   8.0},
                        { 9.0,  10.0,  11.0,  12.0}  };

  std::cout << "Yield = " << yield(beans, std::size(beans))
            << std::endl;
}

// Function to compute total yield
double yield(const double array[][4], size_t size)
{
  double sum  {};
  for (size_t i {}; i < size; ++i)   // Loop through rows
  {
    for (size_t j {}; j < std::size(array[i]); ++j) // Loop through elements in a row
    {
      sum += array[i][j];
    }
  }
  return sum;
}


================================================
FILE: Examples/Modules/Chapter 08/Ex8_06A.cpp
================================================
// Passing a two-dimensional array to a function (range-based for loop)
import <iostream>;
import <array>;	          // For std::size()

double yield(const double values[][4], size_t n);

int main()
{
  double beans[3][4]{ { 1.0,   2.0,   3.0,   4.0},
                        { 5.0,   6.0,   7.0,   8.0},
                        { 9.0,  10.0,  11.0,  12.0} };

  std::cout << "Yield = " << yield(beans, std::size(beans))
    << std::endl;
}

// Function to compute total yield
double yield(const double array[][4], size_t size)
{
  double sum{};
  for (size_t i{}; i < size; ++i)  // Loop through rows
  {
    for (double val : array[i])    // Loop through elements in a row
    {
      sum += val;
    }
  }
  return sum;
}



================================================
FILE: Examples/Modules/Chapter 08/Ex8_07.cpp
================================================
// Modifying the value of a caller variable  references vs pointers
import <iostream>;

void change_it_by_pointer(double* reference_to_it);    // Pass pointer (by value)
void change_it_by_reference(double& reference_to_it);  // Pass by reference

int main()
{
  double it {5.0};

  change_it_by_pointer(&it);         // Now we pass the address
  std::cout << "After first function execution, it = " << it << std::endl;

  change_it_by_reference(it);        // Now we pass a reference, not the value!
  std::cout << "After second function execution, it = " << it << std::endl;
}

void change_it_by_pointer(double* pit)
{
  *pit += 10.0;       // This modifies the original double
}
void change_it_by_reference(double& pit)
{
  pit += 10.0;        // This modifies the original double as well!
}


================================================
FILE: Examples/Modules/Chapter 08/Ex8_08.cpp
================================================
// Using a reference parameter
import <iostream>;
import <format>;
import <string>;
import <vector>;

using std::string;
using std::vector;

void find_words(vector<string>& words, const string& str, const string& separators);
void list_words(const vector<string>& words);

int main()
{
  std::string text;         // The string to be searched
  std::cout << "Enter some text terminated by *:\n";
  std::getline(std::cin, text, '*');

  const std::string separators {" ,;:.\"!?'\n"};  // Word delimiters
  std::vector<std::string> words;                 // Words found

  find_words(words, text, separators);
  list_words(words);
}

void find_words(vector<string>& words, const string& text, const string& separators)
{
  size_t start {text.find_first_not_of(separators)};     // First word start index

  while (start != string::npos)                          // Find the words
  {
    size_t end{ text.find_first_of(separators, start + 1) }; // Find end of word
    if (end == string::npos)                             // Found a separator?
      end = text.length();                               // No, so set to end of text

    words.push_back(text.substr(start, end - start));    // Store the word
    start = text.find_first_not_of(separators, end + 1); // Find 1st character of next word
  }
}

void list_words(const vector<string>& words)
{
  std::cout << "Your string contains the following " << words.size() << " words:\n";
  size_t count {};                 // Number of outputted words
  for (const auto& word : words)
  {
    std::cout << std::format("{:>15}", word);
    if (!(++count % 5))
      std::cout << std::endl;
  }
  std::cout << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 08/Ex8_09A.cpp
================================================
// Passing an array to a function - pass by reference
// Note: with main() as defined in this file, this program will not compile...
import <iostream>;

double average10(const double (&)[10]);        // Function prototype

int main()
{
  // Use 10 values to make example compile...
 // double values[] { 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0, 9.0, 10.0 };
  double values[] { 1.0, 2.0, 3.0 };           // Only three values!!!
  std::cout << "Average = " << average10(values) << std::endl;
}

// Function to compute an average
double average10(const double (&array)[10])   /* Only arrays of length 10 can be passed! */
{
  double sum {};                       // Accumulate total in here
  for (size_t i {}; i < 10; ++i)
    sum += array[i];                   // Sum array elements
  return sum / 10;                     // Return average
}


================================================
FILE: Examples/Modules/Chapter 08/Ex8_09B.cpp
================================================
// Passing an array to a function - pass by reference improved
import <iostream>;
import <array>;          // for std::size()

double average10(const double (&)[10]);        // Function prototype

int main()
{
  double values[] { 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0, 9.0, 10.0 };
 // double values[] { 1.0, 2.0, 3.0 };           // Only three values!!!
  std::cout << "Average = " << average10(values) << std::endl;
}

// Function to compute an average
double average10(const double (&array)[10])
{
  double sum {};                       // Accumulate total in here
  for (double val : array)
    sum += val;                        // Sum array elements
  return sum / std::size(array);       // Return average
}

================================================
FILE: Examples/Modules/Chapter 08/Ex8_09C.cpp
================================================
// Passing an array to a function - use std::array<>
import <iostream>;
import <array>;

double average10(const std::array<double,10>& array);        // Function prototype

int main()
{
  std::array<double,10> values{ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0, 9.0, 10.0 };
 // std::array<double,3> values{ 1.0, 2.0, 3.0 };           // Only three values!!!
  std::cout << "Average = " << average10(values) << std::endl;
}

// Function to compute an average
double average10(const std::array<double,10>& array)
{
  double sum {};                       // Accumulate total in here
  for (double val : array)
    sum += val;                        // Sum array elements
  return sum / array.size();           // Return average
}

================================================
FILE: Examples/Modules/Chapter 08/Ex8_10.cpp
================================================
// Implicit conversions of reference parameters
import <iostream>;

void double_it(double& it)      { it *= 2; }
void print_it(const double& it) { std::cout << it << std::endl; }

int main()
{
  double d{123};
  double_it(d);
  print_it(d);

  int i{456};
  // double_it(i);        /* error, does not compile! */
  print_it(i);
}


================================================
FILE: Examples/Modules/Chapter 08/Ex8_11.cpp
================================================
// Using multiple default parameter values
import <iostream>;
import <format>;
import <string>;

// The function prototype including defaults for parameters
void show_data(const int data[], size_t count = 1,  
               const std::string& title = "Data Values",
               size_t width = 10, size_t perLine = 5);
int main()
{
  int samples[] {1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12};

  int dataItem {-99};
  show_data(&dataItem);

  dataItem = 13;
  show_data(&dataItem, 1, "Unlucky for some!");

  show_data(samples, std::size(samples));
  show_data(samples, std::size(samples), "Samples");
  show_data(samples, std::size(samples), "Samples", 6);
  show_data(samples, std::size(samples), "Samples", 8, 4);
}

void show_data(const int data[], size_t count, const std::string& title, 
               size_t width, size_t perLine)
{
  std::cout << title << std::endl;    // Display the title

  // Output the data values
  for (size_t i {}; i < count; ++i)
  {
    std::cout << std::format("{:{}}", data[i], width); // Display a data item
    if ((i+1) % perLine == 0)                          // Newline after perLine values
      std::cout << '\n';
  }
  std::cout << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 08/Ex8_12.cpp
================================================
// Program that lists its command line arguments
import <iostream>;

int  main(int argc, char* argv[])
{
  for (int i{}; i < argc; ++i)
    std::cout << argv[i] << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 08/Ex8_13.cpp
================================================
// Returning a pointer
import <iostream>;
import <format>;
import <string>;
import <array>;                  // for std::size()

void show_data(const double data[], size_t count = 1, 
               const std::string& title = "Data Values",
               size_t width = 10, size_t perLine = 5);
const double* largest(const double data[], size_t count);
const double* smallest(const double data[], size_t count);
double* shift_range(double data[], size_t count, double delta);
double* scale_range(double data[], size_t count, double divisor);
double* normalize_range(double data[], size_t count);

int main()
{
  double samples[] {
                     11.0,  23.0,  13.0,  4.0,
                     57.0,  36.0, 317.0, 88.0,
                      9.0, 100.0, 121.0, 12.0
                   };

  const size_t count{std::size(samples)};              // Number of samples
  show_data(samples, count, "Original Values");        // Output original values
  normalize_range(samples, count);                     // Normalize the values
  show_data(samples, count, "Normalized Values", 12);  // Output normalized values
}

// Outputs an array of double values
void show_data(const double data[], size_t count, 
               const std::string& title, size_t width, size_t perLine)
{
  std::cout << title << std::endl;  // Display the title

  // Output the data values
  for (size_t i {}; i < count; ++i)
  {
    // Display a data item (uses a dynamic field width: see Chapter 7)
    std::cout << std::format("{:{}.6g}", data[i], width); 
    if ((i + 1) % perLine == 0)     // Newline after perLine values
      std::cout << '\n';
  }
  std::cout << std::endl;
}

const double* smallest(const double data[], size_t count)
{
  if (!count) return nullptr;     // There is no smallest in an empty array

  size_t index_min {};
  for (size_t i {1}; i < count; ++i)
    if (data[index_min] > data[i])
      index_min = i;

  return &data[index_min];
}

double* shift_range(double data[], size_t count, double delta)
{
  for (size_t i {}; i < count; ++i)
    data[i] += delta;
  return data;
}

const double* largest(const double data[], size_t count)
{
  if (!count) return nullptr;    // There is no largest in an empty array

  size_t index_max {};
  for (size_t i {1}; i < count; ++i)
    if (data[index_max] < data[i])
      index_max = i;

  return &data[index_max];
}

double* scale_range(double data[], size_t count, double divisor)
{
  if (!divisor) return data;     // Do nothing for a zero divisor

  for (size_t i{}; i < count; ++i)
    data[i] /= divisor;
  return data;
}

double* normalize_range(double data[], size_t count)
{
  shift_range(data, count, -(*smallest(data, count)));
  return scale_range(data, count, *largest(data, count));
}


================================================
FILE: Examples/Modules/Chapter 08/Ex8_14.cpp
================================================
// Overloading a function
import <iostream>;
import <string>;
import <vector>;

// Function prototypes
double largest(const double data[], size_t count);
double largest(const std::vector<double>& data);
int largest(const std::vector<int>& data);
std::string largest(const std::vector<std::string>& words);
// int largest(const std::vector<std::string>& words); 
            /* Above function overload would not compile: overloaded functions
               must differ in more than just their return type! */
int main()
{
  double array[] {1.5, 44.6, 13.7, 21.2, 6.7};
  std::vector<int> numbers {15, 44, 13, 21, 6, 8, 5, 2};
  std::vector<double> data{3.5, 5, 6, -1.2, 8.7, 6.4};
  std::vector<std::string> names {"Charles Dickens", "Emily Bronte", 
                                  "Jane Austen", "Henry James", "Arthur Miller"};
  std::cout << "The largest of array is " << largest(array, std::size(array)) 
                        << std::endl;
  std::cout << "The largest of numbers is " << largest(numbers) << std::endl;
  std::cout << "The largest of data is " << largest(data) << std::endl;
  std::cout << "The largest of names is " << largest(names) << std::endl;
}

// Finds the largest of an array of double values
double largest(const double data[], size_t count)
{
  double max{ data[0] };
  for (size_t i{ 1 }; i < count; ++i)
    if (max < data[i]) max = data[i];
  return max;
}

// Finds the largest of a vector of double values
double largest(const std::vector<double>& data)
{
  double max {data[0]};
  for (auto value : data)
    if (max < value) max = value;
  return max;
}

// Finds the largest of a vector of int values
int largest(const std::vector<int>& data)
{
  int max {data[0]};
  for (auto value : data)
    if (max < value) max = value;
  return max;
}

// Finds the largest of a vector of string objects
std::string largest(const std::vector<std::string>& words)
{
  std::string max_word {words[0]};
  for (const auto& word : words)
    if (max_word < word) max_word = word;
  return max_word;
}


================================================
FILE: Examples/Modules/Chapter 08/Ex8_15.cpp
================================================
// Overloading a function with reference parameters
import <iostream>;
import <format>;

double larger(double a, double b); // Non-reference parameters
long& larger(long& a, long& b);    // Reference parameters

int main()
{
  double a_double {1.5}, b_double {2.5};
  std::cout << std::format("The larger of double values {} and {} is {}\n",
                           a_double, b_double, larger(a_double, b_double));

  int a_int {15}, b_int {25};
  std::cout << std::format("The larger of int values {} and {} is {}\n",
                  a_int, b_int, 
                  larger(static_cast<long>(a_int), static_cast<long>(b_int)));
}

// Returns the larger of two floating point values
double larger(double a, double b)
{
  std::cout << "double larger() called." << std::endl;
  return a > b ? a : b;
}

// Returns the larger of two long references
long& larger(long& a, long& b)
{
  std::cout << "long ref larger() called" << std::endl;
  return a > b ? a : b;
}


================================================
FILE: Examples/Modules/Chapter 08/Ex8_16.cpp
================================================
// Recursive version of function for x to the power n, n positive or negative
import <iostream>;
import <format>;

double power(double x, int n);

int main()
{
  for (int i{ -3 }; i <= 3; ++i)      // Calculate powers of 8 from -3 to +3
    std::cout << std::format("{:10g}", power(8.0, i));

  std::cout << std::endl;
}

// Recursive function to calculate x to the power n
double power(double x, int n)
{
  if (n == 0)      return 1.0;
  else if (n > 0)  return x * power(x, n - 1);
  else /* n < 0 */ return 1.0 / power(x, -n);
}


================================================
FILE: Examples/Modules/Chapter 08/Ex8_17.cpp
================================================
// Sorting words recursively
import <iostream>;
import <format>;
import <memory>;
import <string>;
import <vector>;
using Words = std::vector<std::shared_ptr<std::string>>;

void swap(Words& words, size_t first, size_t second);
void sort(Words& words);
void sort(Words& words, size_t start, size_t end);
void extract_words(Words& words, const std::string& text, const std::string& separators);
void show_words(const Words& words);
size_t max_word_length(const Words& words);

int main()
{
  Words words;
  std::string text;                    // The string to be sorted
  const auto separators{" ,.!?\"\n"};  // Word delimiters

  // Read the string to be processed from the keyboard
  std::cout << "Enter a string terminated by *:" << std::endl;
  getline(std::cin, text, '*');

  extract_words(words, text, separators);
  if (words.empty())
  {
    std::cout << "No words in text." << std::endl;
    return 0;
  }

  sort(words);         // Sort the words
  show_words(words);   // Output the words
}

void extract_words(Words& words, const std::string& text, const std::string& separators)
{
  size_t start {text.find_first_not_of(separators)}; // Start index of first word

  while (start != std::string::npos)
  {
    size_t end{ text.find_first_of(separators, start + 1) }; // Find end of a word
    if (end == std::string::npos)                    // Found a separator?
      end = text.length();                           // Yes, so set to end of text
    words.push_back(std::make_shared<std::string>(text.substr(start, end - start)));
    start = text.find_first_not_of(separators, end + 1); // Find start next word
  }
}

void swap(Words& words, size_t first, size_t second)
{
  auto temp{words[first]};
  words[first] = words[second];
  words[second] = temp;
}

// Sort strings in ascending sequence
void sort(Words& words)
{
  if (!words.empty())
    sort(words, 0, words.size() - 1);
}

void sort(Words& words, size_t start, size_t end)
{
  // start index must be less than end index for 2 or more elements
  if (!(start < end))
    return;

  // Choose middle address to partition set
  swap(words, start, (start + end) / 2);     // Swap middle address with start

  // Check words against chosen word
  size_t current {start};
  for (size_t i {start + 1}; i <= end; i++)
  {
    if (*words[i] < *words[start])           // Is word less than chosen word?
      swap(words, ++current, i);             // Yes, so swap to the left
  }

  swap(words, start, current);               // Swap chosen and last swapped words

  if (current > start) sort(words, start, current - 1); // Sort left subset if exists
  if (end > current + 1) sort(words, current + 1, end); // Sort right subset if exists
}

size_t max_word_length(const Words& words)
{
  size_t max {};
  for (auto& pword : words)
    if (max < pword->length()) max = pword->length();
  return max;
}

void show_words(const Words& words)
{
  const size_t field_width {max_word_length(words) + 1};
  const size_t words_per_line {8};
  std::cout << std::format("{:{}}", *words[0], field_width); // Output first word

  size_t words_in_line {};         // Number of words in current line
  for (size_t i {1}; i < words.size(); ++i)
  { // Output newline when initial letter changes or after 8 per line
    if ((*words[i])[0] != (*words[i - 1])[0] || ++words_in_line == words_per_line)
    {
      words_in_line = 0;
      std::cout << std::endl;
    }
    std::cout << std::format("{:{}}", *words[i], field_width); // Output a word
  }
  std::cout << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 09/Ex9_01.cpp
================================================
// Working with std::optional<>
import <optional>;     // std::optional<> is defined in the <optional> module
import <iostream>;
import <string>;

std::optional<size_t> find_last(
   const std::string& string, char to_find,
   std::optional<size_t> start_index = std::nullopt); // or: ... start_index = {});

int main()
{
  const auto string{ "Growing old is mandatory; growing up is optional." };

  const std::optional<size_t> found_a{ find_last(string, 'a') };
  if (found_a)
    std::cout << "Found the last a at index " << *found_a << std::endl;

  const auto found_b{ find_last(string, 'b') };
  if (found_b.has_value())
    std::cout << "Found the last b at index " << found_b.value() << std::endl;

// following line gives an error (cannot convert std::optional<size_t> to size_t)
// const size_t found_c{ find_last(string, 'c') }; 
                                                   
  const auto found_early_i{ find_last(string, 'i', 10) };
  if (found_early_i != std::nullopt)
    std::cout << "Found an early i at index " << *found_early_i << std::endl;
}

std::optional<size_t> find_last(const std::string& string, char to_find, 
                                std::optional<size_t> start_index)
{
  // code below will not work for empty strings  
  if (string.empty())            
    return std::nullopt;         // or: 'return std::optional<size_t>{};'
                                 // or: 'return {};'
  // determine the starting index for the loop that follows:
  size_t index{ start_index.value_or(string.size() - 1) };

  while (true)  // never use while (index >= 0) here, as size_t is always >= 0!
  {
    if (string[index] == to_find) return index;
    if (index == 0) return std::nullopt;
    --index;
  }
}

================================================
FILE: Examples/Modules/Chapter 09/Ex9_02.cpp
================================================
// Using std::string_view parameters
import <iostream>;
import <format>;
import <string>;
import <string_view>;
import <vector>;

using std::string;
using std::string_view;
using std::vector;

void find_words(vector<string>& words, string_view str, string_view separators);
void list_words(const vector<string>& words);

int main()
{
  std::string text;         // The string to be searched
  std::cout << "Enter some text terminated by *:\n";
  std::getline(std::cin, text, '*');

  const std::string separators{ " ,;:.\"!?'\n" };  // Word delimiters
  std::vector<std::string> words;                 // Words found

  find_words(words, text, separators);
  list_words(words);
}

void find_words(vector<string>& words, string_view text, string_view separators)
{
  size_t start{ text.find_first_not_of(separators) }; // First word start index

  while (start != string_view::npos)                          // Find the words
  {
    size_t end{ text.find_first_of(separators, start + 1) };  // Find end of word
    if (end == string_view::npos)                             // Found a separator?
      end = text.length();                              // No, so set to end of text

    words.push_back(std::string{ text.substr(start, end - start) }); // Store the word
// Or: words.emplace_back(text.substr(start, end - start));    // (in-place construction)
    start = text.find_first_not_of(separators, end + 1); // Find 1st character of next word
  }
}

void list_words(const vector<string>& words)
{
  std::cout << "Your string contains the following " << words.size() << " words:\n";
  size_t count{};                 // Number of outputted words
  for (const auto& word : words)
  {
    std::cout << std::format("{:>15}", word);
    if (!(++count % 5))
      std::cout << std::endl;
  }
  std::cout << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 09/Ex9_03.cpp
================================================
// Using std::span<> to reduce the number of overloads of largest()
// Clearly the three resulting functions are still similar. 
// See Chapter 10 on how you can eliminate this duplication using function templates.
import <iostream>;
import <string>;
import <vector>;
import <array>;
import <span>;

// Old function prototypes
//double largest(const double data[], size_t count);
//double largest(const std::vector<double>& data);
//int largest(const std::vector<int>& data);
//std::string largest(const std::vector<std::string>& words);

// New function prototypes
// (these functions work for any sequential input, not just arrays or vectors)
/* Caution: these signatures are not ideal yet: see Ex9_03A */
double largest(std::span<double> data);
int largest(std::span<int> data);
std::string largest(std::span<std::string> words);

int main()
{
  double array[] {1.5, 44.6, 13.7, 21.2, 6.7};
  std::vector numbers {15, 44, 13, 21, 6, 8, 5, 2};
  std::vector data{3.5, 5.0, 6.0, -1.2, 8.7, 6.4};
  std::array array_data{ 3.5, 5.0, 6.0, -1.2, 8.7, 6.4 }; // Throwing in an std::array for good measure
  std::vector<std::string> names {"Charles Dickens", "Emily Bronte", 
                                  "Jane Austen", "Henry James", "Arthur Miller"};
  std::cout << "The largest of array is " << largest(array) << std::endl;
  std::cout << "The largest of numbers is " << largest(numbers) << std::endl;
  std::cout << "The largest of data is " << largest(data) << std::endl;
  std::cout << "The largest of array_data is (also) " << largest(array_data) << std::endl;
  std::cout << "The largest of names is " << largest(names) << std::endl;
}

// Finds the largest of a span of values
double largest(std::span<double> data)
{
  double max {data[0]};
  for (auto value : data)
    if (max < value) max = value;
  return max;
}

// Finds the largest of a vector of int values
int largest(std::span<int> data)
{
  int max {data[0]};
  for (auto value : data)
    if (max < value) max = value;
  return max;
}

// Finds the largest of a vector of string objects
std::string largest(std::span<std::string> words)
{
  std::string max_word {words[0]};
  for (const auto& word : words)
    if (max_word < word) max_word = word;
  return max_word;
}


================================================
FILE: Examples/Modules/Chapter 09/Ex9_03A.cpp
================================================
// Using std::span<const T> to ensure largest() works for const inputs
import <iostream>;
import <string>;
import <vector>;
import <array>;
import <span>;

// Old function prototypes
//double largest(const double data[], size_t count);
//double largest(const std::vector<double>& data);
//int largest(const std::vector<int>& data);
//std::string largest(const std::vector<std::string>& words);

// New function prototypes
// (these functions work for any sequential input, not just arrays or vectors)
double largest(std::span<const double> data);
int largest(std::span<const int> data);
std::string largest(std::span<const std::string> words);

int main()
{
  const double array[] {1.5, 44.6, 13.7, 21.2, 6.7};
  const std::vector numbers {15, 44, 13, 21, 6, 8, 5, 2};
  const std::vector data{3.5, 5.0, 6.0, -1.2, 8.7, 6.4};
  const std::array array_data{ 3.5, 5.0, 6.0, -1.2, 8.7, 6.4 }; // Throwing in an std::array for good measure
  const std::vector<std::string> names {"Charles Dickens", "Emily Bronte", 
                                  "Jane Austen", "Henry James", "Arthur Miller"};
  std::cout << "The largest of array is " << largest(array) << std::endl;
  std::cout << "The largest of numbers is " << largest(numbers) << std::endl;
  std::cout << "The largest of data is " << largest(data) << std::endl;
  std::cout << "The largest of array_data is (also) " << largest(array_data) << std::endl;
  std::cout << "The largest of names is " << largest(names) << std::endl;
}

// Finds the largest of a span of values
double largest(std::span<const double> data)
{
  double max {data[0]};
  for (auto value : data)
    if (max < value) max = value;
  return max;
}

// Finds the largest of a vector of int values
int largest(std::span<const int> data)
{
  int max {data[0]};
  for (auto value : data)
    if (max < value) max = value;
  return max;
}

// Finds the largest of a vector of string objects
std::string largest(std::span<const std::string> words)
{
  std::string max_word {words[0]};
  for (const auto& word : words)
    if (max_word < word) max_word = word;
  return max_word;
}


================================================
FILE: Examples/Modules/Chapter 10/Ex10_01.cpp
================================================
// Using a function template
import <iostream>;
import <format>;
import <string>;

template<typename T> T larger(T a, T b);    // Function template prototype

int main()
{
  std::cout << "Larger of 1.5 and 2.5 is " << larger(1.5, 2.5) << std::endl;
  std::cout << "Larger of 3.5 and 4.5 is " << larger(3.5, 4.5) << std::endl;

  int big_int {17011983}, small_int {10};
  std::cout << std::format("Larger of {} and {} is {}\n", 
                            big_int, small_int, larger(big_int, small_int));

  std::string a_string {"A"}, z_string {"Z"};
  std::cout << std::format(R"(Larger of "{}" and "{}" is "{}")", 
                           a_string, z_string, larger(a_string, z_string)) << std::endl;
}

// Template for functions to return the larger of two values
template <typename T>
T larger(T a, T b)
{
    return a > b ? a : b;
}



================================================
FILE: Examples/Modules/Chapter 10/Ex10_02.cpp
================================================
// Overloading function templates
import <iostream>;
import <format>;
import <string>;
import <vector>;

template<typename T> T larger(T a, T b);    // Function template prototype
template <typename T> T* larger(T*, T*);
template <typename T> const T* larger(const std::vector<T>& data);

int main()
{
  int big_int {17011983}, small_int {10};
  std::cout << std::format("Larger of {} and {} is {}", 
                 big_int, small_int, larger(big_int, small_int)) << std::endl;
  std::cout << std::format("Larger of {} and {} is {}",
                 big_int, small_int, *larger(&big_int, &small_int)) << std::endl;

  std::vector<double> data {-1.4, 7.3, -100.0, 54.1, 16.3};
  std::cout << "The largest value in data is " << *larger(data) << std::endl;

  std::vector<std::string> words {"The", "higher", "the", "fewer"};
  std::cout << std::format(R"(The largest word in words is "{}")", *larger(words)) 
            << std::endl;
}

// Template for functions to return the larger of two values
template <typename T>
T larger(T a, T b)
{
    return a > b ? a : b;
}

template<typename T>
T* larger(T* a, T* b)
{
  return *a > * b ? a : b;
}

template <typename T>
const T* larger(const std::vector<T>& data)
{
  const T* result {};       // The largest of an empty vector is nullptr
  for (auto& value : data)
    if (!result || value > *result) result = &value;
  return result;
}


================================================
FILE: Examples/Modules/Chapter 10/Ex10_03.cpp
================================================
// Using return type deduction with templates
import <iostream>;
import <string>;

// Template for functions to return the larger of two values
// Supports implicit converion of differently-typed arguments
template <typename T1, typename T2>
auto larger(const T1& a, const T2& b)
{
  return a > b ? a : b;
}

int main()
{
  int small_int {10};
  std::cout << "Larger of " << small_int << " and 9.6 is "
            << larger(small_int, 9.6) << std::endl;       // deduced return type: double
  
  std::string a_string {"A"};
  std::cout << "Larger of \"" << a_string << "\" and \"Z\" is \""
            << larger(a_string, "Z") << '"' << std::endl; // deduced return type: std::string
}



================================================
FILE: Examples/Modules/Chapter 10/Ex10_03A.cpp
================================================
// Using return type deduction with templates (decltype(auto) instead of auto)
import <iostream>;
import <string>;
import <vector>;

// Template for functions to return the larger of two values
// Supports implicit converion of differently-typed arguments
template <typename T1, typename T2>
decltype(auto) larger(const T1& a, const T2& b)
{
  return a > b ? a : b;
}

int main()
{
  const int small_int {10};
  std::cout << "Larger of " << small_int << " and 9.6 is "
            << larger(small_int, 9.6) << std::endl;       // deduced return type: double
  
  const std::string a_string {"A"};
  std::cout << "Larger of \"" << a_string << "\" and \"Z\" is \""
            << larger(a_string, "Z") << '"' << std::endl; // deduced return type: std::string

  const std::vector v1{ 1, 2, 3, 4, 5, 6, 7, 8, 9, 10 };
  const std::vector v2{ 1, 2, 3, 4, 5, 6, 7, 8, 9, 11 };
  std::cout << "The larger of our two vectors ends with " << larger(v1, v2).back();
}



================================================
FILE: Examples/Modules/Chapter 10/Ex10_04.cpp
================================================
// Defining templates for functions that accept fixed-size arrays
import <iostream>;

template <typename T, size_t N>
T average(const T(&array)[N]);

int main()
{
  double doubles[2]{ 1.0, 2.0 };
  std::cout << average(doubles) << std::endl;

  double moreDoubles[]{ 1.0, 2.0, 3.0, 4.0 };
  std::cout << average(moreDoubles) << std::endl;

  // double* pointer = doubles;
  // std::cout << average(pointer) << std::endl;      /* will not compile */

  std::cout << average({ 1.0, 2.0, 3.0, 4.0 }) << std::endl;

  int ints[] = { 1, 2, 3, 4 };
  std::cout << average(ints) << std::endl;
}

template <typename T, size_t N>
T average(const T(&array)[N])
{
  T sum{};                            // Accumulate total in here
  for (size_t i{}; i < N; ++i)
    sum += array[i];                   // Sum array elements
  return sum / N;                      // Return average
}

================================================
FILE: Examples/Modules/Chapter 11/Ex11_01/Ex11_01.cpp
================================================
// Consuming your own module
import <iostream>;
import <format>;
import math;

int main()
{
  std::cout << "Lambda squared: " << square(lambda) << std::endl;

  int number;
  std::cout << "\nPlease enter an odd number: ";
  std::cin >> number;
  std::cout << std::endl;

  // if (isOdd(number))            /* Error: identifier not found: 'isOdd' */
  //   std::cout << "Well done!" << std::endl;

  switch (getOddity(number))
  {
    using enum Oddity;
  case Odd:
    std::cout << "Well done! And remember: you have to be odd to be number one!";
    break;
  case Even:
    std::cout << std::format("Odd, {} seems to be even?", number);
    break;
  }
  std::cout << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 11/Ex11_01/math.cppm
================================================
export module math;

export auto square(const auto& x) { return x * x; }  // An abbreviated function template

export const double lambda = 1.303577269034296391257;        // Conway's constant

export enum class Oddity { Even, Odd };
bool isOdd(int x) { return x % 2 != 0; }  // Module-local function (not exported)
export auto getOddity(int x) { return isOdd(x) ? Oddity::Odd : Oddity::Even; }


================================================
FILE: Examples/Modules/Chapter 11/Ex11_01A/Ex11_01A.cpp
================================================
// Exporting multiple entities at once
import <iostream>;
import <format>;
import math;

int main()
{
  std::cout << "Lambda squared: " << square(lambda) << std::endl;

  int number;
  std::cout << "\nPlease enter an odd number: ";
  std::cin >> number;
  std::cout << std::endl;

  // if (isOdd(number))            /* Error: identifier not found: 'isOdd' */
  //   std::cout << "Well done!" << std::endl;

  switch (getOddity(number))
  {
    using enum Oddity;
  case Odd:
    std::cout << "Well done! And remember: you have to be odd to be number one!";
    break;
  case Even:
    std::cout << std::format("Odd, {} seems to be even?", number);
    break;
  }
  std::cout << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 11/Ex11_01A/math.cppm
================================================
export module math;

bool isOdd(int x) { return x % 2 != 0; }   // Module-local function (not exported)

export
{
  auto square(const auto& x) { return x * x; }

  const double lambda = 1.303577269034296391257;  // Conway's constant

  enum class Oddity { Even, Odd };
  auto getOddity(int x) { return isOdd(x) ? Oddity::Odd : Oddity::Even; }
}


================================================
FILE: Examples/Modules/Chapter 11/Ex11_01B/Ex11_01B.cpp
================================================
// Separating implementation from interface within the module interface file
import <iostream>;
import <format>;
import math;

int main()
{
  std::cout << "Lambda squared: " << square(lambda) << std::endl;

  int number;
  std::cout << "\nPlease enter an odd number: ";
  std::cin >> number;
  std::cout << std::endl;

  // if (isOdd(number))            /* Error: identifier not found: 'isOdd' */
  //   std::cout << "Well done!" << std::endl;

  switch (getOddity(number))
  {
    using enum Oddity;
  case Odd:
    std::cout << "Well done! And remember: you have to be odd to be number one!";
    break;
  case Even:
    std::cout << std::format("Odd, {} seems to be even?", number);
    break;
  }
  std::cout << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 11/Ex11_01B/math.cppm
================================================
export module math;

export
{
  auto square(const auto& x);

  const double lambda = 1.303577269034296391257;  // Conway's constant

  enum class Oddity { Even, Odd };
  auto getOddity(int x);
}

// The implementation of the module's functions (+ local helpers)
auto square(const auto& x) { return x * x; }

bool isOdd(int x) { return x % 2 != 0; }
auto getOddity(int x) { return isOdd(x) ? Oddity::Odd : Oddity::Even; }


================================================
FILE: Examples/Modules/Chapter 11/Ex11_02/Ex11_02.cpp
================================================
// Defining functions in module implementation files
import <iostream>;
import <string>;
import roman;

int main()
{
  std::cout << "1234 in Roman numerals is " << to_roman(1234) << std::endl;
  std::cout << "MMXX in Arabic numerals is " << from_roman("MMXX") << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 11/Ex11_02/from_roman.cpp
================================================
// Implementation of the from_roman() function
module roman;

unsigned int from_roman(char c)
{
  switch (c)
  {
  case 'I': return 1;    case 'V': return 5;   case 'X': return 10;
  case 'L': return 50;   case 'C': return 100; case 'D': return 500;
  case 'M': return 1000; default:  return 0;
  }
}

unsigned int from_roman(std::string_view roman)
{
  unsigned int result{};
  for (size_t i{}, n{ roman.length() }; i < n; ++i)
  {
    const auto j{ from_roman(roman[i]) };   // Integer value of the i'th roman digit
    // Look at the next digit (if there is one) to know whether to add or subtract j
    if (i + 1 == n || j >= from_roman(roman[i + 1])) result += j; else result -= j;
  }
  return result;
}


================================================
FILE: Examples/Modules/Chapter 11/Ex11_02/roman.cppm
================================================
// Interface file for a Roman numerals module
export module roman;
import <string>;
import <string_view>;

export std::string to_roman(unsigned int i);
export unsigned int from_roman(std::string_view roman);

================================================
FILE: Examples/Modules/Chapter 11/Ex11_02/to_roman.cpp
================================================
// Implementation of the to_roman() function
module roman;

std::string to_roman(unsigned int i)
{
  if (i > 3999) return {}; // 3999, or MMMCMXCIX, is the largest standard Roman numeral
  static const std::string ms[]{ "","M","MM","MMM" };
  static const std::string cds[]{ "","C","CC","CCC","CD","D","DC","DCC","DCCC","CM" };
  static const std::string xls[]{ "","X","XX","XXX","XL","L","LX","LXX","LXXX","XC" };
  static const std::string ivs[]{ "","I","II","III","IV","V","VI","VII","VIII","IX" };
  return ms[i / 1000] + cds[(i % 1000) / 100] + xls[(i % 100) / 10] + ivs[i % 10];
}


================================================
FILE: Examples/Modules/Chapter 11/Ex11_03/Ex11_03.cpp
================================================
// Using types with reachable definitions but whose names are not visible
import <iostream>;
import roman;

int main()
{
  // std::string_view is reachable, so its constructor can be invoked 
  // (this constructor, unlike the std::string_view name itself, is visible)
  std::cout << "MMXX in Arabic numerals is " << from_roman("MMXX") << std::endl;

  // The names of the c_str() and size() members are visible as well
  // (because the definition of std::string is reachable), 
  // and can thus be invoked.
  std::cout << "1234 in Roman numerals is " << to_roman(1234).c_str() << std::endl;
  std::cout << "This consists of " << to_roman(1234).size() << " numerals" << std::endl;

  // std::string_view s{ "MMXX" };   /* Error: the name std::string_view is not visible */
  // std::string roman{ to_roman(567) };  /* Error: the name std::string is not visible */

  auto roman{ to_roman(567) };
  std::cout << "567 in Roman numerals is " << roman.c_str() << std::endl;

  // std::cout << "std::stoi() is not visible: " << std::stoi("1234") << std::endl;

  // The << operator (which is implemented as a non-member function) is not visible either
  // std::cout << "1234 in Roman numerals is " << to_roman(1234) << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 11/Ex11_03/from_roman.cpp
================================================
// Implementation of the from_roman() function
module roman;

unsigned int from_roman(char c)
{
  switch (c)
  {
  case 'I': return 1;    case 'V': return 5;   case 'X': return 10;
  case 'L': return 50;   case 'C': return 100; case 'D': return 500;
  case 'M': return 1000; default:  return 0;
  }
}

unsigned int from_roman(std::string_view roman)
{
  unsigned int result{};
  for (size_t i{}, n{ roman.length() }; i < n; ++i)
  {
    const auto j{ from_roman(roman[i]) };   // Integer value of the i'th roman digit
    // Look at the next digit (if there is one) to know whether to add or subtract j
    if (i + 1 == n || j >= from_roman(roman[i + 1])) result += j; else result -= j;
  }
  return result;
}


================================================
FILE: Examples/Modules/Chapter 11/Ex11_03/roman.cppm
================================================
// Interface file for a Roman numerals module
export module roman;
import <string>;
import <string_view>;

export std::string to_roman(unsigned int i);
export unsigned int from_roman(std::string_view roman);

================================================
FILE: Examples/Modules/Chapter 11/Ex11_03/to_roman.cpp
================================================
// Implementation of the to_roman() function
module roman;

std::string to_roman(unsigned int i)
{
  if (i > 3999) return {}; // 3999, or MMMCMXCIX, is the largest standard Roman numeral
  static const std::string ms[]{ "","M","MM","MMM" };
  static const std::string cds[]{ "","C","CC","CCC","CD","D","DC","DCC","DCCC","CM" };
  static const std::string xls[]{ "","X","XX","XXX","XL","L","LX","LXX","LXXX","XC" };
  static const std::string ivs[]{ "","I","II","III","IV","V","VI","VII","VIII","IX" };
  return ms[i / 1000] + cds[(i % 1000) / 100] + xls[(i % 100) / 10] + ivs[i % 10];
}


================================================
FILE: Examples/Modules/Chapter 11/Ex11_04/Ex11_04.cpp
================================================
// Module implementation partitions
import <iostream>;
import <string>;
import roman;

int main()
{
  std::cout << "1234 in Roman numerals is " << to_roman(1234) << std::endl;
  std::cout << "MMXX in Arabic numerals is " << from_roman("MMXX") << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 11/Ex11_04/from_roman.cpp
================================================
// Implementation of the from_roman() function
module roman;
import :internals;

unsigned int from_roman(std::string_view roman)
{
  unsigned int result{};
  for (size_t i{}, n{ roman.length() }; i < n; ++i)
  {
    const auto j{ from_roman(roman[i]) };   // Integer value of the i'th roman digit
    // Look at the next digit (if there is one) to know whether to add or subtract j
    if (i + 1 == n || j >= from_roman(roman[i + 1])) result += j; else result -= j;
  }
  return result;
}


================================================
FILE: Examples/Modules/Chapter 11/Ex11_04/roman-internals.cpp
================================================
// Implementation of the internal from_roman() function
module roman:internals;

unsigned int from_roman(char c)
{
  switch (c)
  {
  case 'I': return 1;    case 'V': return 5;   case 'X': return 10;
  case 'L': return 50;   case 'C': return 100; case 'D': return 500;
  case 'M': return 1000; default:  return 0;
  }
}


================================================
FILE: Examples/Modules/Chapter 11/Ex11_04/roman.cppm
================================================
// Interface file for a Roman numerals module
export module roman;
import <string>;
import <string_view>;

export std::string to_roman(unsigned int i);
export unsigned int from_roman(std::string_view roman);

================================================
FILE: Examples/Modules/Chapter 11/Ex11_04/to_roman.cpp
================================================
// Implementation of the to_roman() function
module roman;

std::string to_roman(unsigned int i)
{
  if (i > 3999) return {}; // 3999, or MMMCMXCIX, is the largest standard Roman numeral
  static const std::string ms[]{ "","M","MM","MMM" };
  static const std::string cds[]{ "","C","CC","CCC","CD","D","DC","DCC","DCCC","CM" };
  static const std::string xls[]{ "","X","XX","XXX","XL","L","LX","LXX","LXXX","XC" };
  static const std::string ivs[]{ "","I","II","III","IV","V","VI","VII","VIII","IX" };
  return ms[i / 1000] + cds[(i % 1000) / 100] + xls[(i % 100) / 10] + ivs[i % 10];
}


================================================
FILE: Examples/Modules/Chapter 11/Ex11_05/Ex11_05.cpp
================================================
// Creating module interface partitions
import <iostream>;
import <string>;
import roman;

int main()
{
  std::cout << "1234 in Roman numerals is " << to_roman(1234) << std::endl;
  std::cout << "MMXX in Arabic numerals is " << from_roman("MMXX") << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 11/Ex11_05/from_roman.cpp
================================================
// Implementation of the from_roman() function
module roman;
import :internals;

unsigned int from_roman(std::string_view roman)
{
  unsigned int result{};
  for (size_t i{}, n{ roman.length() }; i < n; ++i)
  {
    const auto j{ from_roman(roman[i]) };   // Integer value of the i'th roman digit
    // Look at the next digit (if there is one) to know whether to add or subtract j
    if (i + 1 == n || j >= from_roman(roman[i + 1])) result += j; else result -= j;
  }
  return result;
}


================================================
FILE: Examples/Modules/Chapter 11/Ex11_05/roman-from.cppm
================================================
// Module interface file for the from partition of the roman module
export module roman:from;
import <string_view>;

export unsigned int from_roman(std::string_view roman);

================================================
FILE: Examples/Modules/Chapter 11/Ex11_05/roman-internals.cpp
================================================
// Implementation of the internal from_roman() function
module roman:internals;

unsigned int from_roman(char c)
{
  switch (c)
  {
  case 'I': return 1;    case 'V': return 5;   case 'X': return 10;
  case 'L': return 50;   case 'C': return 100; case 'D': return 500;
  case 'M': return 1000; default:  return 0;
  }
}


================================================
FILE: Examples/Modules/Chapter 11/Ex11_05/roman-to.cppm
================================================
// Module interface file for the to partition of the roman module
export module roman:to;
import <string>;

export std::string to_roman(unsigned int i)
{
  if (i > 3999) return {}; // 3999, or MMMCMXCIX, is the largest standard Roman numeral
  static const std::string ms[]{ "","M","MM","MMM" };
  static const std::string cds[]{ "","C","CC","CCC","CD","D","DC","DCC","DCCC","CM" };
  static const std::string xls[]{ "","X","XX","XXX","XL","L","LX","LXX","LXXX","XC" };
  static const std::string ivs[]{ "","I","II","III","IV","V","VI","VII","VIII","IX" };
  return ms[i / 1000] + cds[(i % 1000) / 100] + xls[(i % 100) / 10] + ivs[i % 10];
}


================================================
FILE: Examples/Modules/Chapter 11/Ex11_05/roman.cppm
================================================
// Primary module interface file for the roman module
export module roman;

export import :to;     // Not: 'export import roman:to;'
export import :from;   // Not: 'export import roman:from;'
// export import :internals;  /* Error: only interface partitions can be exported */


================================================
FILE: Examples/Modules/Chapter 11/Ex11_06/Ex11_06.cpp
================================================
// Defining and using a namespace

import <iostream>;
import <numbers>;

namespace math
{
  const double sqrt2{ 1.414213562373095 };      // the square root of 2
  auto square(const auto& x) { return x * x; }
  auto pow4(const auto& x) { return square(square(x)); }
}

int main()
{
  std::cout << "math::sqrt2 has the value " << math::sqrt2 << std::endl;
  std::cout << "This should be 0: " << (math::sqrt2 - std::numbers::sqrt2) << std::endl;
  std::cout << "This should be 2: " << math::square(math::sqrt2) << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 11/Ex11_06A/Ex11_06A.cpp
================================================
// Defining and using a namespace
import <iostream>;
import <numbers>;
import squaring;

int main()
{
  std::cout << "math::sqrt2 has the value " << math::sqrt2 << std::endl;
  std::cout << "This should be 0: " << (math::sqrt2 - std::numbers::sqrt2) << std::endl;
  std::cout << "This should be 2: " << math::square(math::sqrt2) << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 11/Ex11_06A/squaring.cppm
================================================
export module squaring;

namespace math
{
  export const double sqrt2{ 1.414213562373095 };      // the square root of 2
  export auto square(const auto& x) { return x * x; }
  export auto pow4(const auto& x) { return square(square(x)); }
}

================================================
FILE: Examples/Modules/Chapter 11/Ex11_06B/Ex11_06B.cpp
================================================
// Defining and using a namespace
import <iostream>;
import <numbers>;
import squaring;

int main()
{
  std::cout << "math::sqrt2 has the value " << math::sqrt2 << std::endl;
  std::cout << "This should be 0: " << (math::sqrt2 - std::numbers::sqrt2) << std::endl;
  std::cout << "This should be 2: " << math::square(math::sqrt2) << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 11/Ex11_06B/squaring.cppm
================================================
export module squaring;

export namespace math         // Exports all nested declarations at once
{
  const double sqrt2{ 1.414213562373095 };       // the square root of 2
  auto square(const auto& x) { return x * x; }
  auto pow4(const auto& x) { return square(square(x)); }
}

================================================
FILE: Examples/Modules/Chapter 11/Ex11_07/Ex11_07.cpp
================================================
// Separating declarations and definitions of functions
// declared in a namespace.
import <iostream>;
import math;

int main()
{
  const double values[]{ 10, 2, 1, 8, 3, 7, 4, 5, 6, 9 };
  std::cout << "Arithmetic mean: " << math::averages::arithmetic_mean(values) << std::endl;
  std::cout << "Geometric mean: " << math::averages::geometric_mean(values) << std::endl;
  std::cout << "Root mean square: " << math::averages::rms(values) << std::endl;
  std::cout << "Median: " << math::averages::median(values) << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 11/Ex11_07/math.cpp
================================================
module;
#include <cmath>    // For std::pow(), std::sqrt(), ...
module math;

import <limits>;   // For std::numeric_limits<double>::quiet_NaN()
import <vector>;   // For std::numeric_limits<double>::quiet_NaN()

void quicksort(std::vector<double>& data); // See Chapter 8

// Option 1: define in nested namespace block (compact syntax)
namespace math::averages
{
  double arithmetic_mean(std::span<const double> data)
  {
    // The arithmetic mean, the most commonly used average, 
    // is defined as the sum of all elements divided by the number of elements.
    double sum {};
    for (auto value : data)
      sum += value;
    
    return data.empty() 
      ? std::numeric_limits<double>::quiet_NaN() // Or std::nan("")
      : sum / data.size();
  }
}

// Option 2: define in nested namespace blocks
namespace math
{
  namespace averages
  {
    double geometric_mean(std::span<const double> data)
    {
      // The geometric mean of n elements
      // is defined as the n-th root of the product of all n elements
      double product{ 1 };
      for (auto value : data)
        product *= value;

      return data.empty()
        ? std::numeric_limits<double>::quiet_NaN() 
        : std::pow(product, 1.0 / data.size());
    }
  }
}

// Option 3: define using fully qualified function name
double math::averages::rms(std::span<const double> data)
{ 
  // The RMS or root mean square is defined as 
  // square root of the arithmetic mean of the squares of the elements.
  double sum_squares{};
  for (auto value : data)
    sum_squares += square(value);

  return data.empty()
    ? std::numeric_limits<double>::quiet_NaN() // Or std::nan("")
    : std::sqrt(sum_squares / data.size());
}

// Option 4: define using qualified name in outer namespace block
namespace math
{
  double averages::median(std::span<const double> data)
  {
    // The median of an odd number of elements is the value 
    // that appears in the middle position of these elements when they are sorted.
    // The median of an even number of elements is typically
    // defined as the mean of the two middle elements in a sorted range.

    // We cannot sort the data span itself, because it's elements are const.
    // Therefore, we first copy the const input data to be able to sort it
    std::vector<double> sorted;

    // Use range-based for loop to copy the input data.
    // See Chapter 20 for built-in means of copying a data range.
    for (auto value : data)
      sorted.push_back(value);

    // See Chapter 20 for built-in means of (partially) sorting data
    quicksort(sorted);

    const size_t mid = data.size() / 2;
    return data.empty() ? std::numeric_limits<double>::quiet_NaN() // Or std::nan
         : data.size() % 2 == 1 ? sorted[mid]
         : (sorted[mid - 1] + sorted[mid]) / 2;
  }
}

void quicksort(std::vector<double>& data, size_t start, size_t end);
void quicksort(std::vector<double>& data)
{
  if (!data.empty())
    quicksort(data, 0, data.size() - 1);
}

void quicksort(std::vector<double>& data, size_t start, size_t end)
{
  // start index must be less than end index for 2 or more elements
  if (!(start < end))
    return;

  // Choose middle value to partition set, 
  // and move it to the front of the current range
  std::swap(data[start], data[(start + end) / 2]);
  
  // Compare all other values against chosen value at index start
  size_t current{ start };
  for (size_t i{ start + 1 }; i <= end; i++)
  {
    if (data[i] < data[start]) // Is the value less than chosen value?
      std::swap(data[++current], data[i]); // Yes, so swap to the left
  }

  std::swap(data[start], data[current]); // Swap chosen and last swapped words

  if (current > start) quicksort(data, start, current - 1); // Sort left subset if exists
  if (end > current + 1) quicksort(data, current + 1, end); // Sort right subset if exists
}


================================================
FILE: Examples/Modules/Chapter 11/Ex11_07/math.cppm
================================================
export module math;

import <span>;

export namespace math
{
  auto square(const auto& x) { return x * x; };

  namespace averages
  {
    double arithmetic_mean(std::span<const double> data);
    double geometric_mean(std::span<const double> data);
    double rms(std::span<const double> data);
    double median(std::span<const double> data);
  }
}

================================================
FILE: Examples/Modules/Chapter 11/Ex11_08/Ex11_08.cpp
================================================
// Using using declarations and using directives
// (Note: example was not named in the text)
import <iostream>;
import squaring;

/* Make names from the math namespace available locally */
// Note: text uses hypot(), but this causes ambiguities with hypot() 
// function of <cmath> with Visual Studio
auto hypotenuse(const auto& x, const auto& y)
{
  using namespace math;
  // Or:
  //   using math::square;
  //   using math::sqrt;    /* Same as, of course: using std::sqrt; */
  return sqrt(square(x) + square(y));
}

int main()
{
  std::cout << "math::sqrt2 has the value " << math::sqrt2 << std::endl;
  std::cout << "This should be 0: " << (math::sqrt2 - std::numbers::sqrt2) << std::endl;
  std::cout << "This should be 2: " << math::square(math::sqrt2) << std::endl;
  std::cout << "This should be 5: " << hypotenuse(3, 4) << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 11/Ex11_08/squaring.cppm
================================================
module;               // Start of the global module fragment (for #include directives)
#include <cmath>      // For std::sqrt()
export module squaring;
import <numbers>;     // For std::numbers::sqrt2 

/* Re-export two existing entities from the math namespace using using declarations */
export namespace math         // Exports all nested declarations at once
{
  
  using std::numbers::sqrt2;
  using std::sqrt;    // Never 'using std::sqrt();' or 'using std::sqrt(double);'!
  auto square(const auto& x) { return x * x; }
  auto pow4(const auto& x) { return square(square(x)); }
}

/* Export all names from a namespace from the math namespace using a using directive */
//namespace math
//{
//  export using namespace std::numbers;
//}

================================================
FILE: Examples/Modules/Chapter 12/Ex12_01/Ex12_01.cpp
================================================
// Defining a class constructor
import <iostream>;

// Class to represent a box
class Box
{
public:
  // Constructor
  Box(double length, double width, double height)
  {
    std::cout << "Box constructor called."  << std::endl;
    m_length = length;
    m_width = width;
    m_height = height;
  }

  // Function to calculate the volume of a box
  double volume()
  {
    return m_length * m_width * m_height;
  }

private:
  double m_length {1.0};
  double m_width {1.0};
  double m_height {1.0};
};

int main()
{
  Box firstBox {80.0, 50.0, 40.0};            // Create a box
  double firstBoxVolume {firstBox.volume()};  // Calculate the box volume
  std::cout << "Volume of Box object is " << firstBoxVolume << std::endl;

  // Box secondBox;        // Causes a compiler error message
}


================================================
FILE: Examples/Modules/Chapter 12/Ex12_01A/Ex12_01A.cpp
================================================
// Defining a default constructor
import <iostream>;

// Class to represent a box
class Box
{
public:
// Box() {}           // Explicitly defined default constructor
  Box() = default;    // Defaulted default constructor

  // Constructor
  Box(double length, double width, double height)
  {
    std::cout << "Box constructor called."  << std::endl;
    m_length = length;
    m_width = width;
    m_height = height;
  }

  // Function to calculate the volume of a box
  double volume()
  {
    return m_length * m_width * m_height;
  }

private:
  double m_length {1.0};
  double m_width {1.0};
  double m_height {1.0};
};

int main()
{
  Box firstBox {80.0, 50.0, 40.0};            // Create a box
  double firstBoxVolume {firstBox.volume()};  // Calculate the box volume
  std::cout << "Volume of Box object is " << firstBoxVolume << std::endl;

  Box secondBox;        // No longer causes a compiler error message
}


================================================
FILE: Examples/Modules/Chapter 12/Ex12_02/Ex12_02.cpp
================================================
// Defining member functions outside a class
// Note that, unlike what we said in the text, 
// in this example we put the function definitions after the main() function.
// This illustrates that to invoke a member function,
// the compiler again only needs access to the signature of the member function.
import <iostream>;

// Class to represent a box
class Box
{
public:
  Box() = default;
  Box(double length, double width, double height);

  double volume();   // Function to calculate the volume of a box

private:
  double m_length{ 1.0 };
  double m_width{ 1.0 };
  double m_height{ 1.0 };
};

int main()
{
  Box firstBox {80.0, 50.0, 40.0};            // Create a box
  double firstBoxVolume {firstBox.volume()};  // Calculate the box volume
  std::cout << "Volume of Box object is " << firstBoxVolume << std::endl;

  Box secondBox;        // No longer causes a compiler error message
}

// Constructor definition
Box::Box(double length, double width, double height)
{
  std::cout << "Box constructor called." << std::endl;
  m_length = length;
  m_width = width;
  m_height = height;
}

// Member function definition
double Box::volume()
{
  return m_length * m_width * m_height;
}


================================================
FILE: Examples/Modules/Chapter 12/Ex12_03/Ex12_03.cpp
================================================
// Using a member initializer list
import <iostream>;

// Class to represent a box
class Box
{
public:
  Box() = default;
  Box(double length, double width, double height);

  double volume();   // Function to calculate the volume of a box

private:
  double m_length{ 1.0 };
  double m_width{ 1.0 };
  double m_height{ 1.0 };
};

int main()
{
  Box firstBox {80.0, 50.0, 40.0};            // Create a box
  double firstBoxVolume {firstBox.volume()};  // Calculate the box volume
  std::cout << "Volume of Box object is " << firstBoxVolume << std::endl;

  Box secondBox;        // No longer causes a compiler error message
}

// Constructor definition
Box::Box(double length, double width, double height)
  : m_length{length}, m_width{width}, m_height{height}
{
  std::cout << "Box constructor called." << std::endl;
}

// Member function definition
double Box::volume()
{
  return m_length * m_width * m_height;
}


================================================
FILE: Examples/Modules/Chapter 12/Ex12_04/Ex12_04.cpp
================================================
// Using the explicit keyword
// Uncomment "explicit" to make the compilation of 
// the expression "box1.hasLargerVolumeThan(50.0)" fail
import <iostream>;

class Cube
{
public:
  /*explicit*/ Cube(double side);       // Constructor
  double volume();                      // Calculate volume of a cube
  bool hasLargerVolumeThan(Cube cube);  // Compare volume of a cube with another
private:
  double m_side;
};

Cube::Cube(double side) : m_side{ side }
{
  std::cout << "Cube constructor called." << std::endl;
}

double Cube::volume() { return m_side * m_side * m_side; }
bool Cube::hasLargerVolumeThan(Cube cube) { return volume() > cube.volume(); }

int main()
{
  Cube box1{ 7.0 };
  Cube box2{ 3.0 };
  if (box1.hasLargerVolumeThan(box2))
    std::cout << "box1 is larger than box2." << std::endl;
  else
    std::cout << "Volume of box1 is less than or equal to that of box2." << std::endl;

  std::cout << "Volume of box1 is " << box1.volume() << std::endl;
  if (box1.hasLargerVolumeThan(50.0))
    std::cout << "Volume of box1 is greater than 50" << std::endl;
  else
    std::cout << "Volume of box1 is less than or equal to 50" << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 12/Ex12_05/Ex12_05.cpp
================================================
// Delegating constructors
import <iostream>;

class Box
{
public:
  Box(double length, double width, double height);
  explicit Box(double side);   // Constructor for a cube (explicit!)
  Box() = default;             // Defaulted default constructor

  double volume();             // Function to calculate the volume of a box

private:
  double m_length{1.0};
  double m_width {1.0};
  double m_height{1.0};
};

// A constructor that initializes all three member variables
Box::Box(double length, double width, double height) 
  : m_length{length}, m_width{width}, m_height{height}
{
  std::cout << "Box constructor 1 called." << std::endl;
}

// This second constructor forwards to the first one to initialize all members.
// Note that you do not repeat the explicit keyword here!
Box::Box(double side) : Box{ side, side, side }
{
  std::cout << "Box constructor 2 called." << std::endl;
}

int main()
{
  Box box1{ 2.0, 3.0, 4.0 };     // An arbitrary box
  Box box2{ 5.0 };               // A box that is a cube
  std::cout << "box1 volume = " << box1.volume() << std::endl;
  std::cout << "box2 volume = " << box2.volume() << std::endl;
}

double Box::volume()
{
  return m_length * m_width * m_height;
}

================================================
FILE: Examples/Modules/Chapter 12/Ex12_05A/Ex12_05A.cpp
================================================
// Implementing the copy constructor
// Note: this example is explained but not named in the text
import <iostream>;

class Box
{
public:
  Box(double length, double width, double height);
  explicit Box(double side);   // Constructor for a cube (explicit!)
  Box() = default;             // Defaulted default constructor
  Box(const Box& box);         // Copy constructor

  double volume();             // Function to calculate the volume of a box

private:
  double m_length{1.0};
  double m_width {1.0};
  double m_height{1.0};
};

// A basic copy constructor
Box::Box(const Box& box)
  : m_length{ box.m_length }, m_width{ box.m_width }, m_height{ box.m_height }
{
  std::cout << "Copy constructor called." << std::endl;
}

// A delegating copy constructor
//Box::Box(const Box& box) : Box{ box.m_length, box.m_width, box.m_height }
//{
//  std::cout << "Copy constructor called." << std::endl;
//}


int main()
{
  Box box1{ 2.0, 3.0, 4.0 };     // An arbitrary box
  Box box2{ 5.0 };               // A box that is a cube
  std::cout << "box1 volume = " << box1.volume() << std::endl;
  std::cout << "box2 volume = " << box2.volume() << std::endl;

  Box box3{ box2 };
  std::cout << "box3 volume = " << box3.volume() << std::endl;   // Volume = 125	
}

// A constructor that initializes all three member variables
Box::Box(double length, double width, double height)
  : m_length{ length }, m_width{ width }, m_height{ height }
{
  std::cout << "Box constructor 1 called." << std::endl;
}

// This second constructor forwards to the first one to initialize all members.
// Note that you do not repeat the explicit keyword here!
Box::Box(double side) : Box{ side, side, side }
{
  std::cout << "Box constructor 2 called." << std::endl;
}

double Box::volume()
{
  return m_length * m_width * m_height;
}

================================================
FILE: Examples/Modules/Chapter 12/Ex12_06/Box.cppm
================================================
// Module interface file for a module exporting the Box class
export module box;
import <iostream>;

// Class to represent a box
export class Box
{
public:
  Box() = default;
  Box(double length, double width, double height);

  double volume();   // Function to calculate the volume of a box

private:
  double m_length{ 1.0 };
  double m_width{ 1.0 };
  double m_height{ 1.0 };
};

// Constructor definition
Box::Box(double length, double width, double height)
  : m_length{ length }, m_width{ width }, m_height{ height }
{
  std::cout << "Box constructor called." << std::endl;
}

// Member function definition
double Box::volume() { return m_length * m_width * m_height; }


================================================
FILE: Examples/Modules/Chapter 12/Ex12_06/Ex12_06.cpp
================================================
// Exporting a class from a module
import <iostream>;   // For use of std::cout, std::endl, etc.
import box;          // For use of the Box class

int main()
{
  Box myBox{ 6.0, 6.0, 18.5 }; // Create a box
  std::cout << "Volume of the first Box object is " << myBox.volume() << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 12/Ex12_06A/Box.cpp
================================================
module box;
import <iostream>;

// Constructor definition
Box::Box(double length, double width, double height)
  : m_length{ length }, m_width{ width }, m_height{ height }
{
  std::cout << "Box constructor called." << std::endl;
}

// Member function definition
double Box::volume()
{
  return m_length * m_width * m_height;
}


================================================
FILE: Examples/Modules/Chapter 12/Ex12_06A/Box.cppm
================================================
export module box;

// Class to represent a box
export class Box
{
public:
  Box() = default;
  Box(double length, double width, double height);

  double volume();   // Function to calculate the volume of a box

private:
  double m_length{ 1.0 };
  double m_width{ 1.0 };
  double m_height{ 1.0 };
};


================================================
FILE: Examples/Modules/Chapter 12/Ex12_06A/Ex12_06A.cpp
================================================
// Defining class members in a module implementation file

import <iostream>;  // For use of std::cout, std::endl, etc.
import box;         // For use of the Box class

int main()
{
  Box myBox{ 6.0, 6.0, 18.5 }; // Create a box
  std::cout << "Volume of the first Box object is " << myBox.volume() << std::endl;
}

================================================
FILE: Examples/Modules/Chapter 12/Ex12_06B/Box.cppm
================================================
export module box;
import <iostream>;

// Class to represent a box
export class Box
{
public:
  Box() = default;
  Box(double length, double width, double height)
    : m_length{ length }, m_width{ width }, m_height{ height }
  {
    std::cout << "Box constructor called." << std::endl;
  }

  // Function to calculate the volume of a box
  double volume() { return m_length * m_width * m_height; }

private:
  double m_length{ 1.0 };
  double m_width{ 1.0 };
  double m_height{ 1.0 };
};


================================================
FILE: Examples/Modules/Chapter 12/Ex12_06B/Ex12_06B.cpp
================================================
// Defining classes with in-class member definitions.

import <iostream>; // For use of std::cout, std::endl, etc.
import box;        // For use of the Box class

int main()
{
  Box myBox{ 6.0, 6.0, 18.5 }; // Create a box
  std::cout << "Volume of the first Box object is " << myBox.volume() << std::endl;
}

================================================
FILE: Examples/Modules/Chapter 12/Ex12_07/Box.cpp
================================================
module box;

import <iostream>;

// Constructor definition
Box::Box(double length, double width, double height)
  : m_length{ length }, m_width{ width }, m_height{ height }
{
  std::cout << "Box constructor called." << std::endl;
}

// Member function definition
double Box::volume()
{
  return m_length * m_width * m_height;
}


================================================
FILE: Examples/Modules/Chapter 12/Ex12_07/Box.cppm
================================================
export module box;

export class Box
{
public:
  // Constructors
  Box() = default;
  Box(double length, double width, double height);

  double volume();    // Function to calculate the volume of a box

  // Functions to provide access to the values of member variables
  double getLength() { return m_length; }
  double getWidth()  { return m_width; }
  double getHeight() { return m_height; }

  // Functions to set member variable values
  void setLength(double length) { if (length > 0) m_length = length; }
  void setWidth(double width)   { if (width > 0)  m_width  = width;  }
  void setHeight(double height) { if (height > 0) m_height = height; }

private:
  double m_length{1.0};
  double m_width {1.0};
  double m_height{1.0};
};


================================================
FILE: Examples/Modules/Chapter 12/Ex12_07/Ex12_07.cpp
================================================
// Accessing private members through getters and setters
import <iostream>;
import box;

int main()
{
  Box myBox {3.0, 4.0, 5.0};
  std::cout << "myBox dimensions are " << myBox.getLength()
            << " by " << myBox.getWidth()
            << " by " << myBox.getHeight() << std::endl;

  myBox.setLength(-20.0);       // ignored!
  myBox.setWidth(40.0);
  myBox.setHeight(10.0);
  std::cout << "myBox dimensions are now " << myBox.getLength()  // 3 (unchanged)
    << " by " << myBox.getWidth()                        // by 40
    << " by " << myBox.getHeight() << std::endl;         // by 10
}


================================================
FILE: Examples/Modules/Chapter 12/Ex12_08/Box.cpp
================================================
module box;
import <iostream>;

// Constructor definition
Box::Box(double length, double width, double height)
  : m_length{ length }, m_width{ width }, m_height{ height }
{
  std::cout << "Box constructor called." << std::endl;
}

// Member function definition
double Box::volume()
{
  return m_length * m_width * m_height;
}

// Mutator function definitions
Box& Box::setLength(double length)
{
  if (length > 0) m_length = length;
  return *this;
}
Box& Box::setWidth(double width)
{
  if (width > 0) m_width = width;
  return *this;
}
Box& Box::setHeight(double height)
{
  if (height > 0) m_height = height;
  return *this;
}


================================================
FILE: Examples/Modules/Chapter 12/Ex12_08/Box.cppm
================================================
export module box;

export class Box
{
public:
  // Constructors
  Box() = default;
  Box(double length, double width, double height);

  double volume();    // Function to calculate the volume of a box

  // Inspector functions
  double getLength() { return m_length; }
  double getWidth()  { return m_width; }
  double getHeight() { return m_height; }

  // Mutator functions
  Box& setLength(double length);
  Box& setWidth(double width);
  Box& setHeight(double height);

private:
  double m_length{1.0};
  double m_width {1.0};
  double m_height{1.0};
};


================================================
FILE: Examples/Modules/Chapter 12/Ex12_08/Ex12_08.cpp
================================================
// Accessing private members through getters and setters (method chaining variant)
import <iostream>;
import box;

int main()
{
  Box myBox {3.0, 4.0, 5.0};
  std::cout << "myBox dimensions are " << myBox.getLength()
            << " by " << myBox.getWidth()
            << " by " << myBox.getHeight() << std::endl;

  myBox.setLength(-20.0).setWidth(40.0).setHeight(10.0); // Set all dimensions of myBox

  std::cout << "myBox dimensions are now " << myBox.getLength()  // 3 (unchanged)
    << " by " << myBox.getWidth()                        // by 40
    << " by " << myBox.getHeight() << std::endl;         // by 10
}


================================================
FILE: Examples/Modules/Chapter 12/Ex12_09/Box.cpp
================================================
module box;

import <iostream>;

// Constructor definition
Box::Box(double length, double width, double height)
  : m_length{ length }, m_width{ width }, m_height{ height }
{
  std::cout << "Box constructor called." << std::endl;
}

// Const member function definition
double Box::volume() const
{
  return m_length * m_width * m_height;
}


================================================
FILE: Examples/Modules/Chapter 12/Ex12_09/Box.cppm
================================================
export module box;

export class Box
{
public:
  // Constructors
  Box() = default;
  Box(double length, double width, double height);

  double volume() const;    // Const function to calculate the volume of a box

  // Functions to provide access to the values of member variables (all const!)
  double getLength() const { return m_length; }
  double getWidth()  const { return m_width; }
  double getHeight() const { return m_height; }

  // Functions to set member variable values (not const!)
  void setLength(double length) { if (length > 0) m_length = length; }
  void setWidth(double width)   { if (width > 0)  m_width  = width;  }
  void setHeight(double height) { if (height > 0) m_height = height; }

private:
  double m_length{1.0};
  double m_width {1.0};
  double m_height{1.0};
};


================================================
FILE: Examples/Modules/Chapter 12/Ex12_09/Ex12_09.cpp
================================================
// Const objects and const member functions
import <iostream>;
import box;

int main()
{
  // v-- this const was added...
  const Box myBox {3.0, 4.0, 5.0};
  std::cout << "myBox dimensions are " << myBox.getLength()
            << " by " << myBox.getWidth()
            << " by " << myBox.getHeight() << std::endl;

  // Invoking mutators / setters is not possible on a const object:
  //myBox.setLength(-20.0);       // ignored!
  //myBox.setWidth(40.0);
  //myBox.setHeight(10.0);
  //std::cout << "myBox dimensions are now " << myBox.getLength()  // 3 (unchanged)
  //  << " by " << myBox.getWidth()                        // by 40
  //  << " by " << myBox.getHeight() << std::endl;         // by 10

  std::cout << "myBox's volume is " << myBox.volume() << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 12/Ex12_10/Box.cpp
================================================
module box;
import <iostream>;

// Constructor definition
Box::Box(double length, double width, double height)
  : m_length{ length }, m_width{ width }, m_height{ height }
{
  std::cout << "Box constructor called." << std::endl;
}

// Const member function definition
double Box::volume() const
{
  return m_length * m_width * m_height;
}


================================================
FILE: Examples/Modules/Chapter 12/Ex12_10/Box.cppm
================================================
export module box;
import <iostream>;

export class Box
{
public:
  // Constructors
  Box() = default;
  Box(double length, double width, double height);

  double volume() const;    // Const function to calculate the volume of a box

  // Non-const overloads (return references to dimension variable)
  double& length() { std::cout << "non-const overload called\n"; return m_length; };
  double& width()  { std::cout << "non-const overload called\n"; return m_width; };
  double& height() { std::cout << "non-const overload called\n"; return m_height; };

  // Const overloads (return references to const variables)
  const double& length() const { std::cout << "const overload called\n"; return m_length; };
  const double& width()  const { std::cout << "const overload called\n"; return m_width; };
  const double& height() const { std::cout << "const overload called\n"; return m_height; };

  // Attempt to return non-const references to member variables from const functions
// double& length() const { return m_length; };   // This must not be allowed to compile!
// double& width()  const { return m_width; };
// double& height() const { return m_height; };

private:
  double m_length{1.0};
  double m_width {1.0};
  double m_height{1.0};
};


================================================
FILE: Examples/Modules/Chapter 12/Ex12_10/Ex12_10.cpp
================================================
// Overloading on const
import <iostream>;
import box;

int main()
{
  const Box constBox{ 1, 2, 3 };
  // constBox.length() = 2;                          // Does not compile: good!
  std::cout << constBox.length() << std::endl;

  Box nonConstBox{ 3, 2, 1 };
  nonConstBox.length() *= 2;
  std::cout << nonConstBox.length() << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 12/Ex12_11/Box.cpp
================================================
module box;

import <iostream>;

// Constructor definition
Box::Box(double length, double width, double height)
  : m_length{ length }, m_width{ width }, m_height{ height }
{
  std::cout << "Box constructor called." << std::endl;
}

// Const member function definition
double Box::volume() const
{
  return m_length * m_width * m_height;
}

// Modify mutable member variable from a const member function 
void Box::printVolume() const
{
  // Count how many times printVolume() is called using a mutable member in a const function
  std::cout << "The volume of this box is " << volume() << std::endl;
  std::cout << "printVolume() has been called " << ++m_count << " time(s)" << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 12/Ex12_11/Box.cppm
================================================
export module box;

export class Box
{
public:
  // Constructors
  Box() = default;
  Box(double length, double width, double height);

  double volume() const;      // Function to calculate the volume of a box
  void printVolume() const;   // Function to print out the volume of a box (const!)

  // Functions to provide access to the values of member variables (all const!)
  double getLength() const { return m_length; }
  double getWidth()  const { return m_width; }
  double getHeight() const { return m_height; }

  // Functions to set member variable values (not const!)
  void setLength(double length) { if (length > 0) m_length = length; }
  void setWidth(double width)   { if (width > 0)  m_width  = width;  }
  void setHeight(double height) { if (height > 0) m_height = height; }

private:
  double m_length{1.0};
  double m_width {1.0};
  double m_height{1.0};
  mutable unsigned m_count{};   // Counts the amount of time printVolume() is called
};


================================================
FILE: Examples/Modules/Chapter 12/Ex12_11/Ex12_11.cpp
================================================
// Const objects and const member functions
import <iostream>;
import box;

int main()
{
  const Box myBox {3.0, 4.0, 5.0};
  std::cout << "myBox dimensions are " << myBox.getLength()
            << " by " << myBox.getWidth()
            << " by " << myBox.getHeight() << std::endl;

  myBox.printVolume();
  myBox.printVolume();
  myBox.printVolume();
}


================================================
FILE: Examples/Modules/Chapter 12/Ex12_12/Box.cpp
================================================
module box;

import <iostream>;

// Constructor definition
Box::Box(double length, double width, double height)
  : m_length{ length }, m_width{ width }, m_height{ height }
{
  std::cout << "Box constructor called." << std::endl;
}

// Const member function definition
double Box::volume() const
{
  return m_length * m_width * m_height;
}


================================================
FILE: Examples/Modules/Chapter 12/Ex12_12/Box.cppm
================================================
export module box;

export class Box
{
public:
  Box() : Box{ 1.0, 1.0, 1.0} {}        // A delegating default constructor
  Box(double length, double width, double height);

  double volume() const;                // Function to calculate the volume of a box

  friend double surfaceArea(const Box& box); // Friend function for the surface area

private:
  double m_length, m_width, m_height;
};


================================================
FILE: Examples/Modules/Chapter 12/Ex12_12/Ex12_12.cpp
================================================
// Using a friend function of a class
import <iostream>;
import <memory>;
import box;

int main()
{
  Box box1 {2.2, 1.1, 0.5};    // An arbitrary box
  Box box2;                    // A default box
  auto box3{ std::make_unique<Box>(15.0, 20.0, 8.0) }; // Dynamically allocated Box

  std::cout << "Volume of box1 = " << box1.volume() << std::endl;
  std::cout << "Surface area of box1 = " << surfaceArea(box1) << std::endl;

  std::cout << "Volume of box2 = "<< box2.volume() << std::endl;
  std::cout << "Surface area of box2 = " << surfaceArea(box2) << std::endl;

  std::cout << "Volume of box3 = " << box3->volume() << std::endl;
  std::cout << "Surface area of box3 = " << surfaceArea(*box3) << std::endl;
}

// friend function to calculate the surface area of a Box object
double surfaceArea(const Box& box)
{
  return 2.0 * (box.m_length * box.m_width
    + box.m_length * box.m_height + box.m_height * box.m_width);
}


================================================
FILE: Examples/Modules/Chapter 12/Ex12_13/Box.cpp
================================================
module box;

import <iostream>;

Box::Box(double length, double width, double height)  // Constructor definition
  : m_length{length}, m_width{width}, m_height{height}
{
  std::cout << "Box constructor 1 called." << std::endl;
}

Box::Box(double side) : Box{side, side, side}  // Constructor for a cube
{
  std::cout << "Box constructor 2 called." << std::endl;
}

Box::Box()                                      // Default constructor
{
  std::cout << "Default Box constructor called." << std::endl;
}

Box::Box(const Box& box)                        // Copy constructor
  : m_length{box.m_length}, m_width{box.m_width}, m_height{box.m_height}
{
  std::cout << "Box copy constructor called." << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 12/Ex12_13/Box.cppm
================================================
export module box;

export class Box
{
public:
  /* Constructors */
  Box(double length, double width, double height);
  Box(double side);       // Constructor for a cube
  Box();                  // Default constructor
  Box(const Box& box);    // Copy constructor

  double volume() const { return m_length * m_width * m_height; };

private:
  double m_length {1.0};
  double m_width {1.0};
  double m_height {1.0};
};


================================================
FILE: Examples/Modules/Chapter 12/Ex12_13/Ex12_13.cpp
================================================
// Creating an array of objects
import <iostream>;
import box;

int main()
{
  const Box box1 {2.0, 3.0, 4.0};  // An arbitrary box
  Box box2 {5.0};                  // A box that is a cube
  std::cout << "box1 volume = " << box1.volume() << std::endl;
  std::cout << "box2 volume = " << box2.volume() << std::endl;
  Box box3 {box2};
  std::cout << "box3 volume = " << box3.volume() << std::endl;   // Volume = 125

  std::cout << std::endl;

  Box boxes[6] {box1, box2, box3, Box {2.0}};
}


================================================
FILE: Examples/Modules/Chapter 12/Ex12_14/Box.cpp
================================================
module box;
import <iostream>;

Box::Box(double length, double width, double height)  // Constructor definition
  : m_length{length}, m_width{width}, m_height{height}
{
  ++s_object_count;
  std::cout << "Box constructor 1 called." << std::endl;
}

Box::Box(double side) : Box{side, side, side}  // Constructor for a cube
{
  // Do not increment s_object_count in forwarding constructor: 
  // already incremented in the constructor this constructor forwards to!
  std::cout << "Box constructor 2 called." << std::endl;
}

Box::Box()                                      // Default constructor
{
  ++s_object_count;
  std::cout << "Default Box constructor called." << std::endl;
}

Box::Box(const Box& box)                        // Copy constructor
  : m_length{box.m_length}, m_width{box.m_width}, m_height{box.m_height}
{
  ++s_object_count;
  std::cout << "Box copy constructor called." << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 12/Ex12_14/Box.cppm
================================================
export module box;

export class Box
{
public:
  Box();                     // Default constructor  
  Box(double side);          // Constructor for a cube
  Box(const Box& box);       // Copy constructor
  Box(double length, double width, double height);

  double volume() const { return m_length * m_width * m_height; }

  size_t getObjectCount() const { return s_object_count; }

private:
  double m_length {1.0};
  double m_width {1.0};
  double m_height {1.0};
  static inline size_t s_object_count {};   // Count of objects ever created
};


================================================
FILE: Examples/Modules/Chapter 12/Ex12_14/Ex12_14.cpp
================================================
// Using a static member variable
import <iostream>;
import box;

int main()
{
  const Box box1 {2.0, 3.0, 4.0};                              // An arbitrary box
  Box box2 {5.0};                                              // A box that is a cube
  std::cout << "box1 volume = " << box1.volume() << std::endl;
  std::cout << "box2 volume = " << box2.volume() << std::endl;
  Box box3 {box2};
  std::cout << "box3 volume = " << box3.volume() << std::endl; // Volume = 125

  std::cout << std::endl;

  Box boxes[6] {box1, box2, box3, Box {2.0}};

  std::cout << "\nThere are now " << box1.getObjectCount() << " Box objects.\n";
}


================================================
FILE: Examples/Modules/Chapter 12/Ex12_15/CylindricalBox.cpp
================================================
module cylindrical;

import <iostream>;

CylindricalBox::CylindricalBox(float radius, float height, std::string_view material)
  : m_radius{ radius }
  , m_height{ height }
  , m_material{ material }
{
  std::cout << "Box constructed consisting of " << material;
  if (material == s_default_material)
  {
    std::cout << " (the default material!)";
  }
  std::cout << std::endl;
}

float CylindricalBox::volume() const
{
  return PI * m_radius * m_radius * m_height;
}



================================================
FILE: Examples/Modules/Chapter 12/Ex12_15/CylindricalBox.cppm
================================================
export module cylindrical;

import <string>;
import <string_view>;

export class CylindricalBox
{
public:
  static inline const float s_max_radius { 35.0f };
  static inline const float s_max_height { 60.0f };
  static inline const std::string_view s_default_material { "paperboard" };

  CylindricalBox(float radius, float height,
                 std::string_view material = s_default_material);
  float volume() const;

private:
  // The value of PI used by CylindricalBox's volume() function
  static inline const float PI { 3.141592f };  

  float m_radius;
  float m_height;
  std::string m_material;
};


================================================
FILE: Examples/Modules/Chapter 12/Ex12_15/Ex12_15.cpp
================================================
// Defining and using static constants
import <iostream>;
import cylindrical;

int main()
{
  CylindricalBox bigBox{ 1.23f,
            CylindricalBox::s_max_height, CylindricalBox::s_default_material };
  std::cout << "The volume of bigBox is " <<  bigBox.volume() << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 12/Ex12_16/Box.cpp
================================================
module box;
import <iostream>;

Box::Box(double length, double width, double height)  // Constructor definition
  : m_length{length}, m_width{width}, m_height{height}
{
  ++s_object_count;
  std::cout << "Box constructor 1 called." << std::endl;
}

Box::Box(double side) : Box{side, side, side}  // Constructor for a cube
{
  // Do not increment s_object_count in forwarding constructor: 
  // already incremented in the constructor this constructor forwards to!
  std::cout << "Box constructor 2 called." << std::endl;
}

Box::Box()                                      // Default constructor
{
  ++s_object_count;
  std::cout << "Default Box constructor called." << std::endl;
}

Box::Box(const Box& box)                        // Copy constructor
  : m_length{box.m_length}, m_width{box.m_width}, m_height{box.m_height}
{
  ++s_object_count;
  std::cout << "Box copy constructor called." << std::endl;
}

Box::~Box()                              // Destructor
{
  std::cout << "Box destructor called." << std::endl;
  --s_object_count;
}


================================================
FILE: Examples/Modules/Chapter 12/Ex12_16/Box.cppm
================================================
export module box;

export class Box
{
public:
  Box();                     // Default constructor  
  Box(double side);          // Constructor for a cube
  Box(const Box& box);       // Copy constructor
  Box(double length, double width, double height);
  ~Box();   // Destructor

  double volume() const { return m_length * m_width * m_height; }

  static size_t getObjectCount() { return s_object_count; }

private:
  double m_length {1.0};
  double m_width {1.0};
  double m_height {1.0};
  static inline size_t s_object_count {};   // Count of objects ever created
};


================================================
FILE: Examples/Modules/Chapter 12/Ex12_16/Ex12_16.cpp
================================================
// Implementing a destructor
import <iostream>;
import box;

int main()
{
  std::cout << "There are now " << Box::getObjectCount() << " Box objects." << std::endl;

  const Box box1 {2.0, 3.0, 4.0};     // An arbitrary box
  Box box2 {5.0};                     // A box that is a cube

  std::cout << "There are now " << Box::getObjectCount() << " Box objects." << std::endl;

  for (double d {} ; d < 3.0 ; ++d)
  {
    Box box {d, d + 1.0, d + 2.0};
    std::cout << "Box volume is " << box.volume() << std::endl;
  }

  std::cout << "There are now " << Box::getObjectCount() << " Box objects." << std::endl;

  auto pBox{ std::make_unique<Box>(1.5, 2.5, 3.5) };
  std::cout << "Box volume is " << pBox->volume() << std::endl;
  std::cout << "There are now " << pBox->getObjectCount() << " Box objects." << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 12/Ex12_17/Box.cppm
================================================
export module box;

import <iostream>;
import <format>;

export class Box
{
public:
  Box() = default;
  Box(double length, double width, double height) 
    : m_length{length}, m_width{width}, m_height{height} {};

  double volume() const 
  {
    return m_length * m_width * m_height;
  }

  int compare(const Box& box) const
  {
    if (volume() < box.volume()) return -1;
    if (volume() == box.volume()) return 0;
    return +1;
  }

  void listBox() const
  {
    std::cout << std::format("Box({:.1f},{:.1f},{:.1f})", m_length, m_width, m_height);
  }

private:
  double m_length {1.0};
  double m_width {1.0};
  double m_height {1.0};
};


================================================
FILE: Examples/Modules/Chapter 12/Ex12_17/Ex12_17.cpp
================================================
// Using a linked list
import box.random;
import truckload;
import <iostream>;

int main()  
{
  Truckload load1;  // Create an empty list

  // Add 12 random Box objects to the list
  const size_t boxCount {12};
  for (size_t i {} ; i < boxCount ; ++i)
    load1.addBox(randomSharedBox());

  std::cout << "The first list:\n";
  load1.listBoxes();

  // Copy the truckload
  Truckload copy{load1};
  std::cout << "The copied truckload:\n";
  copy.listBoxes();

  // Find the largest Box in the list
  SharedBox largestBox{load1.getFirstBox()};

  SharedBox nextBox{load1.getNextBox()};
  while (nextBox)
  {
    if (nextBox->compare(*largestBox) > 0)
      largestBox = nextBox;
    nextBox = load1.getNextBox();
  }

  std::cout << "\nThe largest box in the first list is ";
  largestBox->listBox();
  std::cout << std::endl;
  load1.removeBox(largestBox);
  std::cout << "\nAfter deleting the largest box, the list contains:\n";
  load1.listBoxes();

  const size_t nBoxes {20};            // Number of vector elements
  std::vector<SharedBox> boxes;        // Array of Box objects

  for (size_t i {} ; i < nBoxes ; ++i)
    boxes.push_back(randomSharedBox());

  Truckload load2{boxes};
  std::cout << "\nThe second list:\n";
  load2.listBoxes();

  auto smallestBox{ load2.getFirstBox() };
  for (auto box{ load2.getNextBox() }; box; box = load2.getNextBox())
    if (box->compare(*smallestBox) < 0)
      smallestBox = box;

  std::cout << "\nThe smallest box in the second list is ";
  smallestBox->listBox();
  std::cout << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 12/Ex12_17/Package.cpp
================================================
module truckload:package;

import :shared_box;

class Package
{
public:
  Package(SharedBox box) : m_box{box}, m_next{nullptr} {}  // Constructor
  ~Package() { delete m_next; }                            // Destructor

  // Retrieve the Box pointer
  SharedBox getBox() const { return m_box; }

  // Retrieve or update the pointer to the next Package
  Package* getNext() { return m_next; }
  void setNext(Package* package) { m_next = package; }

private:
  SharedBox m_box;    // Pointer to the Box object contained in this Package
  Package* m_next;    // Pointer to the next Package in the list
};


================================================
FILE: Examples/Modules/Chapter 12/Ex12_17/RandomBoxes.cppm
================================================
export module box.random;
import box;
import <random>;        // For random number generation
import <functional>;    // For std::bind()
import <memory>;        // For std::make_shared<>() and std::shared_ptr<>;

// Creates a pseudorandom number generator (PRNG) for random doubles between 0 and max
auto createUniformPseudoRandomNumberGenerator(double max)
{
  std::random_device seeder;      // True random number generator to obtain a seed (slow)
  std::default_random_engine generator{ seeder() };    // Efficient pseudo-random generator
  std::uniform_real_distribution distribution{ 0.0, max }; // Generate in [0, max) interval
  return std::bind(distribution, generator);         //... and in the darkness bind them!
}

export Box randomBox()
{
  const int dimLimit{ 100 };          // Upper limit on Box dimensions
  static auto random{ createUniformPseudoRandomNumberGenerator(dimLimit) };
  return { random(), random(), random() };
}

export auto randomSharedBox()
{
  return std::make_shared<Box>(randomBox());   // Uses copy constructor
}


================================================
FILE: Examples/Modules/Chapter 12/Ex12_17/SharedBox.cppm
================================================
export module truckload:shared_box;

import <memory>;
import box;

export using SharedBox = std::shared_ptr<Box>;


================================================
FILE: Examples/Modules/Chapter 12/Ex12_17/Truckload.cpp
================================================
module truckload;

import <iostream>;

// Constructor - one Box (moved to source file to gain access to definition of Package)
Truckload::Truckload(SharedBox box)          
{
  m_head = m_tail = new Package{ box };
}

// Constructor - vector of Boxes
Truckload::Truckload(const std::vector<SharedBox>& boxes)
{
  for (const auto& box : boxes)
  {
    addBox(box);
  }
}

// Copy constructor
Truckload::Truckload(const Truckload& src)
{
  for (Package* package{ src.m_head }; package; package = package->getNext())
  {
    addBox(package->getBox());
  }
}

// Destructor: clean up the list (moved to source file to gain access to definition of Package)
Truckload::~Truckload()
{
  delete m_head;
}

void Truckload::listBoxes() const
{
  const size_t boxesPerLine{ 4 };
  size_t count {};  
  for (Package* package{m_head}; package; package = package->getNext())
  {
    std::cout << ' ';
    package->getBox()->listBox();
    if (! (++count % boxesPerLine)) std::cout << std::endl;
  }
  if (count % boxesPerLine) std::cout << std::endl;
}


SharedBox Truckload::getFirstBox()
{
  // Return m_head's box (or nullptr if the list is empty)
  m_current = m_head;
  return m_current? m_current->getBox() : nullptr;
}

SharedBox Truckload::getNextBox()
{
  if (!m_current)                                    // If there's no current...
    return getFirstBox();                            // ...return the 1st Box

  m_current = m_current->getNext();                  // Move to the next package

  return m_current? m_current->getBox() : nullptr;   // Return its box (or nullptr...).
}

void Truckload::addBox(SharedBox box)
{
  auto package{ new Package{box} }; // Create a new Package

  if (m_tail)                      // Check list is not empty
    m_tail->setNext(package);      // Append the new object to the tail
  else                             // List is empty
    m_head = package;              // so new object is the head

  m_tail = package;                // Either way: the latest object is the (new) tail
}

bool Truckload::removeBox(SharedBox boxToRemove)
{
  Package* previous {nullptr};      // no previous yet
  Package* current {m_head};        // initialize current to the head of the list
  while (current)
  {
    if (current->getBox() == boxToRemove)      // We found the Box!
    {
      // If there is a previous Package make it point to the next one (Figure 12.10)
      if (previous) previous->setNext(current->getNext());

      // Update pointers in member variables where required:
      if (current == m_head) m_head = current->getNext();
      if (current == m_tail) m_tail = previous;
      if (current == m_current) m_current = current->getNext();

      current->setNext(nullptr);        // Disconnect the current Package from the list
      delete current;                   // and delete it

      return true;                      // Return true: we found and removed the box
    }
                                        // Move both pointers along (mind the order!)
    previous = current;                 //  - first current becomes the new previous
    current = current->getNext();       //  - then move current along to the next Package
  }

  return false;     // Return false: boxToRemove was not found
}


================================================
FILE: Examples/Modules/Chapter 12/Ex12_17/Truckload.cppm
================================================
export module truckload;

export import :shared_box;
import :package;
import <vector>;

export class Truckload
{
public:
  Truckload() = default;            // Default constructor - empty truckload

  Truckload(SharedBox box);         // Constructor - one Box
  Truckload(const std::vector<SharedBox>& boxes);  // Constructor - vector of Boxes
  Truckload(const Truckload& src);  // Copy constructor

  ~Truckload();                     // Destructor

  SharedBox getFirstBox();          // Get the first Box
  SharedBox getNextBox();           // Get the next Box
  void addBox(SharedBox box);       // Add a new SharedBox
  bool removeBox(SharedBox box);    // Remove a Box from the Truckload
  void listBoxes() const;           // Output the Boxes

private:
  Package* m_head {};               // First in the list
  Package* m_tail {};               // Last in the list
  Package* m_current {};            // Last retrieved from the list
};


================================================
FILE: Examples/Modules/Chapter 12/Ex12_18/Box.cppm
================================================
export module box;

import <iostream>;
import <format>;

export class Box
{
public:
  Box() = default;
  Box(double length, double width, double height) 
    : m_length{length}, m_width{width}, m_height{height} {};

  double volume() const 
  {
    return m_length * m_width * m_height;
  }

  int compare(const Box& box) const
  {
    if (volume() < box.volume()) return -1;
    if (volume() == box.volume()) return 0;
    return +1;
  }

  void listBox() const
  {
    std::cout << std::format("Box({:.1f},{:.1f},{:.1f})", m_length, m_width, m_height);
  }

private:
  double m_length {1.0};
  double m_width {1.0};
  double m_height {1.0};
};


================================================
FILE: Examples/Modules/Chapter 12/Ex12_18/Ex12_18.cpp
================================================
// Using nested classes
import box.random;
import truckload;
import <iostream>;

int main()  
{
  Truckload load1;  // Create an empty list

  // Add 12 random Box objects to the list
  const size_t boxCount {12};
  for (size_t i {} ; i < boxCount ; ++i)
    load1.addBox(randomSharedBox());

  std::cout << "The first list:\n";
  load1.listBoxes();

  // Copy the truckload
  Truckload copy{load1};
  std::cout << "The copied truckload:\n";
  copy.listBoxes();

  // Find the largest Box in the list
  SharedBox largestBox{load1.getFirstBox()};

  SharedBox nextBox{load1.getNextBox()};
  while (nextBox)
  {
    if (nextBox->compare(*largestBox) > 0)
      largestBox = nextBox;
    nextBox = load1.getNextBox();
  }

  std::cout << "\nThe largest box in the first list is ";
  largestBox->listBox();
  std::cout << std::endl;
  load1.removeBox(largestBox);
  std::cout << "\nAfter deleting the largest box, the list contains:\n";
  load1.listBoxes();

  const size_t nBoxes {20};            // Number of vector elements
  std::vector<SharedBox> boxes;        // Array of Box objects

  for (size_t i {} ; i < nBoxes ; ++i)
    boxes.push_back(randomSharedBox());

  Truckload load2{boxes};
  std::cout << "\nThe second list:\n";
  load2.listBoxes();

  auto smallestBox{ load2.getFirstBox() };
  for (auto box{ load2.getNextBox() }; box; box = load2.getNextBox())
    if (box->compare(*smallestBox) < 0)
      smallestBox = box;

  std::cout << "\nThe smallest box in the second list is ";
  smallestBox->listBox();
  std::cout << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 12/Ex12_18/RandomBoxes.cppm
================================================
export module box.random;

import box;
import <random>;        // For random number generation
import <functional>;    // For std::bind()
import <memory>;        // For std::make_shared<>() and std::shared_ptr<>;

// Creates a pseudorandom number generator (PRNG) for random doubles between 0 and max
auto createUniformPseudoRandomNumberGenerator(double max)
{
  std::random_device seeder;      // True random number generator to obtain a seed (slow)
  std::default_random_engine generator{ seeder() };    // Efficient pseudo-random generator
  std::uniform_real_distribution distribution{ 0.0, max }; // Generate in [0, max) interval
  return std::bind(distribution, generator);         //... and in the darkness bind them!
}

export Box randomBox()
{
  const int dimLimit{ 100 };          // Upper limit on Box dimensions
  static auto random{ createUniformPseudoRandomNumberGenerator(dimLimit) };
  return Box{ random(), random(), random() };
}

export auto randomSharedBox()
{
  return std::make_shared<Box>(randomBox());   // Uses copy constructor
}


================================================
FILE: Examples/Modules/Chapter 12/Ex12_18/Truckload.cpp
================================================
module truckload;
import <iostream>;

// Constructor - one Box (moved to source file to gain access to definition of Package)
Truckload::Truckload(SharedBox box)          
{
  m_head = m_tail = new Package{ box };
}

// Constructor - vector of Boxes
Truckload::Truckload(const std::vector<SharedBox>& boxes)
{
  for (const auto& box : boxes)
  {
    addBox(box);
  }
}

// Copy constructor
Truckload::Truckload(const Truckload& src)
{
  for (Package* package{ src.m_head }; package; package = package->m_next)
  {
    addBox(package->m_box);
  }
}

// Destructor: clean up the list (moved to source file to gain access to definition of Package)
Truckload::~Truckload()
{
  delete m_head;
}

void Truckload::listBoxes() const
{
  const size_t boxesPerLine{ 4 };
  size_t count {};  
  for (Package* package{m_head}; package; package = package->m_next)
  {
    std::cout << ' ';
    package->m_box->listBox();
    if (! (++count % boxesPerLine)) std::cout << std::endl;
  }
  if (count % boxesPerLine) std::cout << std::endl;
}


SharedBox Truckload::getFirstBox()
{
  // Return m_head's box (or nullptr if the list is empty)
  m_current = m_head;
  return m_current? m_current->m_box : nullptr;
}

SharedBox Truckload::getNextBox()
{
  if (!m_current)                                 // If there's no current...
    return getFirstBox();                         // ...return the 1st Box

  m_current = m_current->m_next;                  // Move to the next package

  return m_current? m_current->m_box : nullptr;   // Return its box (or nullptr...).
}

void Truckload::addBox(SharedBox box)
{
  auto package{ new Package{box} }; // Create a new Package

  if (m_tail)                      // Check list is not empty
    m_tail->m_next = package;      // Append the new object to the tail
  else                             // List is empty
    m_head = package;              // so new object is the head

  m_tail = package;                // Either way: the latest object is the (new) tail
}

bool Truckload::removeBox(SharedBox boxToRemove)
{
  Package* previous {nullptr};       // no previous yet
  Package* current {m_head};         // initialize current to the head of the list
  while (current)
  {
    if (current->m_box == boxToRemove)      // We found the Box!
    {
      // If there is a previous Package make it point to the next one (Figure 12.10)
      if (previous) previous->m_next = current->m_next;

      // Update pointers in member variables where required:
      if (current == m_head) m_head = current->m_next;
      if (current == m_tail) m_tail = previous;
      if (current == m_current) m_current = current->m_next;
                                     
      current->m_next = nullptr;     // Disconnect the current Package from the list
      delete current;                // and delete it
                                     
      return true;                   // Return true: we found and removed the box
    }                                
                                     // Move both pointers along (mind the order!)
    previous = current;              //  - first current becomes the new previous
    current = current->m_next;       //  - then move current along to the next Package
  }

  return false;     // Return false: boxToRemove was not found
}


================================================
FILE: Examples/Modules/Chapter 12/Ex12_18/Truckload.cppm
================================================
export module truckload;
import box;

import <memory>;
import <vector>;

export using SharedBox = std::shared_ptr<Box>;

export class Truckload
{
public:
  Truckload() = default;            // Default constructor - empty truckload

  Truckload(SharedBox box);         // Constructor - one Box
  Truckload(const std::vector<SharedBox>& boxes);  // Constructor - vector of Boxes
  Truckload(const Truckload& src);  // Copy constructor

  ~Truckload();                     // Destructor

  SharedBox getFirstBox();          // Get the first Box
  SharedBox getNextBox();           // Get the next Box
  void addBox(SharedBox box);       // Add a new SharedBox
  bool removeBox(SharedBox box);    // Remove a Box from the Truckload
  void listBoxes() const;           // Output the Boxes

private:
  class Package
  {
  public:
    SharedBox m_box;      // Pointer to the Box object contained in this Package
    Package* m_next;      // Pointer to the next Package in the list

    Package(SharedBox box) : m_box{ box }, m_next{ nullptr } {} // Constructor
    ~Package() { delete m_next; }                           // Destructor
  };

  Package* m_head {};               // First in the list
  Package* m_tail {};               // Last in the list
  Package* m_current {};            // Last retrieved from the list
};


================================================
FILE: Examples/Modules/Chapter 13/Ex13_01/Box.cppm
================================================
export module box;

export class Box
{
public:
  // Constructors
  Box() = default;
  Box(double l, double w, double h) : m_length{l}, m_width{w}, m_height{h} {}

  double volume() const { return m_length * m_width * m_height; }

  // Accessors
  double getLength() const { return m_length; }
  double getWidth()  const { return m_width; }
  double getHeight() const { return m_height; }

  bool operator<(const Box& aBox) const     // Less-than operator
  { return volume() < aBox.volume(); }

private:
  double m_length {1.0};
  double m_width {1.0};
  double m_height {1.0};
};


================================================
FILE: Examples/Modules/Chapter 13/Ex13_01/Ex13_01.cpp
================================================
// Implementing a less-than operator
import <iostream>;
import <vector>;
import box;

int main()
{
  std::vector boxes {Box {2.0, 2.0, 3.0}, Box {1.0, 3.0, 2.0},
                     Box {1.0, 2.0, 1.0}, Box {2.0, 3.0, 3.0}};
  Box smallBox {boxes[0]};
  for (const auto& box : boxes)
  {
    if (box < smallBox) smallBox = box;
  }

  std::cout << "The smallest box has dimensions "
    << smallBox.getLength() << 'x'
    << smallBox.getWidth()  << 'x'
    << smallBox.getHeight() << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 13/Ex13_02/Box.cppm
================================================
export module box;

export class Box
{
public:
  // Constructors
  Box() = default;
  Box(double l, double w, double h) : m_length{ l }, m_width{ w }, m_height{ h } {}

  double volume() const { return m_length * m_width * m_height; }

  // Accessors
  double getLength() const { return m_length; }
  double getWidth()  const { return m_width; }
  double getHeight() const { return m_height; }

  bool operator<(const Box& aBox) const    // Less-than operator
  {
    return volume() < aBox.volume();
  }

  bool operator<(double value) const;      // Compare Box volume < double value

private:
  double m_length{ 1.0 };
  double m_width{ 1.0 };
  double m_height{ 1.0 };
};

// Compare the volume of a Box object with a constant
bool Box::operator<(double value) const
{
  return volume() < value;
}

// Function comparing a constant with volume of a Box object
export bool operator<(double value, const Box& aBox)
{
  return value < aBox.volume();
}


================================================
FILE: Examples/Modules/Chapter 13/Ex13_02/Ex13_02.cpp
================================================
// Using the overloaded 'less-than' operators for Box ojects
import <iostream>;
import <vector>;
import <format>;
import box;

// Display box dimensions
void show(const Box& box)
{
  std::cout << std::format("Box {:g}x{:g}x{:g}", 
                 box.getLength(), box.getWidth(), box.getHeight()) << std::endl;
}

int main()
{
  std::vector boxes {Box {2.0, 2.0, 3.0}, Box {1.0, 3.0, 2.0},
                     Box {1.0, 2.0, 1.0}, Box {2.0, 3.0, 3.0}};
  const double minVolume{6.0};
  std::cout << "Objects with volumes less than " << minVolume << " are:\n";
  for (const auto& box : boxes)
    if (box < minVolume) show(box);

  std::cout << "Objects with volumes greater than " << minVolume << " are:\n";
  for (const auto& box : boxes)
    if (minVolume < box) show(box);
}


================================================
FILE: Examples/Modules/Chapter 13/Ex13_03/Box.cppm
================================================
export module box;

import <compare>;  // For std::partial_ordering (see Chapter 4)

export class Box
{
public:
  // Constructors
  Box() = default;
  Box(double l, double w, double h) : m_length{ l }, m_width{ w }, m_height{ h } {}

  double volume() const { return m_length * m_width * m_height; }

  // Accessors
  double getLength() const { return m_length; }
  double getWidth()  const { return m_width; }
  double getHeight() const { return m_height; }

  std::partial_ordering operator<=>(const Box& otherBox) const 
  { 
    return volume() <=> otherBox.volume();
  }
  std::partial_ordering operator<=>(double otherVolume) const 
  { 
    return volume() <=> otherVolume;
  }

  bool operator==(const Box& otherBox) const
  {
    return m_length == otherBox.m_length
        && m_width  == otherBox.m_width
        && m_height == otherBox.m_height; 
  }

private:
  double m_length{ 1.0 };
  double m_width{ 1.0 };
  double m_height{ 1.0 };
};



================================================
FILE: Examples/Modules/Chapter 13/Ex13_03/Ex13_03.cpp
================================================
// Overloading <=> and == to fully support all comparison operators
import <iostream>;
import <format>;
import <string_view>;
import <vector>;
import box;

void show(const Box& box)
{
  std::cout << std::format("Box({:.1f}, {:.1f}, {:.1f})", 
                  box.getLength(), box.getWidth(), box.getHeight());
}
void show(const Box& box1, std::string_view relationship, const Box& box2)
{
  show(box1); std::cout << relationship; show(box2); std::cout << std::endl;
}

int main()
{
  const std::vector boxes {Box {2.0, 1.5, 3.0}, Box {1.0, 3.0, 5.0},
                           Box {1.0, 2.0, 1.0}, Box {2.0, 3.0, 2.0}};
  const Box theBox {3.0, 1.0, 4.0};

  for (const auto& box : boxes)
    if (theBox > box) show(theBox, " is greater than ", box);  // > works

  std::cout << std::endl;

  for (const auto& box : boxes)
    if (theBox != box) show(theBox, " is not equal to ", box); // != works

  std::cout << std::endl;  

  for (const auto& box : boxes)
    if (6.0 <= box)                     // Yes, even double <= Box works!!
      { std::cout << "6 is less than or equal to "; show(box); std::cout << std::endl; }
}


================================================
FILE: Examples/Modules/Chapter 13/Ex13_03A/Box.cppm
================================================
export module box;

import <compare>;  // For std::partial_ordering (see Chapter 4)

export class Box
{
public:
  // Constructors
  Box() = default;
  Box(double l, double w, double h) : m_length{ l }, m_width{ w }, m_height{ h } {}

  double volume() const { return m_length * m_width * m_height; }

  // Accessors
  double getLength() const { return m_length; }
  double getWidth()  const { return m_width; }
  double getHeight() const { return m_height; }

  std::partial_ordering operator<=>(const Box& otherBox) const 
  { 
    return volume() <=> otherBox.volume();
  }
  std::partial_ordering operator<=>(double otherVolume) const 
  { 
    return volume() <=> otherVolume;
  }

  bool operator==(const Box& otherBox) const = default;

private:
  double m_length{ 1.0 };
  double m_width{ 1.0 };
  double m_height{ 1.0 };
};



================================================
FILE: Examples/Modules/Chapter 13/Ex13_03A/Ex13_03A.cpp
================================================
// Defaulting the == operator

import <iostream>;
import <format>;
import <string_view>;
import <vector>;
import box;

void show(const Box& box)
{
  std::cout << std::format("Box({:.1f}, {:.1f}, {:.1f})", 
                  box.getLength(), box.getWidth(), box.getHeight());
}
void show(const Box& box1, std::string_view relationship, const Box& box2)
{
  show(box1); std::cout << relationship; show(box2); std::cout << std::endl;
}

int main()
{
  const std::vector boxes {Box {2.0, 1.5, 3.0}, Box {1.0, 3.0, 5.0},
                           Box {1.0, 2.0, 1.0}, Box {2.0, 3.0, 2.0}};
  const Box theBox {3.0, 1.0, 4.0};

  for (const auto& box : boxes)
    if (theBox > box) show(theBox, " is greater than ", box);  // > works

  std::cout << std::endl;

  for (const auto& box : boxes)
    if (theBox != box) show(theBox, " is not equal to ", box); // != works

  std::cout << std::endl;  

  for (const auto& box : boxes)
    if (6.0 <= box)                     // Yes, even double <= Box works!!
      { std::cout << "6 is less than or equal to "; show(box); std::cout << std::endl; }
}


================================================
FILE: Examples/Modules/Chapter 13/Ex13_04/Box.cppm
================================================
export module box;

import <compare>;  // For std::partial_ordering (see Chapter 4)
import <ostream>;  // For std::ostream
import <format>;

export class Box
{
public:
  // Constructors
  Box() = default;
  Box(double l, double w, double h) : m_length{ l }, m_width{ w }, m_height{ h } {}

  double volume() const { return m_length * m_width * m_height; }

  // Accessors
  double getLength() const { return m_length; }
  double getWidth()  const { return m_width; }
  double getHeight() const { return m_height; }

  std::partial_ordering operator<=>(const Box& otherBox) const 
  { 
    return volume() <=> otherBox.volume();
  }
  std::partial_ordering operator<=>(double otherVolume) const 
  { 
    return volume() <=> otherVolume;
  }

  bool operator==(const Box& otherBox) const = default;

private:
  double m_length{ 1.0 };
  double m_width{ 1.0 };
  double m_height{ 1.0 };
};

export std::ostream& operator<<(std::ostream& stream, const Box& box)
{
  stream << std::format("Box({:.1f}, {:.1f}, {:.1f})",
                             box.getLength(), box.getWidth(), box.getHeight());
  return stream;
}


================================================
FILE: Examples/Modules/Chapter 13/Ex13_04/Ex13_04.cpp
================================================
// Overloading the << operator
import <iostream>;
import <format>;
import <string_view>;
import <vector>;
import box;

int main()
{
  const std::vector boxes {Box {2.0, 1.5, 3.0}, Box {1.0, 3.0, 5.0},
                           Box {1.0, 2.0, 1.0}, Box {2.0, 3.0, 2.0}};
  const Box theBox {3.0, 1.0, 4.0};

  for (const auto& box : boxes)
    if (theBox > box) 
      std::cout << theBox << " is greater than " << box << std::endl;  // > works

  std::cout << std::endl;

  for (const auto& box : boxes)
    if (theBox != box) 
      std::cout << theBox << " is not equal to " << box << std::endl; // != works

  std::cout << std::endl;  

  for (const auto& box : boxes)
    if (6.0 <= box)                     // Yes, even double <= Box works!!
      std::cout << "6 is less than or equal to " << box << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 13/Ex13_05/Box.cpp
================================================
module box;

import <format>;
import <algorithm>;    // For the min() and max() function templates

double Box::volume() const
{
    return m_length * m_width * m_height;
}

Box Box::operator+(const Box& aBox) const
{
  // New object has larger length and width, and sum of heights
  return Box{ std::max(m_length, aBox.m_length),
              std::max(m_width, aBox.m_width),
              m_height + aBox.m_height };
}

std::partial_ordering Box::operator<=>(const Box& aBox) const
{
  return volume() <=> aBox.volume();
}

std::partial_ordering Box::operator<=>(double value) const
{
  return volume() <=> value;
}

std::ostream& operator<<(std::ostream& stream, const Box& box)
{
  stream << std::format("Box({:.1f}, {:.1f}, {:.1f})",
                          box.getLength(), box.getWidth(), box.getHeight());
  return stream;
}

================================================
FILE: Examples/Modules/Chapter 13/Ex13_05/Box.cppm
================================================
export module box;

import <compare>;  // For std::partial_ordering (see Chapter 4)
import <ostream>;  // For std::ostream

export class Box
{
public:
  Box() = default;       // Default constructor
  Box(double length, double width, double height)
    : m_length{ std::max(length,width) }
    , m_width { std::min(length,width) }
    , m_height{ height } 
  {}

  double volume() const; // Function to calculate the volume
  
  // Accessors
  double getLength() const { return m_length; }
  double getWidth() const  { return m_width; }
  double getHeight() const { return m_height; }

  // Functions that add full support for comparison operators
  std::partial_ordering operator<=>(const Box& aBox) const;
  std::partial_ordering operator<=>(double value) const;
  bool operator==(const Box& aBox) const = default;

  Box operator+(const Box& aBox) const;   // Function to add two Box objects

private:
  double m_length {1.0};
  double m_width {1.0};
  double m_height {1.0};
};

export std::ostream& operator<<(std::ostream& stream, const Box& box);


================================================
FILE: Examples/Modules/Chapter 13/Ex13_05/Ex13_05.cpp
================================================
// Using the addition operator for Box objects
import <iostream>;
import <format>;
import <vector>;
import <random>;       // For random number generation
import <functional>;   // For std::bind()
import box;

// See Chapter 12 for an explanation of this function
auto createUniformPseudoRandomNumberGenerator(double max)
{
  std::random_device seeder;        // True random number generator to obtain a seed (slow)
  std::default_random_engine generator{ seeder() };    // Efficient pseudo-random generator
  std::uniform_real_distribution distribution{ 1.0, max }; // Generate in [1, max) interval
  return std::bind(distribution, generator);           //... and in the darkness bind them!
}

int main()
{
  const double limit {99};       // Upper limit on Box dimensions
  auto random { createUniformPseudoRandomNumberGenerator(limit) };

  const size_t boxCount {20}; // Number of Box object to be created
  std::vector<Box> boxes;     // Vector of Box objects

  // Create 20 Box objects
  for (size_t i {}; i < boxCount; ++i)
    boxes.push_back(Box{ random(), random(), random() });

  size_t first {};            // Index of first Box object of pair
  size_t second {1};          // Index of second Box object of pair
  double minVolume {(boxes[first] + boxes[second]).volume()};

  for (size_t i {}; i < boxCount - 1; ++i)
  {  
    for (size_t j {i + 1}; j < boxCount; j++)
    {
      if (boxes[i] + boxes[j] < minVolume)
      {
        first = i;
        second = j;
        minVolume = (boxes[i] + boxes[j]).volume();
      }
    }
  }

  std::cout << "The two boxes that sum to the smallest volume are "
            << boxes[first] << " and " << boxes[second] << '\n';
  std::cout << std::format("The volume of the first box is {:.1f}\n",
                            boxes[first].volume());
  std::cout << std::format("The volume of the second box is {:.1f}\n",
                            boxes[second].volume());
  std::cout << "The sum of these boxes is " << (boxes[first] + boxes[second]) << '\n';
  std::cout << std::format("The volume of the sum is {:.1f}", minVolume) << std::endl;
}


================================================
FILE: Examples/Modules/Chapter 13/Ex13_06/Box.cpp
================================================
module;
#include <cmath>    // For the min() and max() function templates
module box;

import <format>;

double Box::volume() const
{
    return m_length * m_width * m_height;
}

// Overloaded += operator
Box& Box::operator+=(const Box& aBox)
{
  // New object has larger length and width, and sum of heights
  m_length = std::max(m_length, aBox.m_length);
  m_width = std::max(m_width, aBox.m_width);
  m_height += aBox.m_height;
  return *this;
}

// Function to add two Box objects
Box Box::operator+(const Box& aBox) const
{
  Box copy{ *this };
  copy += aBox;
  return copy;
}

std::partial_ordering Box::operator<=>(const Box& aBox) const
{
  return volume() <=> aBox.volume();
}

std::partial_ordering Box::operator<=>(double value) const
{
  return volume() <=> value;
}

std::ostream& operator<<(std::ostream& stream, const Box& box)
{
  stream << std::format("Box({:.1f}, {:.1f}, {:.1f})",
                          box.getLength(), box.getWidth(), box.getHeight());
  return stream;
}

================================================
FILE: Examples/Modules/Chapter 13/Ex13_06/Box.cppm
================================================
export module box;

import <compare>;  // For std::partial_ordering (see Chapter 4)
import <ostream>;  // For std::ostream

export class Box
{
public:
  Box() = default;       // Default constructor
  Box(double length, double width, double height)
    : m_length{ std::max(length,width) }
    , m_width { std::min(length,width) }
    , m_height{ height } 
  {}

  double volume() const; // Function to calculate the volume
  
  // Accessors
  double getLength() const { return m_length; }
  double getWidth() const  { return m_width; }
  double getHeight() const { return m_height; }

  // Functions that add full support for comparison operators
  std::partial_ordering operator<=>(const Box& aBox) const;
  std::partial_ordering operator<=>(double value) const;
  bool operator==(const Box& aBox) const = default;

  Box& operator+=(const Box& aBox);      // Function to add a Box objects
  Box operator+(const Box& aBox) const; // Function to add two Box objects

private:
  double m_length {1.0};
  double m_width {1.0};
  double m_height {1.0};
};

export std::ostream& operator<<(std::ostream& stream, const Box& box);


================================================
FILE: Examples/Modules/Chapter 13/Ex13_06/Ex13_06.cpp
================================================
// Using the addition operator for Box objects
import <iostream>;
import <format>;
import <vector>;
import <random>;       // For random number generation
import <functional>;   // For std::bind()
import box;

// See Chapter 12 for an explanation of this function
auto createUniformPseudoRandomNumberGenerator(double max)
{
  std::random_device seeder;        // True random number generator to obtain a seed (slow)
  std::default_random_engine generator{ seeder() };    // Efficient pseudo-random generator
  std::uniform_real_distribution distribution{ 1.0, max }; // Generate in [1, max) interval
  return std::bind(distribution, generator);           //... and in the darkness bind them!
}

int main()
{
  const double limit {99};       // Upper limit on Box dimensions
  auto random { createUniformPseudoRandomNumberGenerator(limit) };

  const size_t boxCount {20}; // Number of Box object to be created
  std::vector<Box> boxes;     // Vector of Box objects

  // Create 20 Box objects
  for (size_t i {}; i < boxCount; ++i)
    boxes.push_back(Box{ random(), random(), random() });

  size_t first {};            // Index of first Box object of pair
  size_t second {1};          // Index of second Box object of pair
  double minVolume {(boxes[first] + boxes[second]).volume()};

  for (size_t i {}; i < boxCount - 1; ++i)
  {  
    for (size_t j {i + 1}; j < boxCount; j++)
    {
      if (boxes[i] + boxes[j] < minVolume)
      {
        first = i;
        second = j;
        minVolume = (boxes[i] + boxes[j]).volume();
      }
    }
  }

  std::cout << "The two boxes that sum to the smallest volume are "
            << boxes[first] << " and " << boxes[second] << '\n';
  std::cout
Download .txt
gitextract_vz438qf9/

├── .gitmodules
├── Contributing.md
├── Examples/
│   ├── Modules/
│   │   ├── Chapter 01/
│   │   │   ├── Ex1_01.cpp
│   │   │   └── Ex1_02.cpp
│   │   ├── Chapter 02/
│   │   │   ├── Ex2_01.cpp
│   │   │   ├── Ex2_02.cpp
│   │   │   ├── Ex2_03.cpp
│   │   │   ├── Ex2_03A.cpp
│   │   │   ├── Ex2_03B.cpp
│   │   │   ├── Ex2_03C.cpp
│   │   │   ├── Ex2_03D.cpp
│   │   │   ├── Ex2_04.cpp
│   │   │   ├── Ex2_05.cpp
│   │   │   ├── Ex2_06.cpp
│   │   │   ├── Ex2_06B.cpp
│   │   │   └── Ex2_07.cpp
│   │   ├── Chapter 03/
│   │   │   ├── Ex3_01.cpp
│   │   │   ├── Ex3_02.cpp
│   │   │   └── Ex3_03.cpp
│   │   ├── Chapter 04/
│   │   │   ├── Ex4_01.cpp
│   │   │   ├── Ex4_01A.cpp
│   │   │   ├── Ex4_02.cpp
│   │   │   ├── Ex4_02A.cpp
│   │   │   ├── Ex4_03.cpp
│   │   │   ├── Ex4_04.cpp
│   │   │   ├── Ex4_04A.cpp
│   │   │   ├── Ex4_05.cpp
│   │   │   ├── Ex4_06.cpp
│   │   │   ├── Ex4_07.cpp
│   │   │   ├── Ex4_08.cpp
│   │   │   ├── Ex4_09.cpp
│   │   │   └── Ex4_09A.cpp
│   │   ├── Chapter 05/
│   │   │   ├── Ex5_01.cpp
│   │   │   ├── Ex5_02.cpp
│   │   │   ├── Ex5_03.cpp
│   │   │   ├── Ex5_03A.cpp
│   │   │   ├── Ex5_04.cpp
│   │   │   ├── Ex5_04A.cpp
│   │   │   ├── Ex5_05.cpp
│   │   │   ├── Ex5_06.cpp
│   │   │   ├── Ex5_07.cpp
│   │   │   ├── Ex5_07A.cpp
│   │   │   ├── Ex5_08.cpp
│   │   │   ├── Ex5_09.cpp
│   │   │   ├── Ex5_10.cpp
│   │   │   ├── Ex5_11.cpp
│   │   │   ├── Ex5_12.cpp
│   │   │   ├── Ex5_12A.cpp
│   │   │   ├── Ex5_13.cpp
│   │   │   ├── Ex5_14.cpp
│   │   │   └── Ex5_15.cpp
│   │   ├── Chapter 06/
│   │   │   ├── Ex6_01.cpp
│   │   │   ├── Ex6_02.cpp
│   │   │   ├── Ex6_03.cpp
│   │   │   ├── Ex6_04.cpp
│   │   │   ├── Ex6_05.cpp
│   │   │   ├── Ex6_06.cpp
│   │   │   └── Ex6_07.cpp
│   │   ├── Chapter 08/
│   │   │   ├── Ex8_01.cpp
│   │   │   ├── Ex8_02.cpp
│   │   │   ├── Ex8_03.cpp
│   │   │   ├── Ex8_04.cpp
│   │   │   ├── Ex8_05.cpp
│   │   │   ├── Ex8_05A.cpp
│   │   │   ├── Ex8_06.cpp
│   │   │   ├── Ex8_06A.cpp
│   │   │   ├── Ex8_07.cpp
│   │   │   ├── Ex8_08.cpp
│   │   │   ├── Ex8_09A.cpp
│   │   │   ├── Ex8_09B.cpp
│   │   │   ├── Ex8_09C.cpp
│   │   │   ├── Ex8_10.cpp
│   │   │   ├── Ex8_11.cpp
│   │   │   ├── Ex8_12.cpp
│   │   │   ├── Ex8_13.cpp
│   │   │   ├── Ex8_14.cpp
│   │   │   ├── Ex8_15.cpp
│   │   │   ├── Ex8_16.cpp
│   │   │   └── Ex8_17.cpp
│   │   ├── Chapter 09/
│   │   │   ├── Ex9_01.cpp
│   │   │   ├── Ex9_02.cpp
│   │   │   ├── Ex9_03.cpp
│   │   │   └── Ex9_03A.cpp
│   │   ├── Chapter 10/
│   │   │   ├── Ex10_01.cpp
│   │   │   ├── Ex10_02.cpp
│   │   │   ├── Ex10_03.cpp
│   │   │   ├── Ex10_03A.cpp
│   │   │   └── Ex10_04.cpp
│   │   ├── Chapter 11/
│   │   │   ├── Ex11_01/
│   │   │   │   ├── Ex11_01.cpp
│   │   │   │   └── math.cppm
│   │   │   ├── Ex11_01A/
│   │   │   │   ├── Ex11_01A.cpp
│   │   │   │   └── math.cppm
│   │   │   ├── Ex11_01B/
│   │   │   │   ├── Ex11_01B.cpp
│   │   │   │   └── math.cppm
│   │   │   ├── Ex11_02/
│   │   │   │   ├── Ex11_02.cpp
│   │   │   │   ├── from_roman.cpp
│   │   │   │   ├── roman.cppm
│   │   │   │   └── to_roman.cpp
│   │   │   ├── Ex11_03/
│   │   │   │   ├── Ex11_03.cpp
│   │   │   │   ├── from_roman.cpp
│   │   │   │   ├── roman.cppm
│   │   │   │   └── to_roman.cpp
│   │   │   ├── Ex11_04/
│   │   │   │   ├── Ex11_04.cpp
│   │   │   │   ├── from_roman.cpp
│   │   │   │   ├── roman-internals.cpp
│   │   │   │   ├── roman.cppm
│   │   │   │   └── to_roman.cpp
│   │   │   ├── Ex11_05/
│   │   │   │   ├── Ex11_05.cpp
│   │   │   │   ├── from_roman.cpp
│   │   │   │   ├── roman-from.cppm
│   │   │   │   ├── roman-internals.cpp
│   │   │   │   ├── roman-to.cppm
│   │   │   │   └── roman.cppm
│   │   │   ├── Ex11_06/
│   │   │   │   └── Ex11_06.cpp
│   │   │   ├── Ex11_06A/
│   │   │   │   ├── Ex11_06A.cpp
│   │   │   │   └── squaring.cppm
│   │   │   ├── Ex11_06B/
│   │   │   │   ├── Ex11_06B.cpp
│   │   │   │   └── squaring.cppm
│   │   │   ├── Ex11_07/
│   │   │   │   ├── Ex11_07.cpp
│   │   │   │   ├── math.cpp
│   │   │   │   └── math.cppm
│   │   │   └── Ex11_08/
│   │   │       ├── Ex11_08.cpp
│   │   │       └── squaring.cppm
│   │   ├── Chapter 12/
│   │   │   ├── Ex12_01/
│   │   │   │   └── Ex12_01.cpp
│   │   │   ├── Ex12_01A/
│   │   │   │   └── Ex12_01A.cpp
│   │   │   ├── Ex12_02/
│   │   │   │   └── Ex12_02.cpp
│   │   │   ├── Ex12_03/
│   │   │   │   └── Ex12_03.cpp
│   │   │   ├── Ex12_04/
│   │   │   │   └── Ex12_04.cpp
│   │   │   ├── Ex12_05/
│   │   │   │   └── Ex12_05.cpp
│   │   │   ├── Ex12_05A/
│   │   │   │   └── Ex12_05A.cpp
│   │   │   ├── Ex12_06/
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex12_06.cpp
│   │   │   ├── Ex12_06A/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex12_06A.cpp
│   │   │   ├── Ex12_06B/
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex12_06B.cpp
│   │   │   ├── Ex12_07/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex12_07.cpp
│   │   │   ├── Ex12_08/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex12_08.cpp
│   │   │   ├── Ex12_09/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex12_09.cpp
│   │   │   ├── Ex12_10/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex12_10.cpp
│   │   │   ├── Ex12_11/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex12_11.cpp
│   │   │   ├── Ex12_12/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex12_12.cpp
│   │   │   ├── Ex12_13/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex12_13.cpp
│   │   │   ├── Ex12_14/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex12_14.cpp
│   │   │   ├── Ex12_15/
│   │   │   │   ├── CylindricalBox.cpp
│   │   │   │   ├── CylindricalBox.cppm
│   │   │   │   └── Ex12_15.cpp
│   │   │   ├── Ex12_16/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex12_16.cpp
│   │   │   ├── Ex12_17/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Ex12_17.cpp
│   │   │   │   ├── Package.cpp
│   │   │   │   ├── RandomBoxes.cppm
│   │   │   │   ├── SharedBox.cppm
│   │   │   │   ├── Truckload.cpp
│   │   │   │   └── Truckload.cppm
│   │   │   └── Ex12_18/
│   │   │       ├── Box.cppm
│   │   │       ├── Ex12_18.cpp
│   │   │       ├── RandomBoxes.cppm
│   │   │       ├── Truckload.cpp
│   │   │       └── Truckload.cppm
│   │   ├── Chapter 13/
│   │   │   ├── Ex13_01/
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex13_01.cpp
│   │   │   ├── Ex13_02/
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex13_02.cpp
│   │   │   ├── Ex13_03/
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex13_03.cpp
│   │   │   ├── Ex13_03A/
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex13_03A.cpp
│   │   │   ├── Ex13_04/
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex13_04.cpp
│   │   │   ├── Ex13_05/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex13_05.cpp
│   │   │   ├── Ex13_06/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex13_06.cpp
│   │   │   ├── Ex13_07/
│   │   │   │   ├── Ex13_07.cpp
│   │   │   │   └── Integer.cppm
│   │   │   ├── Ex13_08/
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex13_08.cpp
│   │   │   ├── Ex13_09/
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex13_09.cpp
│   │   │   ├── Ex13_10/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Ex13_10.cpp
│   │   │   │   ├── Truckload.cpp
│   │   │   │   └── Truckload.cppm
│   │   │   ├── Ex13_11/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Ex13_11.cpp
│   │   │   │   ├── Truckload.cpp
│   │   │   │   └── Truckload.cppm
│   │   │   ├── Ex13_12/
│   │   │   │   ├── Ex13_12.cpp
│   │   │   │   ├── Message.cpp
│   │   │   │   └── Message.cppm
│   │   │   ├── Ex13_12A/
│   │   │   │   ├── Ex13_12A.cpp
│   │   │   │   ├── Message.cpp
│   │   │   │   └── Message.cppm
│   │   │   └── Ex13_12B/
│   │   │       ├── Ex13_12B.cpp
│   │   │       ├── Message.cpp
│   │   │       └── Message.cppm
│   │   ├── Chapter 14/
│   │   │   ├── Ex14_01/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Carton.cppm
│   │   │   │   └── Ex14_01.cpp
│   │   │   ├── Ex14_01A/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Carton.cppm
│   │   │   │   └── Ex14_01A.cpp
│   │   │   ├── Ex14_02/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Carton.cppm
│   │   │   │   └── Ex14_02.cpp
│   │   │   ├── Ex14_03/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Carton.cppm
│   │   │   │   └── Ex14_03.cpp
│   │   │   ├── Ex14_04/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Carton.cppm
│   │   │   │   └── Ex14_04.cpp
│   │   │   ├── Ex14_04A/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Carton.cppm
│   │   │   │   └── Ex14_04A.cpp
│   │   │   ├── Ex14_04B/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Carton.cppm
│   │   │   │   └── Ex14_04B.cpp
│   │   │   ├── Ex14_04C/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Carton.cppm
│   │   │   │   └── Ex14_04C.cpp
│   │   │   ├── Ex14_05/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Carton.cppm
│   │   │   │   └── Ex14_05.cpp
│   │   │   ├── Ex14_06/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Carton.cppm
│   │   │   │   └── Ex14_06.cpp
│   │   │   ├── Ex14_07/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Carton.cppm
│   │   │   │   ├── CerealPack.cppm
│   │   │   │   ├── Ex14_07.cpp
│   │   │   │   └── FoodContainer.cppm
│   │   │   ├── Ex14_07A/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Carton.cppm
│   │   │   │   ├── CerealPack.cppm
│   │   │   │   ├── Ex14_07A.cpp
│   │   │   │   └── FoodContainer.cppm
│   │   │   └── Ex14_07B/
│   │   │       ├── Box.cppm
│   │   │       ├── Carton.cppm
│   │   │       ├── CerealPack.cppm
│   │   │       ├── Ex14_07B.cpp
│   │   │       └── FoodContainer.cppm
│   │   ├── Chapter 15/
│   │   │   ├── Ex15_01/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Boxes.cppm
│   │   │   │   ├── Ex15_01.cpp
│   │   │   │   └── ToughPack.cppm
│   │   │   ├── Ex15_02/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Boxes.cppm
│   │   │   │   ├── Carton.cppm
│   │   │   │   ├── Ex15_02.cpp
│   │   │   │   └── ToughPack.cppm
│   │   │   ├── Ex15_03/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Boxes.cppm
│   │   │   │   ├── Carton.cppm
│   │   │   │   ├── Ex15_03.cpp
│   │   │   │   └── ToughPack.cppm
│   │   │   ├── Ex15_04/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Boxes.cppm
│   │   │   │   ├── Carton.cppm
│   │   │   │   ├── Ex15_04.cpp
│   │   │   │   └── ToughPack.cppm
│   │   │   ├── Ex15_05/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Boxes.cppm
│   │   │   │   ├── Carton.cppm
│   │   │   │   ├── Ex15_05.cpp
│   │   │   │   └── ToughPack.cppm
│   │   │   ├── Ex15_06/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Boxes.cppm
│   │   │   │   ├── Carton.cppm
│   │   │   │   ├── Ex15_06.cpp
│   │   │   │   └── ToughPack.cppm
│   │   │   ├── Ex15_07/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Boxes.cppm
│   │   │   │   ├── Carton.cppm
│   │   │   │   ├── Ex15_07.cpp
│   │   │   │   └── ToughPack.cppm
│   │   │   ├── Ex15_07A/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Boxes.cppm
│   │   │   │   ├── Carton.cppm
│   │   │   │   ├── Ex15_07A.cpp
│   │   │   │   └── ToughPack.cppm
│   │   │   ├── Ex15_08/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Boxes.cppm
│   │   │   │   ├── Ex14_08.cpp
│   │   │   │   └── ToughPack.cppm
│   │   │   ├── Ex15_09/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Boxes.cppm
│   │   │   │   ├── Carton.cppm
│   │   │   │   └── Ex15_09.cpp
│   │   │   ├── Ex15_10/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── Boxes.cppm
│   │   │   │   ├── Carton.cppm
│   │   │   │   ├── Ex15_10.cpp
│   │   │   │   └── ToughPack.cppm
│   │   │   └── Ex15_11/
│   │   │       ├── Box.cppm
│   │   │       ├── Boxes.cppm
│   │   │       ├── Can.cppm
│   │   │       ├── Carton.cppm
│   │   │       ├── Ex15_11.cpp
│   │   │       ├── ToughPack.cppm
│   │   │       └── Vessel.cppm
│   │   ├── Chapter 16/
│   │   │   ├── Ex16_01/
│   │   │   │   └── Ex16_01.cpp
│   │   │   ├── Ex16_02/
│   │   │   │   ├── Ex16_02.cpp
│   │   │   │   └── Troubles.cppm
│   │   │   ├── Ex16_03/
│   │   │   │   ├── Ex16_03.cpp
│   │   │   │   └── Troubles.cppm
│   │   │   ├── Ex16_04/
│   │   │   │   ├── Ex16_04.cpp
│   │   │   │   └── Troubles.cppm
│   │   │   ├── Ex16_05/
│   │   │   │   ├── Ex16_05.cpp
│   │   │   │   └── Troubles.cppm
│   │   │   ├── Ex16_06/
│   │   │   │   ├── Ex16_06.cpp
│   │   │   │   └── Troubles.cppm
│   │   │   ├── Ex16_07/
│   │   │   │   ├── Ex16_07.cpp
│   │   │   │   └── Troubles.cppm
│   │   │   ├── Ex16_07A/
│   │   │   │   ├── Ex16_07A.cpp
│   │   │   │   └── Troubles.cppm
│   │   │   ├── Ex16_07B/
│   │   │   │   ├── DoubleArrayRAII.cppm
│   │   │   │   ├── Ex16_07B.cpp
│   │   │   │   └── Troubles.cppm
│   │   │   ├── Ex16_07C/
│   │   │   │   ├── Ex16_07C.cpp
│   │   │   │   └── Troubles.cppm
│   │   │   ├── Ex16_07D/
│   │   │   │   ├── Ex16_07D.cpp
│   │   │   │   └── Troubles.cppm
│   │   │   └── Ex16_09/
│   │   │       ├── Box.cppm
│   │   │       ├── DimensionError.cppm
│   │   │       └── Ex16_09.cpp
│   │   ├── Chapter 17/
│   │   │   ├── Ex17_01/
│   │   │   │   ├── Array.cppm
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex17_01.cpp
│   │   │   ├── Ex17_01A/
│   │   │   │   ├── Array.cppm
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex17_01A.cpp
│   │   │   ├── Ex17_02/
│   │   │   │   ├── Array.cppm
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex17_02.cpp
│   │   │   ├── Ex17_02A/
│   │   │   │   ├── Array.cppm
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex17_02A.cpp
│   │   │   ├── Ex17_03/
│   │   │   │   ├── Array.cppm
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex17_03.cpp
│   │   │   ├── Ex17_04/
│   │   │   │   ├── Ex17_04.cpp
│   │   │   │   └── Stack.cppm
│   │   │   ├── Ex17_04A/
│   │   │   │   ├── Ex17_04A.cpp
│   │   │   │   └── Stack.cppm
│   │   │   ├── Ex17_04B/
│   │   │   │   ├── Ex17_04B.cpp
│   │   │   │   └── Stack.cppm
│   │   │   ├── Ex17_05/
│   │   │   │   ├── Ex17_05A.cpp
│   │   │   │   ├── Ex17_05B.cpp
│   │   │   │   └── Ex17_05C.cpp
│   │   │   └── Ex17_06/
│   │   │       └── Ex17_06.cpp
│   │   ├── Chapter 18/
│   │   │   ├── Ex18_01/
│   │   │   │   ├── Array.cppm
│   │   │   │   └── Ex18_01.cpp
│   │   │   ├── Ex18_02/
│   │   │   │   ├── Array.cppm
│   │   │   │   └── Ex18_02.cpp
│   │   │   ├── Ex18_03/
│   │   │   │   ├── Array.cppm
│   │   │   │   └── Ex18_03.cpp
│   │   │   ├── Ex18_04/
│   │   │   │   ├── Array.cppm
│   │   │   │   └── Ex18_04.cpp
│   │   │   ├── Ex18_05A/
│   │   │   │   ├── Array.cppm
│   │   │   │   └── Ex18_05A.cpp
│   │   │   ├── Ex18_05B/
│   │   │   │   ├── Array.cppm
│   │   │   │   └── Ex18_05B.cpp
│   │   │   ├── Ex18_06/
│   │   │   │   ├── Array.cppm
│   │   │   │   └── Ex18_06.cpp
│   │   │   └── Ex18_07/
│   │   │       ├── Array.cppm
│   │   │       └── Ex18_07.cpp
│   │   ├── Chapter 19/
│   │   │   ├── Ex19_01/
│   │   │   │   └── Ex19_01.cpp
│   │   │   ├── Ex19_02/
│   │   │   │   ├── Ex19_02.cpp
│   │   │   │   └── Optimum.cppm
│   │   │   ├── Ex19_03/
│   │   │   │   ├── Ex19_03.cpp
│   │   │   │   ├── Less.cppm
│   │   │   │   └── Optimum.cppm
│   │   │   ├── Ex19_03A/
│   │   │   │   ├── Ex19_03A.cpp
│   │   │   │   └── Optimum.cppm
│   │   │   ├── Ex19_04/
│   │   │   │   ├── Ex19_04.cpp
│   │   │   │   ├── Nearer.cppm
│   │   │   │   └── Optimum.cppm
│   │   │   ├── Ex19_05/
│   │   │   │   ├── Ex19_05.cpp
│   │   │   │   └── Optimum.cppm
│   │   │   ├── Ex19_05A/
│   │   │   │   ├── Ex19_05A.cpp
│   │   │   │   └── Optimum.cppm
│   │   │   ├── Ex19_06/
│   │   │   │   ├── Ex19_06.cpp
│   │   │   │   └── Optimum.cppm
│   │   │   ├── Ex19_07/
│   │   │   │   ├── Ex19_07.cpp
│   │   │   │   ├── Finder.cpp
│   │   │   │   ├── Finder.cppm
│   │   │   │   └── Optimum.cppm
│   │   │   └── Ex19_08/
│   │   │       └── Ex19_08.cpp
│   │   ├── Chapter 20/
│   │   │   ├── Ex20_01/
│   │   │   │   └── Ex20_01.cpp
│   │   │   ├── Ex20_02/
│   │   │   │   └── Ex20_02.cpp
│   │   │   ├── Ex20_03/
│   │   │   │   └── Ex20_03.cpp
│   │   │   ├── Ex20_04/
│   │   │   │   └── Ex20_04.cpp
│   │   │   ├── Ex20_05/
│   │   │   │   └── Ex20_05.cpp
│   │   │   ├── Ex20_06/
│   │   │   │   └── Ex20_06.cpp
│   │   │   ├── Ex20_07/
│   │   │   │   └── Ex20_07.cpp
│   │   │   ├── Ex20_08/
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex20_08.cpp
│   │   │   ├── Ex20_09/
│   │   │   │   └── Ex20_09.cpp
│   │   │   ├── Ex20_10/
│   │   │   │   └── Ex20_10.cpp
│   │   │   ├── Ex20_11/
│   │   │   │   └── Ex20_11.cpp
│   │   │   ├── Ex20_11A/
│   │   │   │   └── Ex20_11A.cpp
│   │   │   ├── Ex20_12/
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex20_12.cpp
│   │   │   ├── Ex20_12A/
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex20_12A.cpp
│   │   │   ├── Ex20_13/
│   │   │   │   └── Ex20_13.cpp
│   │   │   ├── Ex20_13A/
│   │   │   │   └── Ex20_13A.cpp
│   │   │   ├── Ex20_13B/
│   │   │   │   └── Ex20_13B.cpp
│   │   │   ├── Ex20_14/
│   │   │   │   └── Ex20_14.cpp
│   │   │   ├── Ex20_14A/
│   │   │   │   └── Ex20_14A.cpp
│   │   │   ├── Ex20_14B/
│   │   │   │   └── Ex20_14B.cpp
│   │   │   ├── Ex20_15/
│   │   │   │   └── Ex20_15.cpp
│   │   │   ├── Ex20_15A/
│   │   │   │   └── Ex20_15A.cpp
│   │   │   ├── Ex20_16/
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Ex20_16.cpp
│   │   │   ├── Ex20_17/
│   │   │   │   └── Ex20_17.cpp
│   │   │   └── Ex20_18/
│   │   │       └── Ex20_18.cpp
│   │   └── Chapter 21/
│   │       ├── Ex21_01/
│   │       │   └── Ex21_01.cpp
│   │       ├── Ex21_02/
│   │       │   └── Ex21_02.cpp
│   │       ├── Ex21_03/
│   │       │   ├── Array.cppm
│   │       │   └── Ex21_03.cpp
│   │       └── Ex21_04/
│   │           └── Ex21_04.cpp
│   ├── NoModules/
│   │   ├── Appendix A/
│   │   │   ├── ExA_01/
│   │   │   │   └── ExA_01.cpp
│   │   │   ├── ExA_02/
│   │   │   │   └── ExA_02.cpp
│   │   │   ├── ExA_02A/
│   │   │   │   └── ExA_02A.cpp
│   │   │   ├── ExA_03/
│   │   │   │   └── ExA_03.cpp
│   │   │   ├── ExA_04/
│   │   │   │   └── ExA_04.cpp
│   │   │   ├── ExA_05/
│   │   │   │   ├── ExA_05.cpp
│   │   │   │   └── inclusivity.quote
│   │   │   ├── ExA_06/
│   │   │   │   └── ExA_06.cpp
│   │   │   ├── ExA_07/
│   │   │   │   ├── ExA_07.cpp
│   │   │   │   └── Power.cpp
│   │   │   ├── ExA_07A/
│   │   │   │   ├── ExA_07A.cpp
│   │   │   │   ├── Power.cpp
│   │   │   │   └── Power.h
│   │   │   ├── ExA_08/
│   │   │   │   ├── ExA_08.cpp
│   │   │   │   ├── Power.cpp
│   │   │   │   └── Range.cpp
│   │   │   ├── ExA_08A/
│   │   │   │   ├── ExA_08A.cpp
│   │   │   │   ├── Power.cpp
│   │   │   │   └── Range.cpp
│   │   │   ├── ExA_09/
│   │   │   │   ├── ExA_09.cpp
│   │   │   │   └── Power.cpp
│   │   │   ├── ExA_09A/
│   │   │   │   ├── ExA_09A.cpp
│   │   │   │   └── Power.cpp
│   │   │   ├── ExA_10/
│   │   │   │   ├── BadMath.h
│   │   │   │   └── ExA_10.cpp
│   │   │   ├── ExA_10A/
│   │   │   │   ├── BetterMath.h
│   │   │   │   └── ExA_10A.cpp
│   │   │   ├── ExA_11/
│   │   │   │   ├── BetterMath.h
│   │   │   │   ├── ExA_11.cpp
│   │   │   │   ├── Hypot.cpp
│   │   │   │   ├── Hypot.h
│   │   │   │   ├── Pow4.cpp
│   │   │   │   └── Pow4.h
│   │   │   ├── ExA_12/
│   │   │   │   ├── ExA_12.cpp
│   │   │   │   ├── Hypot.cpp
│   │   │   │   ├── Hypot.h
│   │   │   │   ├── Pow4.cpp
│   │   │   │   ├── Pow4.h
│   │   │   │   └── ProperMath.h
│   │   │   ├── ExA_13/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.h
│   │   │   │   └── ExA_13.cpp
│   │   │   └── ExA_13A/
│   │   │       ├── Box.h
│   │   │       └── ExA_13A.cpp
│   │   ├── Chapter 01/
│   │   │   ├── Ex1_01.cpp
│   │   │   └── Ex1_02.cpp
│   │   ├── Chapter 02/
│   │   │   ├── Ex2_01.cpp
│   │   │   ├── Ex2_02.cpp
│   │   │   ├── Ex2_03.cpp
│   │   │   ├── Ex2_03A.cpp
│   │   │   ├── Ex2_03B.cpp
│   │   │   ├── Ex2_03C.cpp
│   │   │   ├── Ex2_03D.cpp
│   │   │   ├── Ex2_04.cpp
│   │   │   ├── Ex2_05.cpp
│   │   │   ├── Ex2_06.cpp
│   │   │   ├── Ex2_06B.cpp
│   │   │   └── Ex2_07.cpp
│   │   ├── Chapter 03/
│   │   │   ├── Ex3_01.cpp
│   │   │   ├── Ex3_02.cpp
│   │   │   └── Ex3_03.cpp
│   │   ├── Chapter 04/
│   │   │   ├── Ex4_01.cpp
│   │   │   ├── Ex4_01A.cpp
│   │   │   ├── Ex4_02.cpp
│   │   │   ├── Ex4_02A.cpp
│   │   │   ├── Ex4_03.cpp
│   │   │   ├── Ex4_04.cpp
│   │   │   ├── Ex4_04A.cpp
│   │   │   ├── Ex4_05.cpp
│   │   │   ├── Ex4_06.cpp
│   │   │   ├── Ex4_07.cpp
│   │   │   ├── Ex4_08.cpp
│   │   │   ├── Ex4_09.cpp
│   │   │   └── Ex4_09A.cpp
│   │   ├── Chapter 05/
│   │   │   ├── Ex5_01.cpp
│   │   │   ├── Ex5_02.cpp
│   │   │   ├── Ex5_03.cpp
│   │   │   ├── Ex5_03A.cpp
│   │   │   ├── Ex5_04.cpp
│   │   │   ├── Ex5_04A.cpp
│   │   │   ├── Ex5_05.cpp
│   │   │   ├── Ex5_06.cpp
│   │   │   ├── Ex5_07.cpp
│   │   │   ├── Ex5_07A.cpp
│   │   │   ├── Ex5_08.cpp
│   │   │   ├── Ex5_09.cpp
│   │   │   ├── Ex5_10.cpp
│   │   │   ├── Ex5_11.cpp
│   │   │   ├── Ex5_12.cpp
│   │   │   ├── Ex5_12A.cpp
│   │   │   ├── Ex5_13.cpp
│   │   │   ├── Ex5_14.cpp
│   │   │   └── Ex5_15.cpp
│   │   ├── Chapter 06/
│   │   │   ├── Ex6_01.cpp
│   │   │   ├── Ex6_02.cpp
│   │   │   ├── Ex6_03.cpp
│   │   │   ├── Ex6_04.cpp
│   │   │   ├── Ex6_05.cpp
│   │   │   ├── Ex6_06.cpp
│   │   │   └── Ex6_07.cpp
│   │   ├── Chapter 07/
│   │   │   ├── Ex7_01.cpp
│   │   │   ├── Ex7_01A.cpp
│   │   │   ├── Ex7_02.cpp
│   │   │   ├── Ex7_02A.cpp
│   │   │   ├── Ex7_03.cpp
│   │   │   ├── Ex7_04.cpp
│   │   │   ├── Ex7_05.cpp
│   │   │   ├── Ex7_06.cpp
│   │   │   └── Ex7_07.cpp
│   │   ├── Chapter 08/
│   │   │   ├── Ex8_01.cpp
│   │   │   ├── Ex8_02.cpp
│   │   │   ├── Ex8_03.cpp
│   │   │   ├── Ex8_04.cpp
│   │   │   ├── Ex8_05.cpp
│   │   │   ├── Ex8_05A.cpp
│   │   │   ├── Ex8_06.cpp
│   │   │   ├── Ex8_06A.cpp
│   │   │   ├── Ex8_07.cpp
│   │   │   ├── Ex8_08.cpp
│   │   │   ├── Ex8_09A.cpp
│   │   │   ├── Ex8_09B.cpp
│   │   │   ├── Ex8_09C.cpp
│   │   │   ├── Ex8_10.cpp
│   │   │   ├── Ex8_11.cpp
│   │   │   ├── Ex8_12.cpp
│   │   │   ├── Ex8_13.cpp
│   │   │   ├── Ex8_14.cpp
│   │   │   ├── Ex8_15.cpp
│   │   │   ├── Ex8_16.cpp
│   │   │   └── Ex8_17.cpp
│   │   ├── Chapter 09/
│   │   │   ├── Ex9_01.cpp
│   │   │   ├── Ex9_02.cpp
│   │   │   ├── Ex9_03.cpp
│   │   │   └── Ex9_03A.cpp
│   │   ├── Chapter 10/
│   │   │   ├── Ex10_01.cpp
│   │   │   ├── Ex10_02.cpp
│   │   │   ├── Ex10_03.cpp
│   │   │   ├── Ex10_03A.cpp
│   │   │   └── Ex10_04.cpp
│   │   ├── Chapter 11/
│   │   │   ├── Ex11_06/
│   │   │   │   └── Ex11_06.cpp
│   │   │   ├── Ex11_07/
│   │   │   │   ├── Ex11_07.cpp
│   │   │   │   ├── math.cpp
│   │   │   │   └── math.h
│   │   │   └── Ex11_08/
│   │   │       ├── Ex11_08.cpp
│   │   │       └── squaring.h
│   │   ├── Chapter 12/
│   │   │   ├── Ex12_01/
│   │   │   │   └── Ex12_01.cpp
│   │   │   ├── Ex12_01A/
│   │   │   │   └── Ex12_01A.cpp
│   │   │   ├── Ex12_02/
│   │   │   │   └── Ex12_02.cpp
│   │   │   ├── Ex12_03/
│   │   │   │   └── Ex12_03.cpp
│   │   │   ├── Ex12_04/
│   │   │   │   └── Ex12_04.cpp
│   │   │   ├── Ex12_05/
│   │   │   │   └── Ex12_05.cpp
│   │   │   ├── Ex12_05A/
│   │   │   │   └── Ex12_05A.cpp
│   │   │   ├── Ex12_06/
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex12_06.cpp
│   │   │   ├── Ex12_06A/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex12_06A.cpp
│   │   │   ├── Ex12_06B/
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex12_06B.cpp
│   │   │   ├── Ex12_07/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex12_07.cpp
│   │   │   ├── Ex12_08/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex12_08.cpp
│   │   │   ├── Ex12_09/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex12_09.cpp
│   │   │   ├── Ex12_10/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex12_10.cpp
│   │   │   ├── Ex12_11/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex12_11.cpp
│   │   │   ├── Ex12_12/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex12_12.cpp
│   │   │   ├── Ex12_13/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex12_13.cpp
│   │   │   ├── Ex12_14/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex12_14.cpp
│   │   │   ├── Ex12_15/
│   │   │   │   ├── CylindricalBox.cpp
│   │   │   │   ├── CylindricalBox.h
│   │   │   │   └── Ex12_15.cpp
│   │   │   ├── Ex12_16/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex12_16.cpp
│   │   │   ├── Ex12_17/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Ex12_17.cpp
│   │   │   │   ├── Package.h
│   │   │   │   ├── RandomBoxes.h
│   │   │   │   ├── SharedBox.h
│   │   │   │   ├── Truckload.cpp
│   │   │   │   └── Truckload.h
│   │   │   └── Ex12_18/
│   │   │       ├── Box.h
│   │   │       ├── Ex12_18.cpp
│   │   │       ├── RandomBoxes.h
│   │   │       ├── Truckload.cpp
│   │   │       └── Truckload.h
│   │   ├── Chapter 13/
│   │   │   ├── Ex13_01/
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex13_01.cpp
│   │   │   ├── Ex13_02/
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex13_02.cpp
│   │   │   ├── Ex13_03/
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex13_03.cpp
│   │   │   ├── Ex13_03A/
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex13_03A.cpp
│   │   │   ├── Ex13_04/
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex13_04.cpp
│   │   │   ├── Ex13_05/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex13_05.cpp
│   │   │   ├── Ex13_06/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex13_06.cpp
│   │   │   ├── Ex13_07/
│   │   │   │   ├── Ex13_07.cpp
│   │   │   │   └── Integer.h
│   │   │   ├── Ex13_08/
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex13_08.cpp
│   │   │   ├── Ex13_09/
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex13_09.cpp
│   │   │   ├── Ex13_10/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Ex13_10.cpp
│   │   │   │   ├── Truckload.cpp
│   │   │   │   └── Truckload.h
│   │   │   ├── Ex13_11/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Ex13_11.cpp
│   │   │   │   ├── Truckload.cpp
│   │   │   │   └── Truckload.h
│   │   │   ├── Ex13_12/
│   │   │   │   ├── Ex13_12.cpp
│   │   │   │   ├── Message.cpp
│   │   │   │   └── Message.h
│   │   │   ├── Ex13_12A/
│   │   │   │   ├── Ex13_12A.cpp
│   │   │   │   ├── Message.cpp
│   │   │   │   └── Message.h
│   │   │   └── Ex13_12B/
│   │   │       ├── Ex13_12B.cpp
│   │   │       ├── Message.cpp
│   │   │       └── Message.h
│   │   ├── Chapter 14/
│   │   │   ├── Ex14_01/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Carton.h
│   │   │   │   └── Ex14_01.cpp
│   │   │   ├── Ex14_01A/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Carton.h
│   │   │   │   └── Ex14_01A.cpp
│   │   │   ├── Ex14_02/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Carton.h
│   │   │   │   └── Ex14_02.cpp
│   │   │   ├── Ex14_03/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Carton.h
│   │   │   │   └── Ex14_03.cpp
│   │   │   ├── Ex14_04/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Carton.h
│   │   │   │   └── Ex14_04.cpp
│   │   │   ├── Ex14_04A/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Carton.h
│   │   │   │   └── Ex14_04A.cpp
│   │   │   ├── Ex14_04B/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Carton.h
│   │   │   │   └── Ex14_04B.cpp
│   │   │   ├── Ex14_04C/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Carton.h
│   │   │   │   └── Ex14_04C.cpp
│   │   │   ├── Ex14_05/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Carton.h
│   │   │   │   └── Ex14_05.cpp
│   │   │   ├── Ex14_06/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Carton.h
│   │   │   │   └── Ex14_06.cpp
│   │   │   ├── Ex14_07/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Carton.h
│   │   │   │   ├── CerealPack.h
│   │   │   │   ├── Ex14_07.cpp
│   │   │   │   └── FoodContainer.h
│   │   │   ├── Ex14_07A/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Carton.h
│   │   │   │   ├── CerealPack.h
│   │   │   │   ├── Ex14_07A.cpp
│   │   │   │   └── FoodContainer.h
│   │   │   └── Ex14_07B/
│   │   │       ├── Box.h
│   │   │       ├── Carton.h
│   │   │       ├── CerealPack.h
│   │   │       ├── Ex14_07B.cpp
│   │   │       └── FoodContainer.h
│   │   ├── Chapter 15/
│   │   │   ├── Ex15_01/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Ex15_01.cpp
│   │   │   │   └── ToughPack.h
│   │   │   ├── Ex15_02/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Carton.h
│   │   │   │   ├── Ex15_02.cpp
│   │   │   │   └── ToughPack.h
│   │   │   ├── Ex15_03/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Carton.h
│   │   │   │   ├── Ex15_03.cpp
│   │   │   │   └── ToughPack.h
│   │   │   ├── Ex15_04/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Carton.h
│   │   │   │   ├── Ex15_04.cpp
│   │   │   │   └── ToughPack.h
│   │   │   ├── Ex15_05/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Carton.h
│   │   │   │   ├── Ex15_05.cpp
│   │   │   │   └── ToughPack.h
│   │   │   ├── Ex15_06/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Carton.h
│   │   │   │   ├── Ex15_06.cpp
│   │   │   │   └── ToughPack.h
│   │   │   ├── Ex15_07/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Carton.h
│   │   │   │   ├── Ex15_07.cpp
│   │   │   │   └── ToughPack.h
│   │   │   ├── Ex15_07A/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Carton.h
│   │   │   │   ├── Ex15_07A.cpp
│   │   │   │   └── ToughPack.h
│   │   │   ├── Ex15_08/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Ex14_08.cpp
│   │   │   │   └── ToughPack.h
│   │   │   ├── Ex15_09/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Carton.h
│   │   │   │   └── Ex15_09.cpp
│   │   │   ├── Ex15_10/
│   │   │   │   ├── Box.h
│   │   │   │   ├── Carton.h
│   │   │   │   ├── Ex15_10.cpp
│   │   │   │   └── ToughPack.h
│   │   │   └── Ex15_11/
│   │   │       ├── Box.h
│   │   │       ├── Can.h
│   │   │       ├── Carton.h
│   │   │       ├── Ex15_11.cpp
│   │   │       ├── ToughPack.h
│   │   │       └── Vessel.h
│   │   ├── Chapter 16/
│   │   │   ├── Ex16_01/
│   │   │   │   └── Ex16_01.cpp
│   │   │   ├── Ex16_02/
│   │   │   │   ├── Ex16_02.cpp
│   │   │   │   └── Troubles.h
│   │   │   ├── Ex16_03/
│   │   │   │   ├── Ex16_03.cpp
│   │   │   │   └── Troubles.h
│   │   │   ├── Ex16_04/
│   │   │   │   ├── Ex16_04.cpp
│   │   │   │   └── Troubles.h
│   │   │   ├── Ex16_05/
│   │   │   │   ├── Ex16_05.cpp
│   │   │   │   └── Troubles.h
│   │   │   ├── Ex16_06/
│   │   │   │   ├── Ex16_06.cpp
│   │   │   │   └── Troubles.h
│   │   │   ├── Ex16_07/
│   │   │   │   ├── Ex16_07.cpp
│   │   │   │   └── Troubles.h
│   │   │   ├── Ex16_07A/
│   │   │   │   ├── Ex16_07A.cpp
│   │   │   │   └── Troubles.h
│   │   │   ├── Ex16_07B/
│   │   │   │   ├── DoubleArrayRAII.h
│   │   │   │   ├── Ex16_07B.cpp
│   │   │   │   └── Troubles.h
│   │   │   ├── Ex16_07C/
│   │   │   │   ├── Ex16_07C.cpp
│   │   │   │   └── Troubles.h
│   │   │   ├── Ex16_07D/
│   │   │   │   ├── Ex16_07D.cpp
│   │   │   │   └── Troubles.h
│   │   │   └── Ex16_09/
│   │   │       ├── Box.h
│   │   │       ├── DimensionError.h
│   │   │       └── Ex16_09.cpp
│   │   ├── Chapter 17/
│   │   │   ├── Ex17_01/
│   │   │   │   ├── Array.h
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex17_01.cpp
│   │   │   ├── Ex17_01A/
│   │   │   │   ├── Array.h
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex17_01A.cpp
│   │   │   ├── Ex17_02/
│   │   │   │   ├── Array.h
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex17_02.cpp
│   │   │   ├── Ex17_02A/
│   │   │   │   ├── Array.h
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex17_02A.cpp
│   │   │   ├── Ex17_03/
│   │   │   │   ├── Array.h
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex17_03.cpp
│   │   │   ├── Ex17_04/
│   │   │   │   ├── Ex17_04.cpp
│   │   │   │   └── Stack.h
│   │   │   ├── Ex17_04A/
│   │   │   │   ├── Ex17_04A.cpp
│   │   │   │   └── Stack.h
│   │   │   ├── Ex17_04B/
│   │   │   │   ├── Ex17_04B.cpp
│   │   │   │   └── Stack.h
│   │   │   ├── Ex17_05/
│   │   │   │   ├── Ex17_05A.cpp
│   │   │   │   ├── Ex17_05B.cpp
│   │   │   │   └── Ex17_05C.cpp
│   │   │   └── Ex17_06/
│   │   │       └── Ex17_06.cpp
│   │   ├── Chapter 18/
│   │   │   ├── Ex18_01/
│   │   │   │   ├── Array.h
│   │   │   │   └── Ex18_01.cpp
│   │   │   ├── Ex18_02/
│   │   │   │   ├── Array.h
│   │   │   │   └── Ex18_02.cpp
│   │   │   ├── Ex18_03/
│   │   │   │   ├── Array.h
│   │   │   │   └── Ex18_03.cpp
│   │   │   ├── Ex18_04/
│   │   │   │   ├── Array.h
│   │   │   │   └── Ex18_04.cpp
│   │   │   ├── Ex18_05A/
│   │   │   │   ├── Array.h
│   │   │   │   └── Ex18_05A.cpp
│   │   │   ├── Ex18_05B/
│   │   │   │   ├── Array.h
│   │   │   │   └── Ex18_05B.cpp
│   │   │   ├── Ex18_06/
│   │   │   │   ├── Array.h
│   │   │   │   └── Ex18_06.cpp
│   │   │   └── Ex18_07/
│   │   │       ├── Array.h
│   │   │       └── Ex18_07.cpp
│   │   ├── Chapter 19/
│   │   │   ├── Ex19_01/
│   │   │   │   └── Ex19_01.cpp
│   │   │   ├── Ex19_02/
│   │   │   │   ├── Ex19_02.cpp
│   │   │   │   └── Optimum.h
│   │   │   ├── Ex19_03/
│   │   │   │   ├── Ex19_03.cpp
│   │   │   │   ├── Less.h
│   │   │   │   └── Optimum.h
│   │   │   ├── Ex19_03A/
│   │   │   │   ├── Ex19_03A.cpp
│   │   │   │   └── Optimum.h
│   │   │   ├── Ex19_04/
│   │   │   │   ├── Ex19_04.cpp
│   │   │   │   ├── Nearer.h
│   │   │   │   └── Optimum.h
│   │   │   ├── Ex19_05/
│   │   │   │   ├── Ex19_05.cpp
│   │   │   │   └── Optimum.h
│   │   │   ├── Ex19_05A/
│   │   │   │   ├── Ex19_05A.cpp
│   │   │   │   └── Optimum.h
│   │   │   ├── Ex19_06/
│   │   │   │   ├── Ex19_06.cpp
│   │   │   │   └── Optimum.h
│   │   │   ├── Ex19_07/
│   │   │   │   ├── Ex19_07.cpp
│   │   │   │   ├── Finder.cpp
│   │   │   │   ├── Finder.h
│   │   │   │   └── Optimum.h
│   │   │   └── Ex19_08/
│   │   │       └── Ex19_08.cpp
│   │   ├── Chapter 20/
│   │   │   ├── Ex20_01/
│   │   │   │   └── Ex20_01.cpp
│   │   │   ├── Ex20_02/
│   │   │   │   └── Ex20_02.cpp
│   │   │   ├── Ex20_03/
│   │   │   │   └── Ex20_03.cpp
│   │   │   ├── Ex20_04/
│   │   │   │   └── Ex20_04.cpp
│   │   │   ├── Ex20_05/
│   │   │   │   └── Ex20_05.cpp
│   │   │   ├── Ex20_06/
│   │   │   │   └── Ex20_06.cpp
│   │   │   ├── Ex20_07/
│   │   │   │   └── Ex20_07.cpp
│   │   │   ├── Ex20_08/
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex20_08.cpp
│   │   │   ├── Ex20_09/
│   │   │   │   └── Ex20_09.cpp
│   │   │   ├── Ex20_10/
│   │   │   │   └── Ex20_10.cpp
│   │   │   ├── Ex20_11/
│   │   │   │   └── Ex20_11.cpp
│   │   │   ├── Ex20_11A/
│   │   │   │   └── Ex20_11A.cpp
│   │   │   ├── Ex20_12/
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex20_12.cpp
│   │   │   ├── Ex20_12A/
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex20_12A.cpp
│   │   │   ├── Ex20_13/
│   │   │   │   └── Ex20_13.cpp
│   │   │   ├── Ex20_13A/
│   │   │   │   └── Ex20_13A.cpp
│   │   │   ├── Ex20_13B/
│   │   │   │   └── Ex20_13B.cpp
│   │   │   ├── Ex20_14/
│   │   │   │   └── Ex20_14.cpp
│   │   │   ├── Ex20_14A/
│   │   │   │   └── Ex20_14A.cpp
│   │   │   ├── Ex20_14B/
│   │   │   │   └── Ex20_14B.cpp
│   │   │   ├── Ex20_15/
│   │   │   │   └── Ex20_15.cpp
│   │   │   ├── Ex20_15A/
│   │   │   │   └── Ex20_15A.cpp
│   │   │   ├── Ex20_16/
│   │   │   │   ├── Box.h
│   │   │   │   └── Ex20_16.cpp
│   │   │   ├── Ex20_17/
│   │   │   │   └── Ex20_17.cpp
│   │   │   └── Ex20_18/
│   │   │       └── Ex20_18.cpp
│   │   └── Chapter 21/
│   │       ├── Ex21_01/
│   │       │   └── Ex21_01.cpp
│   │       ├── Ex21_02/
│   │       │   └── Ex21_02.cpp
│   │       ├── Ex21_03/
│   │       │   ├── Array.h
│   │       │   └── Ex21_03.cpp
│   │       └── Ex21_04/
│   │           └── Ex21_04.cpp
│   └── README.md
├── Exercises/
│   ├── Modules/
│   │   ├── Chapter 01/
│   │   │   ├── Exer1_03.cpp
│   │   │   ├── Soln1_01.cpp
│   │   │   └── Soln1_02.cpp
│   │   ├── Chapter 02/
│   │   │   ├── Soln2_01A.cpp
│   │   │   ├── Soln2_01B.cpp
│   │   │   ├── Soln2_02A.cpp
│   │   │   ├── Soln2_02B.cpp
│   │   │   ├── Soln2_03.cpp
│   │   │   ├── Soln2_04.cpp
│   │   │   ├── Soln2_05.cpp
│   │   │   ├── Soln2_06.cpp
│   │   │   ├── Soln2_07.cpp
│   │   │   └── Soln2_08.cpp
│   │   ├── Chapter 03/
│   │   │   ├── Soln3_01.cpp
│   │   │   ├── Soln3_02.cpp
│   │   │   ├── Soln3_03.cpp
│   │   │   ├── Soln3_04.cpp
│   │   │   ├── Soln3_05.cpp
│   │   │   └── Soln3_06.cpp
│   │   ├── Chapter 04/
│   │   │   ├── Soln4_01.cpp
│   │   │   ├── Soln4_02.cpp
│   │   │   ├── Soln4_03.cpp
│   │   │   ├── Soln4_04.cpp
│   │   │   ├── Soln4_05.cpp
│   │   │   ├── Soln4_06.cpp
│   │   │   ├── Soln4_07.cpp
│   │   │   └── Soln4_08.cpp
│   │   ├── Chapter 05/
│   │   │   ├── Soln5_01.cpp
│   │   │   ├── Soln5_02.cpp
│   │   │   ├── Soln5_03.cpp
│   │   │   ├── Soln5_04.cpp
│   │   │   ├── Soln5_05.cpp
│   │   │   ├── Soln5_06.cpp
│   │   │   ├── Soln5_07.cpp
│   │   │   └── Soln5_08.cpp
│   │   ├── Chapter 06/
│   │   │   ├── Soln6_01.cpp
│   │   │   ├── Soln6_02.cpp
│   │   │   ├── Soln6_03.cpp
│   │   │   ├── Soln6_04.cpp
│   │   │   ├── Soln6_05.cpp
│   │   │   └── Soln6_06.cpp
│   │   ├── Chapter 08/
│   │   │   ├── Soln8_01.cpp
│   │   │   ├── Soln8_02.cpp
│   │   │   ├── Soln8_03.cpp
│   │   │   ├── Soln8_04.cpp
│   │   │   ├── Soln8_05.cpp
│   │   │   ├── Soln8_06.cpp
│   │   │   ├── Soln8_07.cpp
│   │   │   ├── Soln8_07A.cpp
│   │   │   ├── Soln8_08.cpp
│   │   │   └── Soln8_09.cpp
│   │   ├── Chapter 09/
│   │   │   ├── Soln9_01.cpp
│   │   │   ├── Soln9_02.cpp
│   │   │   ├── Soln9_03.cpp
│   │   │   ├── Soln9_04.cpp
│   │   │   ├── Soln9_05.cpp
│   │   │   └── Soln9_06.cpp
│   │   ├── Chapter 10/
│   │   │   ├── Soln10_01.cpp
│   │   │   ├── Soln10_02.cpp
│   │   │   ├── Soln10_03.cpp
│   │   │   ├── Soln10_04.cpp
│   │   │   ├── Soln10_05.cpp
│   │   │   └── Soln10_06.cpp
│   │   ├── Chapter 11/
│   │   │   ├── Soln11_01/
│   │   │   │   ├── Soln11_01.cpp
│   │   │   │   └── words.cppm
│   │   │   ├── Soln11_02/
│   │   │   │   ├── Soln11_02.cpp
│   │   │   │   ├── words.cpp
│   │   │   │   └── words.cppm
│   │   │   ├── Soln11_03/
│   │   │   │   ├── Soln11_03.cpp
│   │   │   │   ├── words.cppm
│   │   │   │   ├── words.sorting.cpp
│   │   │   │   ├── words.sorting.cppm
│   │   │   │   ├── words.utils.cpp
│   │   │   │   └── words.utils.cppm
│   │   │   ├── Soln11_04/
│   │   │   │   ├── Soln11_04.cpp
│   │   │   │   ├── internals.cpp
│   │   │   │   ├── words.cpp
│   │   │   │   └── words.cppm
│   │   │   ├── Soln11_05/
│   │   │   │   ├── Soln11_05.cpp
│   │   │   │   ├── alias.cppm
│   │   │   │   ├── internals.cpp
│   │   │   │   ├── sorting.cppm
│   │   │   │   ├── utils.cppm
│   │   │   │   └── words.cppm
│   │   │   └── Soln11_06/
│   │   │       ├── Soln11_06.cpp
│   │   │       ├── words.cpp
│   │   │       └── words.cppm
│   │   ├── Chapter 12/
│   │   │   ├── Soln12_01/
│   │   │   │   ├── Integer.cpp
│   │   │   │   ├── Integer.cppm
│   │   │   │   └── Soln12_01.cpp
│   │   │   ├── Soln12_02/
│   │   │   │   ├── Integer.cpp
│   │   │   │   ├── Integer.cppm
│   │   │   │   └── Soln12_02.cpp
│   │   │   ├── Soln12_03/
│   │   │   │   ├── Integer.cpp
│   │   │   │   ├── Integer.cppm
│   │   │   │   └── Soln12_03.cpp
│   │   │   ├── Soln12_04/
│   │   │   │   ├── Integer.cpp
│   │   │   │   ├── Integer.cppm
│   │   │   │   └── Soln12_04.cpp
│   │   │   ├── Soln12_05/
│   │   │   │   ├── Integer.cpp
│   │   │   │   ├── Integer.cppm
│   │   │   │   └── Soln12_05.cpp
│   │   │   ├── Soln12_06/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── RandomBoxes.cppm
│   │   │   │   ├── Soln12_06.cpp
│   │   │   │   ├── Truckload.cpp
│   │   │   │   └── Truckload.cppm
│   │   │   ├── Soln12_07/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── RandomBoxes.cppm
│   │   │   │   ├── Soln12_07.cpp
│   │   │   │   ├── Truckload.cpp
│   │   │   │   └── Truckload.cppm
│   │   │   └── Soln12_08/
│   │   │       ├── Box.cppm
│   │   │       ├── RandomBoxes.cppm
│   │   │       ├── Soln12_08.cpp
│   │   │       ├── Truckload.cpp
│   │   │       └── Truckload.cppm
│   │   ├── Chapter 13/
│   │   │   ├── Soln13_01/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Soln13_01.cpp
│   │   │   ├── Soln13_02/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Soln13_02.cpp
│   │   │   ├── Soln13_03/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Soln13_03.cpp
│   │   │   ├── Soln13_04/
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Soln13_04.cpp
│   │   │   ├── Soln13_05/
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Soln13_05.cpp
│   │   │   ├── Soln13_06/
│   │   │   │   ├── Box.cppm
│   │   │   │   └── Soln13_06.cpp
│   │   │   ├── Soln13_07/
│   │   │   │   ├── Rational.cppm
│   │   │   │   └── Soln13_07.cpp
│   │   │   ├── Soln13_08/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── PRNG.cppm
│   │   │   │   └── Soln13_08.cpp
│   │   │   └── Soln13_09/
│   │   │       ├── Box.cppm
│   │   │       ├── Soln13_09.cpp
│   │   │       ├── Truckload.cpp
│   │   │       └── Truckload.cppm
│   │   ├── Chapter 14/
│   │   │   ├── Soln14_01/
│   │   │   │   ├── Animals.cppm
│   │   │   │   └── Soln14_01.cpp
│   │   │   ├── Soln14_02/
│   │   │   │   ├── Animals.cppm
│   │   │   │   └── Soln14_02.cpp
│   │   │   ├── Soln14_03/
│   │   │   │   ├── Animals.cpp
│   │   │   │   ├── Animals.cppm
│   │   │   │   └── Soln14_03.cpp
│   │   │   └── Soln14_04/
│   │   │       ├── Person.cpp
│   │   │       ├── Person.cppm
│   │   │       └── Soln14_04.cpp
│   │   ├── Chapter 15/
│   │   │   ├── Soln15_01/
│   │   │   │   ├── Animals.cpp
│   │   │   │   ├── Animals.cppm
│   │   │   │   ├── Soln15_01.cpp
│   │   │   │   ├── Zoo.cpp
│   │   │   │   └── Zoo.cppm
│   │   │   ├── Soln15_02/
│   │   │   │   ├── Animals.cpp
│   │   │   │   ├── Animals.cppm
│   │   │   │   ├── Soln15_02.cpp
│   │   │   │   ├── Zoo.cpp
│   │   │   │   └── Zoo.cppm
│   │   │   ├── Soln15_03/
│   │   │   │   ├── Animals.cpp
│   │   │   │   ├── Animals.cppm
│   │   │   │   ├── Soln15_03.cpp
│   │   │   │   ├── Zoo.cpp
│   │   │   │   └── Zoo.cppm
│   │   │   ├── Soln15_04/
│   │   │   │   ├── Animals.cpp
│   │   │   │   ├── Animals.cppm
│   │   │   │   ├── Soln15_04.cpp
│   │   │   │   ├── Zoo.cpp
│   │   │   │   └── Zoo.cppm
│   │   │   ├── Soln15_05/
│   │   │   │   ├── Animals.cpp
│   │   │   │   ├── Animals.cppm
│   │   │   │   ├── Soln15_05.cpp
│   │   │   │   ├── Zoo.cpp
│   │   │   │   └── Zoo.cppm
│   │   │   └── Soln15_06/
│   │   │       ├── Point.cppm
│   │   │       ├── Shapes.cppm
│   │   │       └── Soln15_06.cpp
│   │   ├── Chapter 16/
│   │   │   ├── Exer16_06/
│   │   │   │   ├── Customer.cpp
│   │   │   │   ├── Customer.cppm
│   │   │   │   ├── DB.cpp
│   │   │   │   ├── DB.h
│   │   │   │   ├── DBException.cppm
│   │   │   │   └── Exer16_06.cpp
│   │   │   ├── Soln16_01/
│   │   │   │   ├── Curveball.cppm
│   │   │   │   └── Soln16_01.cpp
│   │   │   ├── Soln16_02/
│   │   │   │   ├── Curveball.cppm
│   │   │   │   ├── Soln16_02.cpp
│   │   │   │   └── TooManyExceptions.cppm
│   │   │   ├── Soln16_03/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── RandomBoxes.cppm
│   │   │   │   ├── Soln16_03.cpp
│   │   │   │   ├── Truckload.cpp
│   │   │   │   └── Truckload.cppm
│   │   │   ├── Soln16_04/
│   │   │   │   └── Soln16_04.cpp
│   │   │   ├── Soln16_05/
│   │   │   │   ├── Curveball.cppm
│   │   │   │   ├── DomainExceptions.cppm
│   │   │   │   └── Soln16_05.cpp
│   │   │   └── Soln16_06/
│   │   │       ├── Customer.cpp
│   │   │       ├── Customer.cppm
│   │   │       ├── DB.cpp
│   │   │       ├── DB.h
│   │   │       ├── DBException.cppm
│   │   │       ├── DB_RAII.cppm
│   │   │       └── Soln16_06.cpp
│   │   ├── Chapter 17/
│   │   │   ├── Soln17_01/
│   │   │   │   ├── Array.cppm
│   │   │   │   └── Soln17_01.cpp
│   │   │   ├── Soln17_02/
│   │   │   │   ├── Pair.cppm
│   │   │   │   └── Soln17_02.cpp
│   │   │   ├── Soln17_03/
│   │   │   │   ├── Pair.cppm
│   │   │   │   └── Soln17_03.cpp
│   │   │   ├── Soln17_04/
│   │   │   │   ├── Pair.cppm
│   │   │   │   ├── Soln17_04.cpp
│   │   │   │   └── SparseArray.cppm
│   │   │   ├── Soln17_05/
│   │   │   │   ├── LinkedList.cppm
│   │   │   │   └── Soln17_05.cpp
│   │   │   ├── Soln17_06/
│   │   │   │   ├── LinkedList.cppm
│   │   │   │   ├── Pair.cppm
│   │   │   │   ├── Soln17_06.cpp
│   │   │   │   └── SparseArray.cppm
│   │   │   ├── Soln17_07/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── BoxFormatter.cppm
│   │   │   │   └── Soln17_07.cpp
│   │   │   └── Soln17_07A/
│   │   │       ├── Box.cppm
│   │   │       ├── BoxFormatter.cppm
│   │   │       └── Soln17_07A.cpp
│   │   ├── Chapter 18/
│   │   │   ├── Soln18_01/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── RandomBoxes.cppm
│   │   │   │   ├── Soln18_01.cpp
│   │   │   │   ├── Truckload.cpp
│   │   │   │   └── Truckload.cppm
│   │   │   ├── Soln18_02/
│   │   │   │   ├── LinkedList.cppm
│   │   │   │   └── Soln18_02.cpp
│   │   │   ├── Soln18_03/
│   │   │   │   ├── Customer.cpp
│   │   │   │   ├── Customer.cppm
│   │   │   │   ├── DB.cpp
│   │   │   │   ├── DB.h
│   │   │   │   ├── DBException.cppm
│   │   │   │   ├── DB_RAII.cppm
│   │   │   │   └── Soln18_03.cpp
│   │   │   ├── Soln18_04/
│   │   │   │   ├── Customer.cpp
│   │   │   │   ├── Customer.cppm
│   │   │   │   ├── DB.cpp
│   │   │   │   ├── DB.h
│   │   │   │   ├── DBException.cppm
│   │   │   │   ├── DB_RAII.cppm
│   │   │   │   └── Soln18_04.cpp
│   │   │   └── Soln18_05/
│   │   │       ├── Customer.cpp
│   │   │       ├── Customer.cppm
│   │   │       ├── DB.cpp
│   │   │       ├── DB.h
│   │   │       ├── DBException.cppm
│   │   │       ├── DB_RAII.cppm
│   │   │       └── Soln18_05.cpp
│   │   ├── Chapter 19/
│   │   │   ├── Soln19_01/
│   │   │   │   └── Soln19_01.cpp
│   │   │   ├── Soln19_02/
│   │   │   │   ├── Soln19_02.cpp
│   │   │   │   └── Sort.cppm
│   │   │   ├── Soln19_03/
│   │   │   │   ├── BubbleSort.cppm
│   │   │   │   ├── Quicksort.cppm
│   │   │   │   ├── Soln19_03.cpp
│   │   │   │   └── Sort.cppm
│   │   │   ├── Soln19_04/
│   │   │   │   ├── Collect.cppm
│   │   │   │   └── Soln19_04.cpp
│   │   │   └── Soln19_05/
│   │   │       ├── Box.cppm
│   │   │       ├── DeliveryTruck.cpp
│   │   │       ├── DeliveryTruck.cppm
│   │   │       ├── RandomBoxes.cppm
│   │   │       ├── Soln19_05.cpp
│   │   │       ├── Truckload.cpp
│   │   │       └── Truckload.cppm
│   │   ├── Chapter 20/
│   │   │   ├── Soln20_01/
│   │   │   │   ├── Box.cppm
│   │   │   │   ├── RandomBoxes.cppm
│   │   │   │   ├── Soln20_01.cpp
│   │   │   │   ├── Truckload.cpp
│   │   │   │   └── Truckload.cppm
│   │   │   ├── Soln20_02/
│   │   │   │   └── Soln20_02.cpp
│   │   │   ├── Soln20_03/
│   │   │   │   └── Soln20_03.cpp
│   │   │   ├── Soln20_03A/
│   │   │   │   └── Soln20_03A.cpp
│   │   │   ├── Soln20_04/
│   │   │   │   └── Soln20_04.cpp
│   │   │   ├── Soln20_05/
│   │   │   │   └── Soln20_05.cpp
│   │   │   ├── Soln20_06/
│   │   │   │   └── Soln20_06.cpp
│   │   │   ├── Soln20_07/
│   │   │   │   └── Soln20_07.cpp
│   │   │   ├── Soln20_08/
│   │   │   │   └── Soln20_08.cpp
│   │   │   ├── Soln20_09/
│   │   │   │   └── Soln20_09.cpp
│   │   │   ├── Soln20_10/
│   │   │   │   └── Soln20_10.cpp
│   │   │   ├── Soln20_11/
│   │   │   │   └── Soln20_11.cpp
│   │   │   ├── Soln20_12/
│   │   │   │   └── Soln20_12.cpp
│   │   │   ├── Soln20_13/
│   │   │   │   └── Soln20_13.cpp
│   │   │   └── Soln20_14/
│   │   │       └── Soln20_14.cpp
│   │   └── Chapter 21/
│   │       ├── Soln21_01/
│   │       │   └── Soln21_01.cpp
│   │       ├── Soln21_02/
│   │       │   └── Soln21_02.cpp
│   │       ├── Soln21_03/
│   │       │   └── Soln21_03.cpp
│   │       ├── Soln21_04/
│   │       │   └── Soln21_04.cpp
│   │       ├── Soln21_05/
│   │       │   └── Soln21_05.cpp
│   │       └── Soln21_06/
│   │           ├── Array.cppm
│   │           └── Soln21_06.cpp
│   ├── NoModules/
│   │   ├── Appendix A/
│   │   │   ├── SolnA_01/
│   │   │   │   ├── ASSERT.h
│   │   │   │   └── SolnA_01.cpp
│   │   │   ├── SolnA_02/
│   │   │   │   ├── ASSERT.h
│   │   │   │   └── SolnA_02.cpp
│   │   │   ├── SolnA_03/
│   │   │   │   ├── SmartException.cpp
│   │   │   │   ├── SmartException.h
│   │   │   │   └── SolnA_03.cpp
│   │   │   ├── SolnA_04/
│   │   │   │   ├── SmartException.h
│   │   │   │   └── SolnA_04.cpp
│   │   │   ├── SolnA_05/
│   │   │   │   ├── Print.cpp
│   │   │   │   ├── PrintThat.cpp
│   │   │   │   ├── PrintThat.h
│   │   │   │   ├── PrintThis.cpp
│   │   │   │   ├── PrintThis.h
│   │   │   │   └── SolnA_05.cpp
│   │   │   ├── SolnA_06/
│   │   │   │   ├── Print.h
│   │   │   │   ├── PrintThat.cpp
│   │   │   │   ├── PrintThat.h
│   │   │   │   ├── PrintThis.cpp
│   │   │   │   ├── PrintThis.h
│   │   │   │   └── SolnA_06.cpp
│   │   │   ├── SolnA_07A/
│   │   │   │   ├── Print.cpp
│   │   │   │   ├── PrintThat.cpp
│   │   │   │   ├── PrintThat.h
│   │   │   │   ├── PrintThis.cpp
│   │   │   │   ├── PrintThis.h
│   │   │   │   └── SolnA_07A.cpp
│   │   │   └── SolnA_07B/
│   │   │       ├── Print.h
│   │   │       ├── PrintThat.cpp
│   │   │       ├── PrintThat.h
│   │   │       ├── PrintThis.cpp
│   │   │       ├── PrintThis.h
│   │   │       └── SolnA_07B.cpp
│   │   ├── Chapter 01/
│   │   │   ├── Exer1_03.cpp
│   │   │   ├── Soln1_01.cpp
│   │   │   └── Soln1_02.cpp
│   │   ├── Chapter 02/
│   │   │   ├── Soln2_01A.cpp
│   │   │   ├── Soln2_01B.cpp
│   │   │   ├── Soln2_02A.cpp
│   │   │   ├── Soln2_02B.cpp
│   │   │   ├── Soln2_03.cpp
│   │   │   ├── Soln2_04.cpp
│   │   │   ├── Soln2_05.cpp
│   │   │   ├── Soln2_06.cpp
│   │   │   ├── Soln2_07.cpp
│   │   │   └── Soln2_08.cpp
│   │   ├── Chapter 03/
│   │   │   ├── Soln3_01.cpp
│   │   │   ├── Soln3_02.cpp
│   │   │   ├── Soln3_03.cpp
│   │   │   ├── Soln3_04.cpp
│   │   │   ├── Soln3_05.cpp
│   │   │   └── Soln3_06.cpp
│   │   ├── Chapter 04/
│   │   │   ├── Soln4_01.cpp
│   │   │   ├── Soln4_02.cpp
│   │   │   ├── Soln4_03.cpp
│   │   │   ├── Soln4_04.cpp
│   │   │   ├── Soln4_05.cpp
│   │   │   ├── Soln4_06.cpp
│   │   │   ├── Soln4_07.cpp
│   │   │   └── Soln4_08.cpp
│   │   ├── Chapter 05/
│   │   │   ├── Soln5_01.cpp
│   │   │   ├── Soln5_02.cpp
│   │   │   ├── Soln5_03.cpp
│   │   │   ├── Soln5_04.cpp
│   │   │   ├── Soln5_05.cpp
│   │   │   ├── Soln5_06.cpp
│   │   │   ├── Soln5_07.cpp
│   │   │   └── Soln5_08.cpp
│   │   ├── Chapter 06/
│   │   │   ├── Soln6_01.cpp
│   │   │   ├── Soln6_02.cpp
│   │   │   ├── Soln6_03.cpp
│   │   │   ├── Soln6_04.cpp
│   │   │   ├── Soln6_05.cpp
│   │   │   └── Soln6_06.cpp
│   │   ├── Chapter 07/
│   │   │   ├── Soln7_01.cpp
│   │   │   ├── Soln7_02.cpp
│   │   │   ├── Soln7_03.cpp
│   │   │   ├── Soln7_04.cpp
│   │   │   ├── Soln7_05.cpp
│   │   │   ├── Soln7_06.cpp
│   │   │   ├── Soln7_07.cpp
│   │   │   ├── Soln7_08A.cpp
│   │   │   ├── Soln7_08B.cpp
│   │   │   ├── Soln7_09A.cpp
│   │   │   └── Soln7_09B.cpp
│   │   ├── Chapter 08/
│   │   │   ├── Soln8_01.cpp
│   │   │   ├── Soln8_02.cpp
│   │   │   ├── Soln8_03.cpp
│   │   │   ├── Soln8_04.cpp
│   │   │   ├── Soln8_05.cpp
│   │   │   ├── Soln8_06.cpp
│   │   │   ├── Soln8_07.cpp
│   │   │   ├── Soln8_07A.cpp
│   │   │   ├── Soln8_08.cpp
│   │   │   └── Soln8_09.cpp
│   │   ├── Chapter 09/
│   │   │   ├── Soln9_01.cpp
│   │   │   ├── Soln9_02.cpp
│   │   │   ├── Soln9_03.cpp
│   │   │   ├── Soln9_04.cpp
│   │   │   ├── Soln9_05.cpp
│   │   │   └── Soln9_06.cpp
│   │   ├── Chapter 10/
│   │   │   ├── Soln10_01.cpp
│   │   │   ├── Soln10_02.cpp
│   │   │   ├── Soln10_03.cpp
│   │   │   ├── Soln10_04.cpp
│   │   │   ├── Soln10_05.cpp
│   │   │   └── Soln10_06.cpp
│   │   ├── Chapter 12/
│   │   │   ├── Soln12_01/
│   │   │   │   ├── Integer.cpp
│   │   │   │   ├── Integer.h
│   │   │   │   └── Soln12_01.cpp
│   │   │   ├── Soln12_02/
│   │   │   │   ├── Integer.cpp
│   │   │   │   ├── Integer.h
│   │   │   │   └── Soln12_02.cpp
│   │   │   ├── Soln12_03/
│   │   │   │   ├── Integer.cpp
│   │   │   │   ├── Integer.h
│   │   │   │   └── Soln12_03.cpp
│   │   │   ├── Soln12_04/
│   │   │   │   ├── Integer.cpp
│   │   │   │   ├── Integer.h
│   │   │   │   └── Soln12_04.cpp
│   │   │   ├── Soln12_05/
│   │   │   │   ├── Integer.cpp
│   │   │   │   ├── Integer.h
│   │   │   │   └── Soln12_05.cpp
│   │   │   ├── Soln12_06/
│   │   │   │   ├── Box.h
│   │   │   │   ├── RandomBoxes.h
│   │   │   │   ├── Soln12_06.cpp
│   │   │   │   ├── Truckload.cpp
│   │   │   │   └── Truckload.h
│   │   │   ├── Soln12_07/
│   │   │   │   ├── Box.h
│   │   │   │   ├── RandomBoxes.h
│   │   │   │   ├── Soln12_07.cpp
│   │   │   │   ├── Truckload.cpp
│   │   │   │   └── Truckload.h
│   │   │   └── Soln12_08/
│   │   │       ├── Box.h
│   │   │       ├── RandomBoxes.h
│   │   │       ├── Soln12_08.cpp
│   │   │       ├── Truckload.cpp
│   │   │       └── Truckload.h
│   │   ├── Chapter 13/
│   │   │   ├── Soln13_01/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.h
│   │   │   │   └── Soln13_01.cpp
│   │   │   ├── Soln13_02/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.h
│   │   │   │   └── Soln13_02.cpp
│   │   │   ├── Soln13_03/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.h
│   │   │   │   └── Soln13_03.cpp
│   │   │   ├── Soln13_04/
│   │   │   │   ├── Box.h
│   │   │   │   └── Soln13_04.cpp
│   │   │   ├── Soln13_05/
│   │   │   │   ├── Box.h
│   │   │   │   └── Soln13_05.cpp
│   │   │   ├── Soln13_06/
│   │   │   │   ├── Box.h
│   │   │   │   └── Soln13_06.cpp
│   │   │   ├── Soln13_07/
│   │   │   │   ├── Rational.h
│   │   │   │   └── Soln13_07.cpp
│   │   │   ├── Soln13_08/
│   │   │   │   ├── Box.cpp
│   │   │   │   ├── Box.h
│   │   │   │   ├── PRNG.h
│   │   │   │   └── Soln13_08.cpp
│   │   │   └── Soln13_09/
│   │   │       ├── Box.h
│   │   │       ├── Soln13_09.cpp
│   │   │       ├── Truckload.cpp
│   │   │       └── Truckload.h
│   │   ├── Chapter 14/
│   │   │   ├── Soln14_01/
│   │   │   │   ├── Animals.cpp
│   │   │   │   ├── Animals.h
│   │   │   │   └── Soln14_01.cpp
│   │   │   ├── Soln14_02/
│   │   │   │   ├── Animals.cpp
│   │   │   │   ├── Animals.h
│   │   │   │   └── Soln14_02.cpp
│   │   │   ├── Soln14_03/
│   │   │   │   ├── Animals.cpp
│   │   │   │   ├── Animals.h
│   │   │   │   └── Soln14_03.cpp
│   │   │   └── Soln14_04/
│   │   │       ├── Person.cpp
│   │   │       ├── Person.h
│   │   │       └── Soln14_04.cpp
│   │   ├── Chapter 15/
│   │   │   ├── Soln15_01/
│   │   │   │   ├── Animals.cpp
│   │   │   │   ├── Animals.h
│   │   │   │   ├── Soln15_01.cpp
│   │   │   │   ├── Zoo.cpp
│   │   │   │   └── Zoo.h
│   │   │   ├── Soln15_02/
│   │   │   │   ├── Animals.cpp
│   │   │   │   ├── Animals.h
│   │   │   │   ├── Soln15_02.cpp
│   │   │   │   ├── Zoo.cpp
│   │   │   │   └── Zoo.h
│   │   │   ├── Soln15_03/
│   │   │   │   ├── Animals.cpp
│   │   │   │   ├── Animals.h
│   │   │   │   ├── Soln15_03.cpp
│   │   │   │   ├── Zoo.cpp
│   │   │   │   └── Zoo.h
│   │   │   ├── Soln15_04/
│   │   │   │   ├── Animals.cpp
│   │   │   │   ├── Animals.h
│   │   │   │   ├── Soln15_04.cpp
│   │   │   │   ├── Zoo.cpp
│   │   │   │   └── Zoo.h
│   │   │   ├── Soln15_05/
│   │   │   │   ├── Animals.cpp
│   │   │   │   ├── Animals.h
│   │   │   │   ├── Soln15_05.cpp
│   │   │   │   ├── Zoo.cpp
│   │   │   │   └── Zoo.h
│   │   │   └── Soln15_06/
│   │   │       ├── Point.h
│   │   │       ├── Shapes.h
│   │   │       └── Soln15_06.cpp
│   │   ├── Chapter 16/
│   │   │   ├── Exer16_06/
│   │   │   │   ├── Customer.cpp
│   │   │   │   ├── Customer.h
│   │   │   │   ├── DB.cpp
│   │   │   │   ├── DB.h
│   │   │   │   ├── DBException.h
│   │   │   │   └── Exer16_06.cpp
│   │   │   ├── Soln16_01/
│   │   │   │   ├── Curveball.h
│   │   │   │   └── Soln16_01.cpp
│   │   │   ├── Soln16_02/
│   │   │   │   ├── Curveball.h
│   │   │   │   ├── Soln16_02.cpp
│   │   │   │   └── TooManyExceptions.h
│   │   │   ├── Soln16_03/
│   │   │   │   ├── Box.h
│   │   │   │   ├── RandomBoxes.h
│   │   │   │   ├── Soln16_03.cpp
│   │   │   │   ├── Truckload.cpp
│   │   │   │   └── Truckload.h
│   │   │   ├── Soln16_04/
│   │   │   │   └── Soln16_04.cpp
│   │   │   ├── Soln16_05/
│   │   │   │   ├── Curveball.h
│   │   │   │   ├── DomainExceptions.h
│   │   │   │   └── Soln16_05.cpp
│   │   │   └── Soln16_06/
│   │   │       ├── Customer.cpp
│   │   │       ├── Customer.h
│   │   │       ├── DB.cpp
│   │   │       ├── DB.h
│   │   │       ├── DBException.h
│   │   │       ├── DB_RAII.h
│   │   │       └── Soln16_06.cpp
│   │   ├── Chapter 17/
│   │   │   ├── Soln17_01/
│   │   │   │   ├── Array.h
│   │   │   │   └── Soln17_01.cpp
│   │   │   ├── Soln17_02/
│   │   │   │   ├── Pair.h
│   │   │   │   └── Soln17_02.cpp
│   │   │   ├── Soln17_03/
│   │   │   │   ├── Pair.h
│   │   │   │   └── Soln17_03.cpp
│   │   │   ├── Soln17_04/
│   │   │   │   ├── Pair.h
│   │   │   │   ├── Soln17_04.cpp
│   │   │   │   └── SparseArray.h
│   │   │   ├── Soln17_05/
│   │   │   │   ├── LinkedList.h
│   │   │   │   └── Soln17_05.cpp
│   │   │   ├── Soln17_06/
│   │   │   │   ├── LinkedList.h
│   │   │   │   ├── Pair.h
│   │   │   │   ├── Soln17_06.cpp
│   │   │   │   └── SparseArray.h
│   │   │   ├── Soln17_07/
│   │   │   │   ├── Box.h
│   │   │   │   ├── BoxFormatter.h
│   │   │   │   └── Soln17_07.cpp
│   │   │   └── Soln17_07A/
│   │   │       ├── Box.h
│   │   │       ├── BoxFormatter.h
│   │   │       └── Soln17_07A.cpp
│   │   ├── Chapter 18/
│   │   │   ├── Soln18_01/
│   │   │   │   ├── Box.h
│   │   │   │   ├── RandomBoxes.h
│   │   │   │   ├── Soln18_01.cpp
│   │   │   │   ├── Truckload.cpp
│   │   │   │   └── Truckload.h
│   │   │   ├── Soln18_02/
│   │   │   │   ├── LinkedList.h
│   │   │   │   └── Soln18_02.cpp
│   │   │   ├── Soln18_03/
│   │   │   │   ├── Customer.cpp
│   │   │   │   ├── Customer.h
│   │   │   │   ├── DB.cpp
│   │   │   │   ├── DB.h
│   │   │   │   ├── DBException.h
│   │   │   │   ├── DB_RAII.h
│   │   │   │   └── Soln18_03.cpp
│   │   │   ├── Soln18_04/
│   │   │   │   ├── Customer.cpp
│   │   │   │   ├── Customer.h
│   │   │   │   ├── DB.cpp
│   │   │   │   ├── DB.h
│   │   │   │   ├── DBException.h
│   │   │   │   ├── DB_RAII.h
│   │   │   │   └── Soln18_04.cpp
│   │   │   └── Soln18_05/
│   │   │       ├── Customer.cpp
│   │   │       ├── Customer.h
│   │   │       ├── DB.cpp
│   │   │       ├── DB.h
│   │   │       ├── DBException.h
│   │   │       ├── DB_RAII.h
│   │   │       └── Soln18_05.cpp
│   │   ├── Chapter 19/
│   │   │   ├── Soln19_01/
│   │   │   │   └── Soln19_01.cpp
│   │   │   ├── Soln19_02/
│   │   │   │   ├── Soln19_02.cpp
│   │   │   │   └── Sort.h
│   │   │   ├── Soln19_03/
│   │   │   │   ├── Soln19_03.cpp
│   │   │   │   └── Sort.h
│   │   │   ├── Soln19_04/
│   │   │   │   ├── Collect.h
│   │   │   │   └── Soln19_04.cpp
│   │   │   └── Soln19_05/
│   │   │       ├── Box.h
│   │   │       ├── DeliveryTruck.cpp
│   │   │       ├── DeliveryTruck.h
│   │   │       ├── RandomBoxes.h
│   │   │       ├── Soln19_05.cpp
│   │   │       ├── Truckload.cpp
│   │   │       └── Truckload.h
│   │   ├── Chapter 20/
│   │   │   ├── Soln20_01/
│   │   │   │   ├── Box.h
│   │   │   │   ├── RandomBoxes.h
│   │   │   │   ├── Soln20_01.cpp
│   │   │   │   ├── Truckload.cpp
│   │   │   │   └── Truckload.h
│   │   │   ├── Soln20_02/
│   │   │   │   └── Soln20_02.cpp
│   │   │   ├── Soln20_03/
│   │   │   │   └── Soln20_03.cpp
│   │   │   ├── Soln20_03A/
│   │   │   │   └── Soln20_03A.cpp
│   │   │   ├── Soln20_04/
│   │   │   │   └── Soln20_04.cpp
│   │   │   ├── Soln20_05/
│   │   │   │   └── Soln20_05.cpp
│   │   │   ├── Soln20_06/
│   │   │   │   └── Soln20_06.cpp
│   │   │   ├── Soln20_07/
│   │   │   │   └── Soln20_07.cpp
│   │   │   ├── Soln20_08/
│   │   │   │   └── Soln20_08.cpp
│   │   │   ├── Soln20_09/
│   │   │   │   └── Soln20_09.cpp
│   │   │   ├── Soln20_10/
│   │   │   │   └── Soln20_10.cpp
│   │   │   ├── Soln20_11/
│   │   │   │   └── Soln20_11.cpp
│   │   │   ├── Soln20_12/
│   │   │   │   └── Soln20_12.cpp
│   │   │   ├── Soln20_13/
│   │   │   │   └── Soln20_13.cpp
│   │   │   └── Soln20_14/
│   │   │       └── Soln20_14.cpp
│   │   └── Chapter 21/
│   │       ├── Soln21_01/
│   │       │   └── Soln21_01.cpp
│   │       ├── Soln21_02/
│   │       │   └── Soln21_02.cpp
│   │       ├── Soln21_03/
│   │       │   └── Soln21_03.cpp
│   │       ├── Soln21_04/
│   │       │   └── Soln21_04.cpp
│   │       ├── Soln21_05/
│   │       │   └── Soln21_05.cpp
│   │       └── Soln21_06/
│   │           ├── Array.h
│   │           └── Soln21_06.cpp
│   └── README.md
├── LICENSE.txt
├── README.md
├── Workarounds/
│   ├── README.md
│   ├── format
│   └── ranges
└── errata.md
Download .txt
SYMBOL INDEX (2193 symbols across 1123 files)

FILE: Examples/Modules/Chapter 01/Ex1_01.cpp
  function main (line 4) | int main()

FILE: Examples/Modules/Chapter 01/Ex1_02.cpp
  function main (line 4) | int main()

FILE: Examples/Modules/Chapter 02/Ex2_01.cpp
  function main (line 4) | int main()

FILE: Examples/Modules/Chapter 02/Ex2_02.cpp
  function main (line 4) | int main()

FILE: Examples/Modules/Chapter 02/Ex2_03.cpp
  function main (line 7) | int main()

FILE: Examples/Modules/Chapter 02/Ex2_03A.cpp
  function main (line 9) | int main()

FILE: Examples/Modules/Chapter 02/Ex2_03B.cpp
  function main (line 8) | int main()

FILE: Examples/Modules/Chapter 02/Ex2_03C.cpp
  function main (line 8) | int main()

FILE: Examples/Modules/Chapter 02/Ex2_03D.cpp
  function main (line 8) | int main()

FILE: Examples/Modules/Chapter 02/Ex2_04.cpp
  function main (line 4) | int main()

FILE: Examples/Modules/Chapter 02/Ex2_05.cpp
  function main (line 5) | int main()

FILE: Examples/Modules/Chapter 02/Ex2_06.cpp
  function main (line 6) | int main()

FILE: Examples/Modules/Chapter 02/Ex2_06B.cpp
  function main (line 6) | int main()

FILE: Examples/Modules/Chapter 02/Ex2_07.cpp
  function main (line 6) | int main()

FILE: Examples/Modules/Chapter 03/Ex3_01.cpp
  function main (line 5) | int main()

FILE: Examples/Modules/Chapter 03/Ex3_02.cpp
  function main (line 8) | int main()

FILE: Examples/Modules/Chapter 03/Ex3_03.cpp
  function main (line 5) | int main()

FILE: Examples/Modules/Chapter 04/Ex4_01.cpp
  function main (line 4) | int main()

FILE: Examples/Modules/Chapter 04/Ex4_01A.cpp
  function main (line 5) | int main()

FILE: Examples/Modules/Chapter 04/Ex4_02.cpp
  function main (line 6) | int main()

FILE: Examples/Modules/Chapter 04/Ex4_02A.cpp
  function main (line 6) | int main()

FILE: Examples/Modules/Chapter 04/Ex4_03.cpp
  function main (line 4) | int main()

FILE: Examples/Modules/Chapter 04/Ex4_04.cpp
  function main (line 4) | int main()

FILE: Examples/Modules/Chapter 04/Ex4_04A.cpp
  function main (line 6) | int main()

FILE: Examples/Modules/Chapter 04/Ex4_05.cpp
  function main (line 4) | int main()

FILE: Examples/Modules/Chapter 04/Ex4_06.cpp
  function main (line 4) | int main()

FILE: Examples/Modules/Chapter 04/Ex4_07.cpp
  function main (line 5) | int main()

FILE: Examples/Modules/Chapter 04/Ex4_08.cpp
  function main (line 4) | int main()

FILE: Examples/Modules/Chapter 04/Ex4_09.cpp
  function main (line 6) | int main()

FILE: Examples/Modules/Chapter 04/Ex4_09A.cpp
  function main (line 6) | int main()

FILE: Examples/Modules/Chapter 05/Ex5_01.cpp
  function main (line 4) | int main()

FILE: Examples/Modules/Chapter 05/Ex5_02.cpp
  function main (line 5) | int main()

FILE: Examples/Modules/Chapter 05/Ex5_03.cpp
  function main (line 6) | int main()

FILE: Examples/Modules/Chapter 05/Ex5_03A.cpp
  function main (line 6) | int main()

FILE: Examples/Modules/Chapter 05/Ex5_04.cpp
  function main (line 5) | int main()

FILE: Examples/Modules/Chapter 05/Ex5_04A.cpp
  function main (line 6) | int main()

FILE: Examples/Modules/Chapter 05/Ex5_05.cpp
  function main (line 5) | int main()

FILE: Examples/Modules/Chapter 05/Ex5_06.cpp
  function main (line 6) | int main()

FILE: Examples/Modules/Chapter 05/Ex5_07.cpp
  function main (line 7) | int main()

FILE: Examples/Modules/Chapter 05/Ex5_07A.cpp
  function main (line 8) | int main()

FILE: Examples/Modules/Chapter 05/Ex5_08.cpp
  function main (line 7) | int main()

FILE: Examples/Modules/Chapter 05/Ex5_09.cpp
  function main (line 5) | int main()

FILE: Examples/Modules/Chapter 05/Ex5_10.cpp
  function main (line 6) | int main()

FILE: Examples/Modules/Chapter 05/Ex5_11.cpp
  function main (line 5) | int main()

FILE: Examples/Modules/Chapter 05/Ex5_12.cpp
  function main (line 11) | int main()

FILE: Examples/Modules/Chapter 05/Ex5_12A.cpp
  function main (line 11) | int main()

FILE: Examples/Modules/Chapter 05/Ex5_13.cpp
  function main (line 5) | int main()

FILE: Examples/Modules/Chapter 05/Ex5_14.cpp
  function main (line 9) | int main()

FILE: Examples/Modules/Chapter 05/Ex5_15.cpp
  function main (line 6) | int main()

FILE: Examples/Modules/Chapter 06/Ex6_01.cpp
  function main (line 4) | int main()

FILE: Examples/Modules/Chapter 06/Ex6_02.cpp
  function main (line 6) | int main()

FILE: Examples/Modules/Chapter 06/Ex6_03.cpp
  function main (line 4) | int main()

FILE: Examples/Modules/Chapter 06/Ex6_04.cpp
  function main (line 5) | int main()

FILE: Examples/Modules/Chapter 06/Ex6_05.cpp
  function main (line 5) | int main()

FILE: Examples/Modules/Chapter 06/Ex6_06.cpp
  function main (line 7) | int main()

FILE: Examples/Modules/Chapter 06/Ex6_07.cpp
  function main (line 9) | int main()

FILE: Examples/Modules/Chapter 08/Ex8_01.cpp
  function power (line 6) | double power(double x, int n)
  function main (line 22) | int main()

FILE: Examples/Modules/Chapter 08/Ex8_02.cpp
  function main (line 7) | int main()
  function power (line 17) | double power(double x, int n)

FILE: Examples/Modules/Chapter 08/Ex8_03.cpp
  function main (line 6) | int main()
  function changeIt (line 16) | double changeIt(double it)

FILE: Examples/Modules/Chapter 08/Ex8_04.cpp
  function main (line 6) | int main()
  function changeIt (line 16) | double changeIt(double* pit)

FILE: Examples/Modules/Chapter 08/Ex8_05.cpp
  function main (line 7) | int main()
  function average (line 14) | double average(double array[], size_t count)

FILE: Examples/Modules/Chapter 08/Ex8_05A.cpp
  function main (line 8) | int main()
  function average10 (line 16) | double average10(double array[10])         /* The [10] does not mean wha...

FILE: Examples/Modules/Chapter 08/Ex8_06.cpp
  function main (line 7) | int main()
  function yield (line 18) | double yield(const double array[][4], size_t size)

FILE: Examples/Modules/Chapter 08/Ex8_06A.cpp
  function main (line 7) | int main()
  function yield (line 18) | double yield(const double array[][4], size_t size)

FILE: Examples/Modules/Chapter 08/Ex8_07.cpp
  function main (line 7) | int main()
  function change_it_by_pointer (line 18) | void change_it_by_pointer(double* pit)
  function change_it_by_reference (line 22) | void change_it_by_reference(double& pit)

FILE: Examples/Modules/Chapter 08/Ex8_08.cpp
  function main (line 13) | int main()
  function find_words (line 26) | void find_words(vector<string>& words, const string& text, const string&...
  function list_words (line 41) | void list_words(const vector<string>& words)

FILE: Examples/Modules/Chapter 08/Ex8_09A.cpp
  function main (line 7) | int main()
  function average10 (line 16) | double average10(const double (&array)[10])   /* Only arrays of length 1...

FILE: Examples/Modules/Chapter 08/Ex8_09B.cpp
  function main (line 7) | int main()
  function average10 (line 15) | double average10(const double (&array)[10])

FILE: Examples/Modules/Chapter 08/Ex8_09C.cpp
  function main (line 7) | int main()
  function average10 (line 15) | double average10(const std::array<double,10>& array)

FILE: Examples/Modules/Chapter 08/Ex8_10.cpp
  function double_it (line 4) | void double_it(double& it)      { it *= 2; }
  function print_it (line 5) | void print_it(const double& it) { std::cout << it << std::endl; }
  function main (line 7) | int main()

FILE: Examples/Modules/Chapter 08/Ex8_11.cpp
  function main (line 10) | int main()
  function show_data (line 26) | void show_data(const int data[], size_t count, const std::string& title,

FILE: Examples/Modules/Chapter 08/Ex8_12.cpp
  function main (line 4) | int  main(int argc, char* argv[])

FILE: Examples/Modules/Chapter 08/Ex8_13.cpp
  function main (line 16) | int main()
  function show_data (line 31) | void show_data(const double data[], size_t count,

FILE: Examples/Modules/Chapter 08/Ex8_14.cpp
  function main (line 14) | int main()
  function largest (line 29) | double largest(const double data[], size_t count)
  function largest (line 38) | double largest(const std::vector<double>& data)
  function largest (line 47) | int largest(const std::vector<int>& data)
  function largest (line 56) | std::string largest(const std::vector<std::string>& words)

FILE: Examples/Modules/Chapter 08/Ex8_15.cpp
  function main (line 8) | int main()
  function larger (line 21) | double larger(double a, double b)

FILE: Examples/Modules/Chapter 08/Ex8_16.cpp
  function main (line 7) | int main()
  function power (line 16) | double power(double x, int n)

FILE: Examples/Modules/Chapter 08/Ex8_17.cpp
  function main (line 16) | int main()
  function extract_words (line 37) | void extract_words(Words& words, const std::string& text, const std::str...
  function swap (line 51) | void swap(Words& words, size_t first, size_t second)
  function sort (line 59) | void sort(Words& words)
  function sort (line 65) | void sort(Words& words, size_t start, size_t end)
  function max_word_length (line 88) | size_t max_word_length(const Words& words)
  function show_words (line 96) | void show_words(const Words& words)

FILE: Examples/Modules/Chapter 09/Ex9_01.cpp
  function main (line 10) | int main()
  function find_last (line 30) | std::optional<size_t> find_last(const std::string& string, char to_find,

FILE: Examples/Modules/Chapter 09/Ex9_02.cpp
  function main (line 15) | int main()
  function find_words (line 28) | void find_words(vector<string>& words, string_view text, string_view sep...
  function list_words (line 44) | void list_words(const vector<string>& words)

FILE: Examples/Modules/Chapter 09/Ex9_03.cpp
  function main (line 23) | int main()
  function largest (line 39) | double largest(std::span<double> data)
  function largest (line 48) | int largest(std::span<int> data)
  function largest (line 57) | std::string largest(std::span<std::string> words)

FILE: Examples/Modules/Chapter 09/Ex9_03A.cpp
  function main (line 20) | int main()
  function largest (line 36) | double largest(std::span<const double> data)
  function largest (line 45) | int largest(std::span<const int> data)
  function largest (line 54) | std::string largest(std::span<const std::string> words)

FILE: Examples/Modules/Chapter 10/Ex10_01.cpp
  function main (line 8) | int main()
  function T (line 24) | T larger(T a, T b)

FILE: Examples/Modules/Chapter 10/Ex10_02.cpp
  function main (line 11) | int main()
  function T (line 29) | T larger(T a, T b)
  function T (line 35) | T* larger(T* a, T* b)
  function T (line 41) | const T* larger(const std::vector<T>& data)

FILE: Examples/Modules/Chapter 10/Ex10_03.cpp
  function larger (line 8) | auto larger(const T1& a, const T2& b)
  function main (line 13) | int main()

FILE: Examples/Modules/Chapter 10/Ex10_03A.cpp
  function larger (line 9) | decltype(auto) larger(const T1& a, const T2& b)
  function main (line 14) | int main()

FILE: Examples/Modules/Chapter 10/Ex10_04.cpp
  function main (line 7) | int main()
  function T (line 25) | T average(const T(&array)[N])

FILE: Examples/Modules/Chapter 11/Ex11_01/Ex11_01.cpp
  function main (line 6) | int main()

FILE: Examples/Modules/Chapter 11/Ex11_01A/Ex11_01A.cpp
  function main (line 6) | int main()

FILE: Examples/Modules/Chapter 11/Ex11_01B/Ex11_01B.cpp
  function main (line 6) | int main()

FILE: Examples/Modules/Chapter 11/Ex11_02/Ex11_02.cpp
  function main (line 6) | int main()

FILE: Examples/Modules/Chapter 11/Ex11_02/from_roman.cpp
  function from_roman (line 4) | unsigned int from_roman(char c)
  function from_roman (line 14) | unsigned int from_roman(std::string_view roman)

FILE: Examples/Modules/Chapter 11/Ex11_02/to_roman.cpp
  function to_roman (line 4) | std::string to_roman(unsigned int i)

FILE: Examples/Modules/Chapter 11/Ex11_03/Ex11_03.cpp
  function main (line 5) | int main()

FILE: Examples/Modules/Chapter 11/Ex11_03/from_roman.cpp
  function from_roman (line 4) | unsigned int from_roman(char c)
  function from_roman (line 14) | unsigned int from_roman(std::string_view roman)

FILE: Examples/Modules/Chapter 11/Ex11_03/to_roman.cpp
  function to_roman (line 4) | std::string to_roman(unsigned int i)

FILE: Examples/Modules/Chapter 11/Ex11_04/Ex11_04.cpp
  function main (line 6) | int main()

FILE: Examples/Modules/Chapter 11/Ex11_04/from_roman.cpp
  function from_roman (line 5) | unsigned int from_roman(std::string_view roman)

FILE: Examples/Modules/Chapter 11/Ex11_04/roman-internals.cpp
  function from_roman (line 4) | unsigned int from_roman(char c)

FILE: Examples/Modules/Chapter 11/Ex11_04/to_roman.cpp
  function to_roman (line 4) | std::string to_roman(unsigned int i)

FILE: Examples/Modules/Chapter 11/Ex11_05/Ex11_05.cpp
  function main (line 6) | int main()

FILE: Examples/Modules/Chapter 11/Ex11_05/from_roman.cpp
  function from_roman (line 5) | unsigned int from_roman(std::string_view roman)

FILE: Examples/Modules/Chapter 11/Ex11_05/roman-internals.cpp
  function from_roman (line 4) | unsigned int from_roman(char c)

FILE: Examples/Modules/Chapter 11/Ex11_06/Ex11_06.cpp
  type math (line 6) | namespace math
    function square (line 9) | auto square(const auto& x) { return x * x; }
    function pow4 (line 10) | auto pow4(const auto& x) { return square(square(x)); }
  function main (line 13) | int main()

FILE: Examples/Modules/Chapter 11/Ex11_06A/Ex11_06A.cpp
  function main (line 6) | int main()

FILE: Examples/Modules/Chapter 11/Ex11_06B/Ex11_06B.cpp
  function main (line 6) | int main()

FILE: Examples/Modules/Chapter 11/Ex11_07/Ex11_07.cpp
  function main (line 6) | int main()

FILE: Examples/Modules/Chapter 11/Ex11_07/math.cpp
  type math::averages (line 11) | namespace math::averages
    function arithmetic_mean (line 13) | double arithmetic_mean(std::span<const double> data)
  type math (line 28) | namespace math
    type averages (line 30) | namespace averages
      function geometric_mean (line 32) | double geometric_mean(std::span<const double> data)
  type math (line 62) | namespace math
    type averages (line 30) | namespace averages
      function geometric_mean (line 32) | double geometric_mean(std::span<const double> data)
  function quicksort (line 91) | void quicksort(std::vector<double>& data)
  function quicksort (line 97) | void quicksort(std::vector<double>& data, size_t start, size_t end)

FILE: Examples/Modules/Chapter 11/Ex11_08/Ex11_08.cpp
  function hypotenuse (line 9) | auto hypotenuse(const auto& x, const auto& y)
  function main (line 18) | int main()

FILE: Examples/Modules/Chapter 12/Ex12_01/Ex12_01.cpp
  class Box (line 5) | class Box
    method Box (line 9) | Box(double length, double width, double height)
    method volume (line 18) | double volume()
  function main (line 29) | int main()

FILE: Examples/Modules/Chapter 12/Ex12_01A/Ex12_01A.cpp
  class Box (line 5) | class Box
    method Box (line 9) | Box() = default;
    method Box (line 12) | Box(double length, double width, double height)
    method volume (line 21) | double volume()
  function main (line 32) | int main()

FILE: Examples/Modules/Chapter 12/Ex12_02/Ex12_02.cpp
  class Box (line 9) | class Box
    method Box (line 12) | Box() = default;
  function main (line 23) | int main()

FILE: Examples/Modules/Chapter 12/Ex12_03/Ex12_03.cpp
  class Box (line 5) | class Box
    method Box (line 8) | Box() = default;
  function main (line 19) | int main()

FILE: Examples/Modules/Chapter 12/Ex12_04/Ex12_04.cpp
  class Cube (line 6) | class Cube
  function main (line 24) | int main()

FILE: Examples/Modules/Chapter 12/Ex12_05/Ex12_05.cpp
  class Box (line 4) | class Box
    method Box (line 9) | Box() = default;
  function main (line 33) | int main()

FILE: Examples/Modules/Chapter 12/Ex12_05A/Ex12_05A.cpp
  class Box (line 5) | class Box
    method Box (line 10) | Box() = default;
  function main (line 35) | int main()

FILE: Examples/Modules/Chapter 12/Ex12_06/Ex12_06.cpp
  function main (line 5) | int main()

FILE: Examples/Modules/Chapter 12/Ex12_06A/Ex12_06A.cpp
  function main (line 6) | int main()

FILE: Examples/Modules/Chapter 12/Ex12_06B/Ex12_06B.cpp
  function main (line 6) | int main()

FILE: Examples/Modules/Chapter 12/Ex12_07/Ex12_07.cpp
  function main (line 5) | int main()

FILE: Examples/Modules/Chapter 12/Ex12_08/Box.cpp
  function Box (line 18) | Box& Box::setLength(double length)
  function Box (line 23) | Box& Box::setWidth(double width)
  function Box (line 28) | Box& Box::setHeight(double height)

FILE: Examples/Modules/Chapter 12/Ex12_08/Ex12_08.cpp
  function main (line 5) | int main()

FILE: Examples/Modules/Chapter 12/Ex12_09/Ex12_09.cpp
  function main (line 5) | int main()

FILE: Examples/Modules/Chapter 12/Ex12_10/Ex12_10.cpp
  function main (line 5) | int main()

FILE: Examples/Modules/Chapter 12/Ex12_11/Ex12_11.cpp
  function main (line 5) | int main()

FILE: Examples/Modules/Chapter 12/Ex12_12/Ex12_12.cpp
  function main (line 6) | int main()
  function surfaceArea (line 23) | double surfaceArea(const Box& box)

FILE: Examples/Modules/Chapter 12/Ex12_13/Ex12_13.cpp
  function main (line 5) | int main()

FILE: Examples/Modules/Chapter 12/Ex12_14/Ex12_14.cpp
  function main (line 5) | int main()

FILE: Examples/Modules/Chapter 12/Ex12_15/Ex12_15.cpp
  function main (line 5) | int main()

FILE: Examples/Modules/Chapter 12/Ex12_16/Ex12_16.cpp
  function main (line 5) | int main()

FILE: Examples/Modules/Chapter 12/Ex12_17/Ex12_17.cpp
  function main (line 6) | int main()

FILE: Examples/Modules/Chapter 12/Ex12_17/Package.cpp
  class Package (line 5) | class Package
    method Package (line 8) | Package(SharedBox box) : m_box{box}, m_next{nullptr} {}
    method SharedBox (line 12) | SharedBox getBox() const { return m_box; }
    method Package (line 15) | Package* getNext() { return m_next; }
    method setNext (line 16) | void setNext(Package* package) { m_next = package; }

FILE: Examples/Modules/Chapter 12/Ex12_17/Truckload.cpp
  function SharedBox (line 49) | SharedBox Truckload::getFirstBox()
  function SharedBox (line 56) | SharedBox Truckload::getNextBox()

FILE: Examples/Modules/Chapter 12/Ex12_18/Ex12_18.cpp
  function main (line 6) | int main()

FILE: Examples/Modules/Chapter 12/Ex12_18/Truckload.cpp
  function SharedBox (line 48) | SharedBox Truckload::getFirstBox()
  function SharedBox (line 55) | SharedBox Truckload::getNextBox()

FILE: Examples/Modules/Chapter 13/Ex13_01/Ex13_01.cpp
  function main (line 6) | int main()

FILE: Examples/Modules/Chapter 13/Ex13_02/Ex13_02.cpp
  function show (line 8) | void show(const Box& box)
  function main (line 14) | int main()

FILE: Examples/Modules/Chapter 13/Ex13_03/Ex13_03.cpp
  function show (line 8) | void show(const Box& box)
  function show (line 13) | void show(const Box& box1, std::string_view relationship, const Box& box2)
  function main (line 18) | int main()

FILE: Examples/Modules/Chapter 13/Ex13_03A/Ex13_03A.cpp
  function show (line 9) | void show(const Box& box)
  function show (line 14) | void show(const Box& box1, std::string_view relationship, const Box& box2)
  function main (line 19) | int main()

FILE: Examples/Modules/Chapter 13/Ex13_04/Ex13_04.cpp
  function main (line 8) | int main()

FILE: Examples/Modules/Chapter 13/Ex13_05/Box.cpp
  function Box (line 11) | Box Box::operator+(const Box& aBox) const

FILE: Examples/Modules/Chapter 13/Ex13_05/Ex13_05.cpp
  function createUniformPseudoRandomNumberGenerator (line 10) | auto createUniformPseudoRandomNumberGenerator(double max)
  function main (line 18) | int main()

FILE: Examples/Modules/Chapter 13/Ex13_06/Box.cpp
  function Box (line 13) | Box& Box::operator+=(const Box& aBox)
  function Box (line 23) | Box Box::operator+(const Box& aBox) const

FILE: Examples/Modules/Chapter 13/Ex13_06/Ex13_06.cpp
  function createUniformPseudoRandomNumberGenerator (line 10) | auto createUniformPseudoRandomNumberGenerator(double max)
  function main (line 18) | int main()

FILE: Examples/Modules/Chapter 13/Ex13_07/Ex13_07.cpp
  function main (line 5) | int main()

FILE: Examples/Modules/Chapter 13/Ex13_08/Ex13_08.cpp
  function main (line 5) | int main()

FILE: Examples/Modules/Chapter 13/Ex13_09/Ex13_09.cpp
  function main (line 5) | int main()

FILE: Examples/Modules/Chapter 13/Ex13_10/Ex13_10.cpp
  function createUniformPseudoRandomNumberGenerator (line 9) | auto createUniformPseudoRandomNumberGenerator(double max)
  function main (line 17) | int main()

FILE: Examples/Modules/Chapter 13/Ex13_10/Truckload.cpp
  class Truckload::Package (line 8) | class Truckload::Package
    method Package (line 14) | Package(SharedBox box) : m_box{ box }, m_next{ nullptr } {}
  function SharedBox (line 51) | SharedBox Truckload::Iterator::getFirstBox()
  function SharedBox (line 59) | SharedBox Truckload::Iterator::getNextBox()
  function SharedBox (line 109) | SharedBox Truckload::operator[](size_t index) const

FILE: Examples/Modules/Chapter 13/Ex13_11/Ex13_11.cpp
  function createUniformPseudoRandomNumberGenerator (line 21) | auto createUniformPseudoRandomNumberGenerator(double max)
  function main (line 29) | int main()

FILE: Examples/Modules/Chapter 13/Ex13_11/Truckload.cpp
  class Truckload::Package (line 8) | class Truckload::Package
    method Package (line 14) | Package(SharedBox box) : m_box{ box }, m_next{ nullptr } {}
  function SharedBox (line 51) | SharedBox Truckload::Iterator::getFirstBox()
  function SharedBox (line 59) | SharedBox Truckload::Iterator::getNextBox()
  function SharedBox (line 109) | SharedBox& Truckload::operator[](size_t index) const

FILE: Examples/Modules/Chapter 13/Ex13_12/Ex13_12.cpp
  function main (line 5) | int main()

FILE: Examples/Modules/Chapter 13/Ex13_12/Message.cpp
  function Message (line 5) | Message& Message::operator=(const Message& message)

FILE: Examples/Modules/Chapter 13/Ex13_12A/Ex13_12A.cpp
  function main (line 6) | int main()

FILE: Examples/Modules/Chapter 13/Ex13_12A/Message.cpp
  function Message (line 10) | Message& Message::operator=(const Message& message)

FILE: Examples/Modules/Chapter 13/Ex13_12B/Ex13_12B.cpp
  function main (line 10) | int main()

FILE: Examples/Modules/Chapter 13/Ex13_12B/Message.cpp
  function Message (line 10) | Message& Message::operator=(const Message& message)

FILE: Examples/Modules/Chapter 14/Ex14_01/Ex14_01.cpp
  function main (line 6) | int main()

FILE: Examples/Modules/Chapter 14/Ex14_01A/Ex14_01A.cpp
  function main (line 6) | int main()

FILE: Examples/Modules/Chapter 14/Ex14_02/Ex14_02.cpp
  function main (line 5) | int main()

FILE: Examples/Modules/Chapter 14/Ex14_03/Ex14_03.cpp
  function main (line 5) | int main()

FILE: Examples/Modules/Chapter 14/Ex14_04/Ex14_04.cpp
  function main (line 6) | int main()

FILE: Examples/Modules/Chapter 14/Ex14_04A/Ex14_04A.cpp
  function main (line 10) | int main()

FILE: Examples/Modules/Chapter 14/Ex14_04B/Ex14_04B.cpp
  function main (line 10) | int main()

FILE: Examples/Modules/Chapter 14/Ex14_04C/Ex14_04C.cpp
  function main (line 10) | int main()

FILE: Examples/Modules/Chapter 14/Ex14_05/Ex14_05.cpp
  function main (line 5) | int main()

FILE: Examples/Modules/Chapter 14/Ex14_06/Ex14_06.cpp
  function main (line 5) | int main()

FILE: Examples/Modules/Chapter 14/Ex14_07/Ex14_07.cpp
  function main (line 7) | int main()

FILE: Examples/Modules/Chapter 14/Ex14_07A/Ex14_07A.cpp
  function main (line 5) | int main()

FILE: Examples/Modules/Chapter 14/Ex14_07B/Ex14_07B.cpp
  function main (line 6) | int main()

FILE: Examples/Modules/Chapter 15/Ex15_01/Ex15_01.cpp
  function main (line 4) | int main()

FILE: Examples/Modules/Chapter 15/Ex15_02/Ex15_02.cpp
  function main (line 5) | int main()

FILE: Examples/Modules/Chapter 15/Ex15_03/Ex15_03.cpp
  function main (line 5) | int main()

FILE: Examples/Modules/Chapter 15/Ex15_04/Ex15_04.cpp
  function main (line 5) | int main()

FILE: Examples/Modules/Chapter 15/Ex15_05/Ex15_05.cpp
  function showVolume (line 6) | void showVolume(const Box& box)
  function main (line 11) | int main()

FILE: Examples/Modules/Chapter 15/Ex15_06/Ex15_06.cpp
  function main (line 7) | int main()

FILE: Examples/Modules/Chapter 15/Ex15_07/Ex15_07.cpp
  function main (line 7) | int main()

FILE: Examples/Modules/Chapter 15/Ex15_07A/Ex15_07A.cpp
  function main (line 7) | int main()

FILE: Examples/Modules/Chapter 15/Ex15_08/Ex14_08.cpp
  function main (line 4) | int main()

FILE: Examples/Modules/Chapter 15/Ex15_09/Ex15_09.cpp
  class NonPolyBase (line 7) | class NonPolyBase {}
  class NonPolyDerived (line 8) | class NonPolyDerived : public NonPolyBase {}
  function main (line 13) | int main()
  function Box (line 47) | Box& getSomeBox()
  function NonPolyBase (line 53) | NonPolyBase& getSomeNonPoly()

FILE: Examples/Modules/Chapter 15/Ex15_10/Ex15_10.cpp
  function main (line 5) | int main()

FILE: Examples/Modules/Chapter 15/Ex15_11/Ex15_11.cpp
  function main (line 8) | int main()

FILE: Examples/Modules/Chapter 16/Ex16_01/Ex16_01.cpp
  function main (line 4) | int main()

FILE: Examples/Modules/Chapter 16/Ex16_02/Ex16_02.cpp
  function main (line 8) | int main()
  function trySomething (line 24) | void trySomething(int i)

FILE: Examples/Modules/Chapter 16/Ex16_03/Ex16_03.cpp
  function main (line 6) | int main()

FILE: Examples/Modules/Chapter 16/Ex16_04/Ex16_04.cpp
  function main (line 7) | int main()

FILE: Examples/Modules/Chapter 16/Ex16_05/Ex16_05.cpp
  function main (line 7) | int main()

FILE: Examples/Modules/Chapter 16/Ex16_06/Ex16_06.cpp
  function main (line 7) | int main()

FILE: Examples/Modules/Chapter 16/Ex16_07/Ex16_07.cpp
  function main (line 10) | int main()
  function computeValue (line 32) | double computeValue(size_t x)

FILE: Examples/Modules/Chapter 16/Ex16_07A/Ex16_07A.cpp
  function main (line 10) | int main()
  function computeValue (line 41) | double computeValue(size_t x)

FILE: Examples/Modules/Chapter 16/Ex16_07B/Ex16_07B.cpp
  function main (line 11) | int main()
  function computeValue (line 33) | double computeValue(size_t x)

FILE: Examples/Modules/Chapter 16/Ex16_07C/Ex16_07C.cpp
  function main (line 14) | int main()
  function computeValues (line 26) | std::unique_ptr<double[]> computeValues(size_t howMany)
  function computeValue (line 34) | double computeValue(size_t x)

FILE: Examples/Modules/Chapter 16/Ex16_07D/Ex16_07D.cpp
  function main (line 14) | int main()
  function computeValues (line 26) | std::vector<double> computeValues(size_t howMany)
  function computeValue (line 34) | double computeValue(size_t x)

FILE: Examples/Modules/Chapter 16/Ex16_09/Ex16_09.cpp
  function main (line 6) | int main()

FILE: Examples/Modules/Chapter 17/Ex17_01/Ex17_01.cpp
  function main (line 7) | int main()

FILE: Examples/Modules/Chapter 17/Ex17_01A/Ex17_01A.cpp
  function main (line 7) | int main()

FILE: Examples/Modules/Chapter 17/Ex17_02/Ex17_02.cpp
  function main (line 8) | int main()

FILE: Examples/Modules/Chapter 17/Ex17_02A/Ex17_02A.cpp
  function main (line 10) | int main()

FILE: Examples/Modules/Chapter 17/Ex17_03/Ex17_03.cpp
  function main (line 7) | int main()

FILE: Examples/Modules/Chapter 17/Ex17_04/Ex17_04.cpp
  function main (line 6) | int main()

FILE: Examples/Modules/Chapter 17/Ex17_04A/Ex17_04A.cpp
  function main (line 7) | int main()

FILE: Examples/Modules/Chapter 17/Ex17_04B/Ex17_04B.cpp
  function main (line 9) | int main()

FILE: Examples/Modules/Chapter 17/Ex17_05/Ex17_05A.cpp
  class Outer (line 4) | class Outer
    class Nested (line 7) | class Nested { /* ... */ }
  function someFunction (line 14) | void someFunction() { /*typename*/ Outer<T>::Nested* nested; /* ... */ }

FILE: Examples/Modules/Chapter 17/Ex17_05/Ex17_05B.cpp
  class Outer (line 6) | class Outer
    class Nested (line 9) | class Nested { /* ... */ }
  function someOtherFunction (line 14) | void someOtherFunction()

FILE: Examples/Modules/Chapter 17/Ex17_05/Ex17_05C.cpp
  class Outer (line 7) | class Outer
    class Nested (line 10) | class Nested { /* ... */ }
  class MyClass (line 15) | class MyClass

FILE: Examples/Modules/Chapter 17/Ex17_06/Ex17_06.cpp
  class Base (line 7) | class Base
    method baseFun (line 10) | void baseFun() { /* ... */ }
  class Derived (line 16) | class Derived : public Base<T>
  function main (line 44) | int main()

FILE: Examples/Modules/Chapter 18/Ex18_01/Ex18_01.cpp
  function buildStringArray (line 7) | Array<std::string> buildStringArray(const size_t size)
  function main (line 15) | int main()

FILE: Examples/Modules/Chapter 18/Ex18_02/Ex18_02.cpp
  function buildStringArray (line 7) | Array<std::string> buildStringArray(const size_t size)
  function main (line 15) | int main()

FILE: Examples/Modules/Chapter 18/Ex18_03/Ex18_03.cpp
  function buildStringArray (line 6) | Array<std::string> buildStringArray(const size_t size)
  function main (line 14) | int main()

FILE: Examples/Modules/Chapter 18/Ex18_04/Ex18_04.cpp
  function buildStringArray (line 6) | Array<std::string> buildStringArray(const size_t size)
  function main (line 14) | int main()

FILE: Examples/Modules/Chapter 18/Ex18_05A/Ex18_05A.cpp
  function buildStringArray (line 7) | Array<std::string> buildStringArray(const size_t size)
  function main (line 15) | int main()

FILE: Examples/Modules/Chapter 18/Ex18_05B/Ex18_05B.cpp
  function buildStringArray (line 9) | Array<std::string> buildStringArray(const size_t size)
  function main (line 17) | int main()

FILE: Examples/Modules/Chapter 18/Ex18_06/Ex18_06.cpp
  function buildStringArray (line 10) | Array<std::string> buildStringArray(const size_t size)
  function main (line 18) | int main()

FILE: Examples/Modules/Chapter 18/Ex18_07/Ex18_07.cpp
  function buildStringArray (line 10) | Array<std::string> buildStringArray(const size_t size)
  function main (line 18) | int main()

FILE: Examples/Modules/Chapter 19/Ex19_01/Ex19_01.cpp
  function main (line 7) | int main()
  function product (line 20) | long product(long a, long b) { return a * b; }
  function sum (line 23) | long sum(long a, long b) { return a + b; }

FILE: Examples/Modules/Chapter 19/Ex19_02/Ex19_02.cpp
  function main (line 12) | int main()
  function less (line 24) | bool less(const int& one, const int& other) { return one < other; }
  function greater (line 27) | bool greater(const T& one, const T& other) { return one > other; }
  function longer (line 29) | bool longer(const std::string& one, const std::string& other)

FILE: Examples/Modules/Chapter 19/Ex19_03/Ex19_03.cpp
  function greater (line 8) | bool greater(const T& one, const T& other) { return one > other; }
  function main (line 10) | int main()

FILE: Examples/Modules/Chapter 19/Ex19_03A/Ex19_03A.cpp
  function main (line 7) | int main()

FILE: Examples/Modules/Chapter 19/Ex19_04/Ex19_04.cpp
  function main (line 8) | int main()

FILE: Examples/Modules/Chapter 19/Ex19_05/Ex19_05.cpp
  function main (line 8) | int main()

FILE: Examples/Modules/Chapter 19/Ex19_05A/Ex19_05A.cpp
  function main (line 10) | int main()

FILE: Examples/Modules/Chapter 19/Ex19_06/Ex19_06.cpp
  function main (line 7) | int main()

FILE: Examples/Modules/Chapter 19/Ex19_07/Ex19_07.cpp
  function main (line 7) | int main()

FILE: Examples/Modules/Chapter 19/Ex19_08/Ex19_08.cpp
  function less (line 7) | bool less(int x, int y) { return x < y; }
  function main (line 9) | int main()

FILE: Examples/Modules/Chapter 20/Ex20_01/Ex20_01.cpp
  function main (line 5) | int main()

FILE: Examples/Modules/Chapter 20/Ex20_02/Ex20_02.cpp
  function main (line 6) | int main()

FILE: Examples/Modules/Chapter 20/Ex20_03/Ex20_03.cpp
  function main (line 7) | int main()
  function printSet (line 30) | void printSet(const std::set<int>& my_set)

FILE: Examples/Modules/Chapter 20/Ex20_04/Ex20_04.cpp
  function main (line 6) | int main()

FILE: Examples/Modules/Chapter 20/Ex20_05/Ex20_05.cpp
  function main (line 19) | int main()
  function Words (line 38) | Words extractWords(std::string_view text, std::string_view separators)
  function WordCounts (line 56) | WordCounts countWords(const Words& words)
  function maxWordLength (line 64) | size_t maxWordLength(const WordCounts& wordCounts)
  function showWordCounts (line 72) | void showWordCounts(const WordCounts& wordCounts)

FILE: Examples/Modules/Chapter 20/Ex20_06/Ex20_06.cpp
  function main (line 5) | int main()

FILE: Examples/Modules/Chapter 20/Ex20_07/Ex20_07.cpp
  function main (line 5) | int main()

FILE: Examples/Modules/Chapter 20/Ex20_08/Ex20_08.cpp
  function main (line 6) | int main()

FILE: Examples/Modules/Chapter 20/Ex20_09/Ex20_09.cpp
  function main (line 7) | int main()
  function printVector (line 26) | void printVector(const std::vector<int>& v)

FILE: Examples/Modules/Chapter 20/Ex20_10/Ex20_10.cpp
  function removeEvenNumbers (line 10) | void removeEvenNumbers(auto& numbers)    /* Correct! */
  function main (line 21) | int main()
  function fillVector_1toN (line 34) | std::vector<int> fillVector_1toN(size_t N)
  function printVector (line 42) | void printVector(std::string_view message, const std::vector<int>& numbers)

FILE: Examples/Modules/Chapter 20/Ex20_11/Ex20_11.cpp
  function main (line 7) | int main()

FILE: Examples/Modules/Chapter 20/Ex20_11A/Ex20_11A.cpp
  function main (line 8) | int main()

FILE: Examples/Modules/Chapter 20/Ex20_12/Ex20_12.cpp
  function main (line 7) | int main()

FILE: Examples/Modules/Chapter 20/Ex20_12A/Ex20_12A.cpp
  function main (line 7) | int main()

FILE: Examples/Modules/Chapter 20/Ex20_13/Ex20_13.cpp
  function main (line 10) | int main()
  function fillSet_1toN (line 24) | std::set<int> fillSet_1toN(size_t N)   // Fill a set with 1, 2, ..., N
  function printVector (line 32) | void printVector(const std::vector<int>& v)

FILE: Examples/Modules/Chapter 20/Ex20_13A/Ex20_13A.cpp
  function main (line 11) | int main()
  function fillSet_1toN (line 24) | std::set<int> fillSet_1toN(size_t N)   // Fill a set with 1, 2, ..., N
  function printVector (line 32) | void printVector(const std::vector<int>& v)

FILE: Examples/Modules/Chapter 20/Ex20_13B/Ex20_13B.cpp
  function main (line 12) | int main()
  function fillSet_1toN (line 25) | std::set<int> fillSet_1toN(size_t N)   // Fill a set with 1, 2, ..., N
  function printVector (line 33) | void printVector(const std::vector<int>& v)

FILE: Examples/Modules/Chapter 20/Ex20_14/Ex20_14.cpp
  function removeEvenNumbers (line 11) | void removeEvenNumbers(std::vector<int>& numbers)
  function main (line 20) | int main()
  function fillVector_1toN (line 33) | std::vector<int> fillVector_1toN(size_t N)
  function printVector (line 41) | void printVector(std::string_view message, const std::vector<int>& numbers)

FILE: Examples/Modules/Chapter 20/Ex20_14A/Ex20_14A.cpp
  function removeEvenNumbers (line 9) | void removeEvenNumbers(std::vector<int>& numbers)
  function main (line 14) | int main()
  function fillVector_1toN (line 27) | std::vector<int> fillVector_1toN(size_t N)
  function printVector (line 35) | void printVector(std::string_view message, const std::vector<int>& numbers)

FILE: Examples/Modules/Chapter 20/Ex20_14B/Ex20_14B.cpp
  function removeEvenNumbers (line 14) | void removeEvenNumbers(std::vector<int>& numbers)
  function main (line 23) | int main()
  function fillVector_1toN (line 36) | std::vector<int> fillVector_1toN(size_t N)
  function printVector (line 44) | void printVector(std::string_view message, const std::vector<int>& numbers)

FILE: Examples/Modules/Chapter 20/Ex20_15/Ex20_15.cpp
  function main (line 7) | int main()

FILE: Examples/Modules/Chapter 20/Ex20_15A/Ex20_15A.cpp
  function main (line 7) | int main()

FILE: Examples/Modules/Chapter 20/Ex20_16/Ex20_16.cpp
  function main (line 11) | int main()

FILE: Examples/Modules/Chapter 20/Ex20_17/Ex20_17.cpp
  function isEven (line 7) | bool isEven(int i) { return i % 2 == 0; }
  function squared (line 8) | int squared(int i) { return i * i; }
  function main (line 10) | int main()

FILE: Examples/Modules/Chapter 20/Ex20_18/Ex20_18.cpp
  function isEven (line 6) | bool isEven(int i) { return i % 2 == 0; }
  function main (line 8) | int main()

FILE: Examples/Modules/Chapter 21/Ex21_01/Ex21_01.cpp
  class MyClass (line 7) | class MyClass { /* just a dummy class */ }
  function main (line 9) | int main()

FILE: Examples/Modules/Chapter 21/Ex21_02/Ex21_02.cpp
  function main (line 59) | int main()

FILE: Examples/Modules/Chapter 21/Ex21_03/Ex21_03.cpp
  function main (line 8) | int main()

FILE: Examples/Modules/Chapter 21/Ex21_04/Ex21_04.cpp
  function distanceBetween (line 10) | auto distanceBetween(Iter first, Iter last)
  function distanceBetween (line 19) | auto distanceBetween(Iter first, Iter last)
  function main (line 25) | int main()

FILE: Examples/NoModules/Appendix A/ExA_01/ExA_01.cpp
  function main (line 7) | int main()

FILE: Examples/NoModules/Appendix A/ExA_02/ExA_02.cpp
  function main (line 9) | int main()

FILE: Examples/NoModules/Appendix A/ExA_02A/ExA_02A.cpp
  function nt (line 13) | nt\

FILE: Examples/NoModules/Appendix A/ExA_03/ExA_03.cpp
  function logError (line 7) | void logError(std::string_view message,
  function main (line 15) | int main()

FILE: Examples/NoModules/Appendix A/ExA_04/ExA_04.cpp
  function main (line 9) | int main()

FILE: Examples/NoModules/Appendix A/ExA_05/ExA_05.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Appendix A/ExA_06/ExA_06.cpp
  function main (line 8) | int main()
  function power (line 15) | double power(double x, int n)   // A first definition
  function power (line 24) | double power(double x, int n)   // A second, more efficient definition (...

FILE: Examples/NoModules/Appendix A/ExA_07/ExA_07.cpp
  function main (line 7) | int main()

FILE: Examples/NoModules/Appendix A/ExA_07/Power.cpp
  function power (line 2) | double power(double x, int n)

FILE: Examples/NoModules/Appendix A/ExA_07A/ExA_07A.cpp
  function main (line 7) | int main()

FILE: Examples/NoModules/Appendix A/ExA_07A/Power.cpp
  function power (line 2) | double power(double x, int n)

FILE: Examples/NoModules/Appendix A/ExA_08/ExA_08.cpp
  function main (line 8) | int main()

FILE: Examples/NoModules/Appendix A/ExA_08/Power.cpp
  function power (line 2) | double power(double x, int n)

FILE: Examples/NoModules/Appendix A/ExA_08A/ExA_08A.cpp
  function main (line 8) | int main()

FILE: Examples/NoModules/Appendix A/ExA_08A/Power.cpp
  function power (line 2) | double power(double x, int n)

FILE: Examples/NoModules/Appendix A/ExA_09/ExA_09.cpp
  function main (line 7) | int main()

FILE: Examples/NoModules/Appendix A/ExA_09/Power.cpp
  function localHelper (line 4) | double localHelper(double x, unsigned n)   // localHelper() has internal...
  function power (line 12) | double power(double x, int n)               // power() has external linkage

FILE: Examples/NoModules/Appendix A/ExA_09A/ExA_09A.cpp
  function main (line 7) | int main()

FILE: Examples/NoModules/Appendix A/ExA_09A/Power.cpp
  function localHelper (line 4) | double localHelper(double x, unsigned n)   // localHelper() has internal...
  function power (line 12) | double power(double x, int n)               // power() has external linkage

FILE: Examples/NoModules/Appendix A/ExA_10/BadMath.h
  type class (line 5) | enum class
  function isOdd (line 6) | bool isOdd(int x) { return x % 2 != 0; }

FILE: Examples/NoModules/Appendix A/ExA_10/ExA_10.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Appendix A/ExA_10A/BetterMath.h
  type class (line 9) | enum class
  function isOdd (line 10) | bool isOdd(int x) { return x % 2 != 0; }

FILE: Examples/NoModules/Appendix A/ExA_10A/ExA_10A.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Appendix A/ExA_11/BetterMath.h
  type class (line 9) | enum class
  function isOdd (line 10) | bool isOdd(int x) { return x % 2 != 0; }

FILE: Examples/NoModules/Appendix A/ExA_11/ExA_11.cpp
  function main (line 8) | int main()

FILE: Examples/NoModules/Appendix A/ExA_11/Hypot.h
  function namespace (line 5) | namespace math

FILE: Examples/NoModules/Appendix A/ExA_11/Pow4.cpp
  type math (line 4) | namespace math
    function pow4 (line 6) | double pow4(double x) { return square(square(x)); }

FILE: Examples/NoModules/Appendix A/ExA_11/Pow4.h
  function namespace (line 5) | namespace math

FILE: Examples/NoModules/Appendix A/ExA_12/ExA_12.cpp
  function main (line 7) | int main()

FILE: Examples/NoModules/Appendix A/ExA_12/Hypot.h
  function namespace (line 5) | namespace math

FILE: Examples/NoModules/Appendix A/ExA_12/Pow4.cpp
  type math (line 4) | namespace math
    function pow4 (line 6) | double pow4(double x) { return square(square(x)); }

FILE: Examples/NoModules/Appendix A/ExA_12/Pow4.h
  function namespace (line 5) | namespace math

FILE: Examples/NoModules/Appendix A/ExA_12/ProperMath.h
  type class (line 9) | enum class
  function isOdd (line 10) | inline bool isOdd(int x) { return x % 2 != 0; }

FILE: Examples/NoModules/Appendix A/ExA_13/Box.h
  function class (line 5) | class Box

FILE: Examples/NoModules/Appendix A/ExA_13/ExA_13.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Appendix A/ExA_13A/Box.h
  function m_height (line 23) | double m_height {1.0};

FILE: Examples/NoModules/Appendix A/ExA_13A/ExA_13A.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 01/Ex1_01.cpp
  function main (line 4) | int main()

FILE: Examples/NoModules/Chapter 01/Ex1_02.cpp
  function main (line 4) | int main()

FILE: Examples/NoModules/Chapter 02/Ex2_01.cpp
  function main (line 4) | int main()

FILE: Examples/NoModules/Chapter 02/Ex2_02.cpp
  function main (line 4) | int main()

FILE: Examples/NoModules/Chapter 02/Ex2_03.cpp
  function main (line 6) | int main()

FILE: Examples/NoModules/Chapter 02/Ex2_03A.cpp
  function main (line 8) | int main()

FILE: Examples/NoModules/Chapter 02/Ex2_03B.cpp
  function main (line 7) | int main()

FILE: Examples/NoModules/Chapter 02/Ex2_03C.cpp
  function main (line 7) | int main()

FILE: Examples/NoModules/Chapter 02/Ex2_03D.cpp
  function main (line 7) | int main()

FILE: Examples/NoModules/Chapter 02/Ex2_04.cpp
  function main (line 4) | int main()

FILE: Examples/NoModules/Chapter 02/Ex2_05.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 02/Ex2_06.cpp
  function main (line 6) | int main()

FILE: Examples/NoModules/Chapter 02/Ex2_06B.cpp
  function main (line 6) | int main()

FILE: Examples/NoModules/Chapter 02/Ex2_07.cpp
  function main (line 6) | int main()

FILE: Examples/NoModules/Chapter 03/Ex3_01.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 03/Ex3_02.cpp
  function main (line 8) | int main()

FILE: Examples/NoModules/Chapter 03/Ex3_03.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 04/Ex4_01.cpp
  function main (line 4) | int main()

FILE: Examples/NoModules/Chapter 04/Ex4_01A.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 04/Ex4_02.cpp
  function main (line 6) | int main()

FILE: Examples/NoModules/Chapter 04/Ex4_02A.cpp
  function main (line 6) | int main()

FILE: Examples/NoModules/Chapter 04/Ex4_03.cpp
  function main (line 4) | int main()

FILE: Examples/NoModules/Chapter 04/Ex4_04.cpp
  function main (line 4) | int main()

FILE: Examples/NoModules/Chapter 04/Ex4_04A.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 04/Ex4_05.cpp
  function main (line 4) | int main()

FILE: Examples/NoModules/Chapter 04/Ex4_06.cpp
  function main (line 4) | int main()

FILE: Examples/NoModules/Chapter 04/Ex4_07.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 04/Ex4_08.cpp
  function main (line 4) | int main()

FILE: Examples/NoModules/Chapter 04/Ex4_09.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 04/Ex4_09A.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 05/Ex5_01.cpp
  function main (line 4) | int main()

FILE: Examples/NoModules/Chapter 05/Ex5_02.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 05/Ex5_03.cpp
  function main (line 6) | int main()

FILE: Examples/NoModules/Chapter 05/Ex5_03A.cpp
  function main (line 6) | int main()

FILE: Examples/NoModules/Chapter 05/Ex5_04.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 05/Ex5_04A.cpp
  function main (line 6) | int main()

FILE: Examples/NoModules/Chapter 05/Ex5_05.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 05/Ex5_06.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 05/Ex5_07.cpp
  function main (line 6) | int main()

FILE: Examples/NoModules/Chapter 05/Ex5_07A.cpp
  function main (line 7) | int main()

FILE: Examples/NoModules/Chapter 05/Ex5_08.cpp
  function main (line 6) | int main()

FILE: Examples/NoModules/Chapter 05/Ex5_09.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 05/Ex5_10.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 05/Ex5_11.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 05/Ex5_12.cpp
  function main (line 11) | int main()

FILE: Examples/NoModules/Chapter 05/Ex5_12A.cpp
  function main (line 11) | int main()

FILE: Examples/NoModules/Chapter 05/Ex5_13.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 05/Ex5_14.cpp
  function main (line 9) | int main()

FILE: Examples/NoModules/Chapter 05/Ex5_15.cpp
  function main (line 6) | int main()

FILE: Examples/NoModules/Chapter 06/Ex6_01.cpp
  function main (line 4) | int main()

FILE: Examples/NoModules/Chapter 06/Ex6_02.cpp
  function main (line 6) | int main()

FILE: Examples/NoModules/Chapter 06/Ex6_03.cpp
  function main (line 4) | int main()

FILE: Examples/NoModules/Chapter 06/Ex6_04.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 06/Ex6_05.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 06/Ex6_06.cpp
  function main (line 6) | int main()

FILE: Examples/NoModules/Chapter 06/Ex6_07.cpp
  function main (line 8) | int main()

FILE: Examples/NoModules/Chapter 07/Ex7_01.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 07/Ex7_01A.cpp
  function main (line 6) | int main()

FILE: Examples/NoModules/Chapter 07/Ex7_02.cpp
  function main (line 6) | int main()

FILE: Examples/NoModules/Chapter 07/Ex7_02A.cpp
  function main (line 7) | int main()

FILE: Examples/NoModules/Chapter 07/Ex7_03.cpp
  function main (line 7) | int main()

FILE: Examples/NoModules/Chapter 07/Ex7_04.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 07/Ex7_05.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 07/Ex7_06.cpp
  function main (line 6) | int main()

FILE: Examples/NoModules/Chapter 07/Ex7_07.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 08/Ex8_01.cpp
  function power (line 6) | double power(double x, int n)
  function main (line 22) | int main()

FILE: Examples/NoModules/Chapter 08/Ex8_02.cpp
  function main (line 7) | int main()
  function power (line 17) | double power(double x, int n)

FILE: Examples/NoModules/Chapter 08/Ex8_03.cpp
  function main (line 6) | int main()
  function changeIt (line 16) | double changeIt(double it)

FILE: Examples/NoModules/Chapter 08/Ex8_04.cpp
  function main (line 6) | int main()
  function changeIt (line 16) | double changeIt(double* pit)

FILE: Examples/NoModules/Chapter 08/Ex8_05.cpp
  function main (line 7) | int main()
  function average (line 14) | double average(double array[], size_t count)

FILE: Examples/NoModules/Chapter 08/Ex8_05A.cpp
  function main (line 8) | int main()
  function average10 (line 16) | double average10(double array[10])         /* The [10] does not mean wha...

FILE: Examples/NoModules/Chapter 08/Ex8_06.cpp
  function main (line 7) | int main()
  function yield (line 18) | double yield(const double array[][4], size_t size)

FILE: Examples/NoModules/Chapter 08/Ex8_06A.cpp
  function main (line 7) | int main()
  function yield (line 18) | double yield(const double array[][4], size_t size)

FILE: Examples/NoModules/Chapter 08/Ex8_07.cpp
  function main (line 7) | int main()
  function change_it_by_pointer (line 18) | void change_it_by_pointer(double* pit)
  function change_it_by_reference (line 22) | void change_it_by_reference(double& pit)

FILE: Examples/NoModules/Chapter 08/Ex8_08.cpp
  function main (line 13) | int main()
  function find_words (line 26) | void find_words(vector<string>& words, const string& text, const string&...
  function list_words (line 41) | void list_words(const vector<string>& words)

FILE: Examples/NoModules/Chapter 08/Ex8_09A.cpp
  function main (line 7) | int main()
  function average10 (line 16) | double average10(const double (&array)[10])   /* Only arrays of length 1...

FILE: Examples/NoModules/Chapter 08/Ex8_09B.cpp
  function main (line 7) | int main()
  function average10 (line 15) | double average10(const double (&array)[10])

FILE: Examples/NoModules/Chapter 08/Ex8_09C.cpp
  function main (line 7) | int main()
  function average10 (line 15) | double average10(const std::array<double,10>& array)

FILE: Examples/NoModules/Chapter 08/Ex8_10.cpp
  function double_it (line 4) | void double_it(double& it)      { it *= 2; }
  function print_it (line 5) | void print_it(const double& it) { std::cout << it << std::endl; }
  function main (line 7) | int main()

FILE: Examples/NoModules/Chapter 08/Ex8_11.cpp
  function main (line 10) | int main()
  function show_data (line 26) | void show_data(const int data[], size_t count, const std::string& title,

FILE: Examples/NoModules/Chapter 08/Ex8_12.cpp
  function main (line 4) | int  main(int argc, char* argv[])

FILE: Examples/NoModules/Chapter 08/Ex8_13.cpp
  function main (line 16) | int main()
  function show_data (line 31) | void show_data(const double data[], size_t count,

FILE: Examples/NoModules/Chapter 08/Ex8_14.cpp
  function main (line 14) | int main()
  function largest (line 29) | double largest(const double data[], size_t count)
  function largest (line 38) | double largest(const std::vector<double>& data)
  function largest (line 47) | int largest(const std::vector<int>& data)
  function largest (line 56) | std::string largest(const std::vector<std::string>& words)

FILE: Examples/NoModules/Chapter 08/Ex8_15.cpp
  function main (line 8) | int main()
  function larger (line 21) | double larger(double a, double b)

FILE: Examples/NoModules/Chapter 08/Ex8_16.cpp
  function main (line 7) | int main()
  function power (line 16) | double power(double x, int n)

FILE: Examples/NoModules/Chapter 08/Ex8_17.cpp
  function main (line 15) | int main()
  function extract_words (line 36) | void extract_words(Words& words, const std::string& text, const std::str...
  function swap (line 50) | void swap(Words& words, size_t first, size_t second)
  function sort (line 58) | void sort(Words& words)
  function sort (line 64) | void sort(Words& words, size_t start, size_t end)
  function max_word_length (line 87) | size_t max_word_length(const Words& words)
  function show_words (line 95) | void show_words(const Words& words)

FILE: Examples/NoModules/Chapter 09/Ex9_01.cpp
  function main (line 10) | int main()
  function find_last (line 30) | std::optional<size_t> find_last(const std::string& string, char to_find,

FILE: Examples/NoModules/Chapter 09/Ex9_02.cpp
  function main (line 15) | int main()
  function find_words (line 28) | void find_words(vector<string>& words, string_view text, string_view sep...
  function list_words (line 44) | void list_words(const vector<string>& words)

FILE: Examples/NoModules/Chapter 09/Ex9_03.cpp
  function main (line 23) | int main()
  function largest (line 39) | double largest(std::span<double> data)
  function largest (line 48) | int largest(std::span<int> data)
  function largest (line 57) | std::string largest(std::span<std::string> words)

FILE: Examples/NoModules/Chapter 09/Ex9_03A.cpp
  function main (line 20) | int main()
  function largest (line 36) | double largest(std::span<const double> data)
  function largest (line 45) | int largest(std::span<const int> data)
  function largest (line 54) | std::string largest(std::span<const std::string> words)

FILE: Examples/NoModules/Chapter 10/Ex10_01.cpp
  function main (line 8) | int main()
  function T (line 24) | T larger(T a, T b)

FILE: Examples/NoModules/Chapter 10/Ex10_02.cpp
  function main (line 10) | int main()
  function T (line 28) | T larger(T a, T b)
  function T (line 34) | T* larger(T* a, T* b)
  function T (line 40) | const T* larger(const std::vector<T>& data)

FILE: Examples/NoModules/Chapter 10/Ex10_03.cpp
  function larger (line 8) | auto larger(const T1& a, const T2& b)
  function main (line 13) | int main()

FILE: Examples/NoModules/Chapter 10/Ex10_03A.cpp
  function larger (line 9) | decltype(auto) larger(const T1& a, const T2& b)
  function main (line 14) | int main()

FILE: Examples/NoModules/Chapter 10/Ex10_04.cpp
  function main (line 7) | int main()
  function T (line 25) | T average(const T(&array)[N])

FILE: Examples/NoModules/Chapter 11/Ex11_06/Ex11_06.cpp
  type math (line 6) | namespace math
    function square (line 9) | auto square(const auto& x) { return x * x; }
    function pow4 (line 10) | auto pow4(const auto& x) { return square(square(x)); }
  function main (line 13) | int main()

FILE: Examples/NoModules/Chapter 11/Ex11_07/Ex11_07.cpp
  function main (line 6) | int main()

FILE: Examples/NoModules/Chapter 11/Ex11_07/math.cpp
  type math::averages (line 12) | namespace math::averages
    function arithmetic_mean (line 14) | double arithmetic_mean(std::span<const double> data)
  type math (line 29) | namespace math
    type averages (line 31) | namespace averages
      function geometric_mean (line 33) | double geometric_mean(std::span<const double> data)
  type math (line 63) | namespace math
    type averages (line 31) | namespace averages
      function geometric_mean (line 33) | double geometric_mean(std::span<const double> data)
  function quicksort (line 94) | void quicksort(std::vector<double>& data)
  function quicksort (line 100) | void quicksort(std::vector<double>& data, size_t start, size_t end)

FILE: Examples/NoModules/Chapter 11/Ex11_07/math.h
  function namespace (line 6) | namespace math

FILE: Examples/NoModules/Chapter 11/Ex11_08/Ex11_08.cpp
  function my_hypot (line 6) | auto my_hypot(const auto& x, const auto& y) // Renamed to my_hypot to av...
  function main (line 15) | int main()

FILE: Examples/NoModules/Chapter 11/Ex11_08/squaring.h
  function namespace (line 5) | namespace math        // Exports all nested declarations at once

FILE: Examples/NoModules/Chapter 12/Ex12_01/Ex12_01.cpp
  class Box (line 5) | class Box
    method Box (line 9) | Box(double length, double width, double height)
    method volume (line 18) | double volume()
  function main (line 29) | int main()

FILE: Examples/NoModules/Chapter 12/Ex12_01A/Ex12_01A.cpp
  class Box (line 5) | class Box
    method Box (line 9) | Box() = default;
    method Box (line 12) | Box(double length, double width, double height)
    method volume (line 21) | double volume()
  function main (line 32) | int main()

FILE: Examples/NoModules/Chapter 12/Ex12_02/Ex12_02.cpp
  class Box (line 9) | class Box
    method Box (line 12) | Box() = default;
  function main (line 23) | int main()

FILE: Examples/NoModules/Chapter 12/Ex12_03/Ex12_03.cpp
  class Box (line 5) | class Box
    method Box (line 8) | Box() = default;
  function main (line 19) | int main()

FILE: Examples/NoModules/Chapter 12/Ex12_04/Ex12_04.cpp
  class Cube (line 6) | class Cube
  function main (line 24) | int main()

FILE: Examples/NoModules/Chapter 12/Ex12_05/Ex12_05.cpp
  class Box (line 4) | class Box
    method Box (line 9) | Box() = default;
  function main (line 33) | int main()

FILE: Examples/NoModules/Chapter 12/Ex12_05A/Ex12_05A.cpp
  class Box (line 5) | class Box
    method Box (line 10) | Box() = default;
  function main (line 35) | int main()

FILE: Examples/NoModules/Chapter 12/Ex12_06/Box.h
  function m_height (line 18) | double m_height{ 1.0 };
  function volume (line 31) | inline double Box::volume()

FILE: Examples/NoModules/Chapter 12/Ex12_06/Ex12_06.cpp
  function main (line 10) | int main()

FILE: Examples/NoModules/Chapter 12/Ex12_06A/Box.h
  function m_height (line 16) | double m_height{ 1.0 };

FILE: Examples/NoModules/Chapter 12/Ex12_06A/Ex12_06A.cpp
  function main (line 9) | int main()

FILE: Examples/NoModules/Chapter 12/Ex12_06B/Box.h
  function class (line 7) | class Box
  function volume (line 18) | double volume() { return m_length * m_width * m_height; }
  function m_width (line 22) | double m_width{ 1.0 };

FILE: Examples/NoModules/Chapter 12/Ex12_06B/Ex12_06B.cpp
  function main (line 6) | int main()

FILE: Examples/NoModules/Chapter 12/Ex12_07/Box.h
  function getLength (line 14) | double getLength() { return m_length; }
  function getWidth (line 15) | double getWidth()  { return m_width; }
  function getHeight (line 16) | double getHeight() { return m_height; }
  function setLength (line 19) | void setLength(double length) { if (length > 0) m_length = length; }
  function setWidth (line 20) | void setWidth(double width)   { if (width > 0)  m_width  = width;  }
  function setHeight (line 21) | void setHeight(double height) { if (height > 0) m_height = height; }
  function m_height (line 26) | double m_height{1.0};

FILE: Examples/NoModules/Chapter 12/Ex12_07/Ex12_07.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 12/Ex12_08/Box.cpp
  function Box (line 18) | Box& Box::setLength(double length)
  function Box (line 23) | Box& Box::setWidth(double width)
  function Box (line 28) | Box& Box::setHeight(double height)

FILE: Examples/NoModules/Chapter 12/Ex12_08/Box.h
  function getLength (line 14) | double getLength() { return m_length; }
  function getWidth (line 15) | double getWidth()  { return m_width; }
  function getHeight (line 16) | double getHeight() { return m_height; }
  function m_height (line 26) | double m_height{1.0};

FILE: Examples/NoModules/Chapter 12/Ex12_08/Ex12_08.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 12/Ex12_09/Box.h
  function volume (line 11) | double volume() const;    // Const function to calculate the volume of a...
  function setLength (line 19) | void setLength(double length) { if (length > 0) m_length = length; }
  function setWidth (line 20) | void setWidth(double width)   { if (width > 0)  m_width  = width;  }
  function setHeight (line 21) | void setHeight(double height) { if (height > 0) m_height = height; }
  function m_height (line 26) | double m_height{1.0};

FILE: Examples/NoModules/Chapter 12/Ex12_09/Ex12_09.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 12/Ex12_10/Box.h
  function class (line 6) | class Box
  function width (line 17) | double& width()  { std::cout << "non-const overload called\n"; return m_...
  function height (line 18) | double& height() { std::cout << "non-const overload called\n"; return m_...
  function m_width (line 32) | double m_width {1.0};

FILE: Examples/NoModules/Chapter 12/Ex12_10/Ex12_10.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 12/Ex12_11/Box.h
  function volume (line 11) | double volume() const;      // Function to calculate the volume of a box
  function setLength (line 20) | void setLength(double length) { if (length > 0) m_length = length; }
  function setWidth (line 21) | void setWidth(double width)   { if (width > 0)  m_width  = width;  }
  function setHeight (line 22) | void setHeight(double height) { if (height > 0) m_height = height; }
  function m_height (line 27) | double m_height{1.0};

FILE: Examples/NoModules/Chapter 12/Ex12_11/Ex12_11.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 12/Ex12_12/Box.h
  function class (line 4) | class Box

FILE: Examples/NoModules/Chapter 12/Ex12_12/Ex12_12.cpp
  function main (line 6) | int main()
  function surfaceArea (line 23) | double surfaceArea(const Box& box)

FILE: Examples/NoModules/Chapter 12/Ex12_13/Box.h
  function m_height (line 18) | double m_height {1.0};

FILE: Examples/NoModules/Chapter 12/Ex12_13/Ex12_13.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 12/Ex12_14/Box.h
  function m_height (line 19) | double m_height {1.0};

FILE: Examples/NoModules/Chapter 12/Ex12_14/Ex12_14.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 12/Ex12_15/CylindricalBox.h
  function std (line 12) | static inline const std::string_view s_default_material { "paperboard" };

FILE: Examples/NoModules/Chapter 12/Ex12_15/Ex12_15.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 12/Ex12_16/Box.h
  function getObjectCount (line 15) | static size_t getObjectCount() { return s_object_count; }
  function m_height (line 20) | double m_height {1.0};

FILE: Examples/NoModules/Chapter 12/Ex12_16/Ex12_16.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 12/Ex12_17/Box.h
  function compare (line 19) | int compare(const Box& box) const
  function m_height (line 34) | double m_height {1.0};

FILE: Examples/NoModules/Chapter 12/Ex12_17/Ex12_17.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 12/Ex12_17/Package.h
  function class (line 6) | class Package

FILE: Examples/NoModules/Chapter 12/Ex12_17/RandomBoxes.h
  function dimLimit (line 20) | const int dimLimit{ 100 };          // Upper limit on Box dimensions

FILE: Examples/NoModules/Chapter 12/Ex12_17/Truckload.cpp
  function SharedBox (line 50) | SharedBox Truckload::getFirstBox()
  function SharedBox (line 57) | SharedBox Truckload::getNextBox()

FILE: Examples/NoModules/Chapter 12/Ex12_17/Truckload.h
  function class (line 11) | class Truckload

FILE: Examples/NoModules/Chapter 12/Ex12_18/Box.h
  function compare (line 19) | int compare(const Box& box) const
  function m_height (line 34) | double m_height {1.0};

FILE: Examples/NoModules/Chapter 12/Ex12_18/Ex12_18.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 12/Ex12_18/RandomBoxes.h
  function dimLimit (line 20) | const int dimLimit{ 100 };          // Upper limit on Box dimensions

FILE: Examples/NoModules/Chapter 12/Ex12_18/Truckload.cpp
  function SharedBox (line 49) | SharedBox Truckload::getFirstBox()
  function SharedBox (line 56) | SharedBox Truckload::getNextBox()

FILE: Examples/NoModules/Chapter 12/Ex12_18/Truckload.h
  function m_box (line 35) | Package(SharedBox box) : m_box{ box }, m_next{ nullptr } {} // Constructor
  function Package (line 39) | Package* m_head {}
  function Package (line 40) | Package* m_tail {}
  function Package (line 41) | Package* m_current {}

FILE: Examples/NoModules/Chapter 13/Ex13_01/Box.h
  function class (line 4) | class Box
  function operator (line 18) | bool operator<(const Box& aBox) const     // Less-than operator
  function m_width (line 23) | double m_width {1.0};

FILE: Examples/NoModules/Chapter 13/Ex13_01/Ex13_01.cpp
  function main (line 6) | int main()

FILE: Examples/NoModules/Chapter 13/Ex13_02/Box.h
  function class (line 4) | class Box
  function operator (line 18) | bool operator<(const Box& aBox) const    // Less-than operator
  function m_height (line 28) | double m_height{ 1.0 };
  function value (line 32) | inline bool Box::operator<(double value) const

FILE: Examples/NoModules/Chapter 13/Ex13_02/Ex13_02.cpp
  function show (line 8) | void show(const Box& box)
  function main (line 14) | int main()

FILE: Examples/NoModules/Chapter 13/Ex13_03/Box.h
  function class (line 6) | class Box
  function otherBox (line 29) | bool operator==(const Box& otherBox) const
  function m_width (line 38) | double m_width{ 1.0 };

FILE: Examples/NoModules/Chapter 13/Ex13_03/Ex13_03.cpp
  function show (line 8) | void show(const Box& box)
  function show (line 13) | void show(const Box& box1, std::string_view relationship, const Box& box2)
  function main (line 18) | int main()

FILE: Examples/NoModules/Chapter 13/Ex13_03A/Box.h
  function class (line 6) | class Box
  function m_width (line 33) | double m_width{ 1.0 };

FILE: Examples/NoModules/Chapter 13/Ex13_03A/Ex13_03A.cpp
  function show (line 8) | void show(const Box& box)
  function show (line 13) | void show(const Box& box1, std::string_view relationship, const Box& box2)
  function main (line 18) | int main()

FILE: Examples/NoModules/Chapter 13/Ex13_04/Box.h
  function class (line 8) | class Box
  function m_height (line 36) | double m_height{ 1.0 };

FILE: Examples/NoModules/Chapter 13/Ex13_04/Ex13_04.cpp
  function main (line 8) | int main()

FILE: Examples/NoModules/Chapter 13/Ex13_05/Box.cpp
  function Box (line 11) | Box Box::operator+(const Box& aBox) const

FILE: Examples/NoModules/Chapter 13/Ex13_05/Box.h
  function m_height (line 34) | double m_height {1.0};

FILE: Examples/NoModules/Chapter 13/Ex13_05/Ex13_05.cpp
  function createUniformPseudoRandomNumberGenerator (line 10) | auto createUniformPseudoRandomNumberGenerator(double max)
  function main (line 18) | int main()

FILE: Examples/NoModules/Chapter 13/Ex13_06/Box.cpp
  function Box (line 12) | Box& Box::operator+=(const Box& aBox)
  function Box (line 22) | Box Box::operator+(const Box& aBox) const

FILE: Examples/NoModules/Chapter 13/Ex13_06/Box.h
  function m_height (line 35) | double m_height {1.0};

FILE: Examples/NoModules/Chapter 13/Ex13_06/Ex13_06.cpp
  function createUniformPseudoRandomNumberGenerator (line 10) | auto createUniformPseudoRandomNumberGenerator(double max)
  function main (line 18) | int main()

FILE: Examples/NoModules/Chapter 13/Ex13_07/Ex13_07.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 13/Ex13_07/Integer.h
  function class (line 4) | class Integer

FILE: Examples/NoModules/Chapter 13/Ex13_08/Box.h
  function class (line 8) | class Box
  function m_height (line 41) | double m_height{ 1.0 };

FILE: Examples/NoModules/Chapter 13/Ex13_08/Ex13_08.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 13/Ex13_09/Box.h
  function m_width (line 40) | double m_width{ 1.0 };

FILE: Examples/NoModules/Chapter 13/Ex13_09/Ex13_09.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 13/Ex13_10/Box.h
  function compare (line 19) | int compare(const Box& box) const
  function m_height (line 34) | double m_height {1.0};

FILE: Examples/NoModules/Chapter 13/Ex13_10/Ex13_10.cpp
  function createUniformPseudoRandomNumberGenerator (line 9) | auto createUniformPseudoRandomNumberGenerator(double max)
  function main (line 17) | int main()

FILE: Examples/NoModules/Chapter 13/Ex13_10/Truckload.cpp
  class Truckload::Package (line 8) | class Truckload::Package
    method Package (line 14) | Package(SharedBox box) : m_box{ box }, m_next{ nullptr } {}
  function SharedBox (line 51) | SharedBox Truckload::Iterator::getFirstBox()
  function SharedBox (line 59) | SharedBox Truckload::Iterator::getNextBox()
  function SharedBox (line 109) | SharedBox Truckload::operator[](size_t index) const

FILE: Examples/NoModules/Chapter 13/Ex13_10/Truckload.h
  function class (line 12) | class Truckload
  function explicit (line 52) | explicit Iterator(Package* head) : m_head{ head }, m_current{ nullptr } {}

FILE: Examples/NoModules/Chapter 13/Ex13_11/Box.h
  function compare (line 20) | int compare(const Box& box) const
  function m_height (line 42) | double m_height {1.0};

FILE: Examples/NoModules/Chapter 13/Ex13_11/Ex13_11.cpp
  function createUniformPseudoRandomNumberGenerator (line 21) | auto createUniformPseudoRandomNumberGenerator(double max)
  function main (line 29) | int main()

FILE: Examples/NoModules/Chapter 13/Ex13_11/Truckload.cpp
  class Truckload::Package (line 8) | class Truckload::Package
    method Package (line 14) | Package(SharedBox box) : m_box{ box }, m_next{ nullptr } {}
  function SharedBox (line 51) | SharedBox Truckload::Iterator::getFirstBox()
  function SharedBox (line 59) | SharedBox Truckload::Iterator::getNextBox()
  function SharedBox (line 109) | SharedBox& Truckload::operator[](size_t index) const

FILE: Examples/NoModules/Chapter 13/Ex13_11/Truckload.h
  function class (line 12) | class Truckload
  function explicit (line 57) | explicit Iterator(Package* head) : m_head{ head }, m_current{ nullptr } {}

FILE: Examples/NoModules/Chapter 13/Ex13_12/Ex13_12.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 13/Ex13_12/Message.cpp
  function Message (line 3) | Message& Message::operator=(const Message& message)

FILE: Examples/NoModules/Chapter 13/Ex13_12/Message.h
  function class (line 6) | class Message

FILE: Examples/NoModules/Chapter 13/Ex13_12A/Ex13_12A.cpp
  function main (line 6) | int main()

FILE: Examples/NoModules/Chapter 13/Ex13_12A/Message.cpp
  function Message (line 8) | Message& Message::operator=(const Message& message)

FILE: Examples/NoModules/Chapter 13/Ex13_12A/Message.h
  function class (line 6) | class Message

FILE: Examples/NoModules/Chapter 13/Ex13_12B/Ex13_12B.cpp
  function main (line 10) | int main()

FILE: Examples/NoModules/Chapter 13/Ex13_12B/Message.cpp
  function Message (line 10) | Message& Message::operator=(const Message& message)

FILE: Examples/NoModules/Chapter 13/Ex13_12B/Message.h
  function class (line 6) | class Message
  function swap (line 27) | inline void swap(Message& one, Message& other) noexcept

FILE: Examples/NoModules/Chapter 14/Ex14_01/Box.h
  function class (line 5) | class Box
  function m_width (line 22) | double m_width  {1.0};

FILE: Examples/NoModules/Chapter 14/Ex14_01/Carton.h
  function class (line 9) | class Carton : public Box

FILE: Examples/NoModules/Chapter 14/Ex14_01/Ex14_01.cpp
  function main (line 6) | int main()

FILE: Examples/NoModules/Chapter 14/Ex14_01A/Box.h
  function class (line 5) | class Box
  function m_width (line 22) | double m_width  {1.0};

FILE: Examples/NoModules/Chapter 14/Ex14_01A/Carton.h
  function class (line 9) | class Carton : private Box

FILE: Examples/NoModules/Chapter 14/Ex14_01A/Ex14_01A.cpp
  function main (line 6) | int main()

FILE: Examples/NoModules/Chapter 14/Ex14_02/Box.h
  function class (line 8) | class Box
  function explicit (line 15) | explicit Box(double side) : Box{side, side, side}
  function m_height (line 30) | double m_height {1.0};

FILE: Examples/NoModules/Chapter 14/Ex14_02/Carton.h
  function class (line 9) | class Carton : public Box

FILE: Examples/NoModules/Chapter 14/Ex14_02/Ex14_02.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 14/Ex14_03/Box.h
  function class (line 8) | class Box
  function explicit (line 15) | explicit Box(double side) : Box{side, side, side}
  function m_height (line 34) | double m_height {1.0};

FILE: Examples/NoModules/Chapter 14/Ex14_03/Carton.h
  function class (line 9) | class Carton : public Box
  function m_material (line 25) | Carton(const Carton& carton) : m_material {carton.m_material}

FILE: Examples/NoModules/Chapter 14/Ex14_03/Ex14_03.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 14/Ex14_04/Box.h
  function class (line 8) | class Box
  function explicit (line 15) | explicit Box(double side) : Box{side, side, side}
  function m_height (line 30) | double m_height {1.0};

FILE: Examples/NoModules/Chapter 14/Ex14_04/Carton.h
  function class (line 9) | class Carton : public Box

FILE: Examples/NoModules/Chapter 14/Ex14_04/Ex14_04.cpp
  function main (line 6) | int main()

FILE: Examples/NoModules/Chapter 14/Ex14_04A/Box.h
  function class (line 8) | class Box
  function explicit (line 15) | explicit Box(double side) : Box{side, side, side}
  function m_height (line 30) | double m_height {1.0};

FILE: Examples/NoModules/Chapter 14/Ex14_04A/Carton.h
  function class (line 9) | class Carton : public Box

FILE: Examples/NoModules/Chapter 14/Ex14_04A/Ex14_04A.cpp
  function main (line 10) | int main()

FILE: Examples/NoModules/Chapter 14/Ex14_04B/Box.h
  function class (line 8) | class Box
  function explicit (line 15) | explicit Box(double side) : Box{side, side, side}
  function m_height (line 30) | double m_height {1.0};

FILE: Examples/NoModules/Chapter 14/Ex14_04B/Carton.h
  function class (line 9) | class Carton : public Box

FILE: Examples/NoModules/Chapter 14/Ex14_04B/Ex14_04B.cpp
  function main (line 10) | int main()

FILE: Examples/NoModules/Chapter 14/Ex14_04C/Box.h
  function class (line 8) | class Box
  function explicit (line 15) | explicit Box(double side) : Box{side, side, side}
  function m_height (line 30) | double m_height {1.0};

FILE: Examples/NoModules/Chapter 14/Ex14_04C/Carton.h
  function class (line 9) | class Carton : public Box

FILE: Examples/NoModules/Chapter 14/Ex14_04C/Ex14_04C.cpp
  function main (line 10) | int main()

FILE: Examples/NoModules/Chapter 14/Ex14_05/Box.h
  function class (line 8) | class Box
  function explicit (line 15) | explicit Box(double side) : Box{side, side, side}
  function m_height (line 30) | double m_height {1.0};

FILE: Examples/NoModules/Chapter 14/Ex14_05/Carton.h
  function class (line 9) | class Carton : public Box

FILE: Examples/NoModules/Chapter 14/Ex14_05/Ex14_05.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 14/Ex14_06/Box.h
  function class (line 8) | class Box
  function explicit (line 15) | explicit Box(double side) : Box{side, side, side}
  function m_height (line 37) | double m_height {1.0};

FILE: Examples/NoModules/Chapter 14/Ex14_06/Carton.h
  function class (line 9) | class Carton : public Box
  function Box (line 25) | Carton(const Carton& carton) : Box{ carton }, m_material{ carton.m_mater...

FILE: Examples/NoModules/Chapter 14/Ex14_06/Ex14_06.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 14/Ex14_07/Box.h
  function class (line 8) | class Box
  function explicit (line 15) | explicit Box(double side) : Box{side, side, side}
  function m_height (line 30) | double m_height {1.0};

FILE: Examples/NoModules/Chapter 14/Ex14_07/Carton.h
  function class (line 9) | class Carton : public Box
  function m_density (line 54) | double m_density {0.2};       // Material density in pounds/cubic inch

FILE: Examples/NoModules/Chapter 14/Ex14_07/Ex14_07.cpp
  function main (line 7) | int main()

FILE: Examples/NoModules/Chapter 14/Ex14_07/FoodContainer.h
  function class (line 8) | class FoodContainer
  function volume (line 26) | double volume {}
  function density (line 27) | double density {0.03}

FILE: Examples/NoModules/Chapter 14/Ex14_07A/Box.h
  function class (line 8) | class Box
  function explicit (line 15) | explicit Box(double side) : Box{side, side, side}
  function m_height (line 30) | double m_height {1.0};

FILE: Examples/NoModules/Chapter 14/Ex14_07A/Carton.h
  function class (line 9) | class Carton : public Box
  function m_density (line 54) | double m_density {0.2};       // Material density in pounds/cubic inch

FILE: Examples/NoModules/Chapter 14/Ex14_07A/Ex14_07A.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 14/Ex14_07A/FoodContainer.h
  function class (line 8) | class FoodContainer
  function volume (line 26) | double volume {}
  function density (line 27) | double density {0.03}

FILE: Examples/NoModules/Chapter 14/Ex14_07B/Box.h
  function class (line 8) | class Box
  function explicit (line 15) | explicit Box(double side) : Box{side, side, side}
  function m_height (line 30) | double m_height {1.0};

FILE: Examples/NoModules/Chapter 14/Ex14_07B/Carton.h
  function class (line 9) | class Carton : public Box
  function m_density (line 54) | double m_density {0.2};       // Material density in pounds/cubic inch

FILE: Examples/NoModules/Chapter 14/Ex14_07B/Ex14_07B.cpp
  function main (line 6) | int main()

FILE: Examples/NoModules/Chapter 14/Ex14_07B/FoodContainer.h
  function class (line 8) | class FoodContainer
  function volume (line 26) | double volume {}
  function density (line 27) | double density {0.03}

FILE: Examples/NoModules/Chapter 15/Ex15_01/Box.h
  function class (line 5) | class Box

FILE: Examples/NoModules/Chapter 15/Ex15_01/Ex15_01.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 15/Ex15_01/ToughPack.h
  function class (line 6) | class ToughPack : public Box

FILE: Examples/NoModules/Chapter 15/Ex15_02/Box.h
  function class (line 5) | class Box

FILE: Examples/NoModules/Chapter 15/Ex15_02/Carton.h
  function class (line 8) | class Carton : public Box

FILE: Examples/NoModules/Chapter 15/Ex15_02/Ex15_02.cpp
  function main (line 7) | int main()

FILE: Examples/NoModules/Chapter 15/Ex15_02/ToughPack.h
  function class (line 6) | class ToughPack : public Box

FILE: Examples/NoModules/Chapter 15/Ex15_03/Box.h
  function class (line 5) | class Box

FILE: Examples/NoModules/Chapter 15/Ex15_03/Carton.h
  function class (line 8) | class Carton : public Box

FILE: Examples/NoModules/Chapter 15/Ex15_03/Ex15_03.cpp
  function main (line 7) | int main()

FILE: Examples/NoModules/Chapter 15/Ex15_03/ToughPack.h
  function class (line 6) | class ToughPack : public Box

FILE: Examples/NoModules/Chapter 15/Ex15_04/Box.h
  function class (line 5) | class Box

FILE: Examples/NoModules/Chapter 15/Ex15_04/Carton.h
  function class (line 8) | class Carton : public Box

FILE: Examples/NoModules/Chapter 15/Ex15_04/Ex15_04.cpp
  function main (line 7) | int main()

FILE: Examples/NoModules/Chapter 15/Ex15_04/ToughPack.h
  function class (line 6) | class ToughPack : public Box

FILE: Examples/NoModules/Chapter 15/Ex15_05/Box.h
  function class (line 5) | class Box

FILE: Examples/NoModules/Chapter 15/Ex15_05/Carton.h
  function class (line 8) | class Carton : public Box

FILE: Examples/NoModules/Chapter 15/Ex15_05/Ex15_05.cpp
  function showVolume (line 8) | void showVolume(const Box& box)
  function main (line 13) | int main()

FILE: Examples/NoModules/Chapter 15/Ex15_05/ToughPack.h
  function class (line 6) | class ToughPack : public Box

FILE: Examples/NoModules/Chapter 15/Ex15_06/Box.h
  function class (line 5) | class Box

FILE: Examples/NoModules/Chapter 15/Ex15_06/Carton.h
  function class (line 8) | class Carton : public Box

FILE: Examples/NoModules/Chapter 15/Ex15_06/Ex15_06.cpp
  function main (line 9) | int main()

FILE: Examples/NoModules/Chapter 15/Ex15_06/ToughPack.h
  function class (line 6) | class ToughPack : public Box

FILE: Examples/NoModules/Chapter 15/Ex15_07/Box.h
  function class (line 5) | class Box

FILE: Examples/NoModules/Chapter 15/Ex15_07/Carton.h
  function class (line 8) | class Carton : public Box

FILE: Examples/NoModules/Chapter 15/Ex15_07/Ex15_07.cpp
  function main (line 9) | int main()

FILE: Examples/NoModules/Chapter 15/Ex15_07/ToughPack.h
  function class (line 6) | class ToughPack : public Box

FILE: Examples/NoModules/Chapter 15/Ex15_07A/Box.h
  function class (line 5) | class Box

FILE: Examples/NoModules/Chapter 15/Ex15_07A/Carton.h
  function class (line 8) | class Carton : public Box

FILE: Examples/NoModules/Chapter 15/Ex15_07A/Ex15_07A.cpp
  function main (line 9) | int main()

FILE: Examples/NoModules/Chapter 15/Ex15_07A/ToughPack.h
  function class (line 6) | class ToughPack : public Box

FILE: Examples/NoModules/Chapter 15/Ex15_08/Box.h
  function class (line 5) | class Box
  function virtual (line 13) | virtual ~Box()

FILE: Examples/NoModules/Chapter 15/Ex15_08/Ex14_08.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 15/Ex15_08/ToughPack.h
  function class (line 6) | class ToughPack : public Box
  function virtual (line 15) | virtual ~ToughPack()

FILE: Examples/NoModules/Chapter 15/Ex15_09/Box.h
  function class (line 5) | class Box

FILE: Examples/NoModules/Chapter 15/Ex15_09/Carton.h
  function class (line 8) | class Carton : public Box

FILE: Examples/NoModules/Chapter 15/Ex15_09/Ex15_09.cpp
  class NonPolyBase (line 8) | class NonPolyBase {}
  class NonPolyDerived (line 9) | class NonPolyDerived : public NonPolyBase {}
  function main (line 14) | int main()
  function Box (line 48) | Box& getSomeBox()
  function NonPolyBase (line 54) | NonPolyBase& getSomeNonPoly()

FILE: Examples/NoModules/Chapter 15/Ex15_10/Box.h
  function class (line 5) | class Box

FILE: Examples/NoModules/Chapter 15/Ex15_10/Carton.h
  function class (line 8) | class Carton : public Box

FILE: Examples/NoModules/Chapter 15/Ex15_10/Ex15_10.cpp
  function main (line 7) | int main()

FILE: Examples/NoModules/Chapter 15/Ex15_10/ToughPack.h
  function class (line 6) | class ToughPack : public Box

FILE: Examples/NoModules/Chapter 15/Ex15_11/Box.h
  function class (line 6) | class Box : public Vessel

FILE: Examples/NoModules/Chapter 15/Ex15_11/Can.h
  function class (line 8) | class Can : public Vessel

FILE: Examples/NoModules/Chapter 15/Ex15_11/Carton.h
  function class (line 8) | class Carton : public Box

FILE: Examples/NoModules/Chapter 15/Ex15_11/Ex15_11.cpp
  function main (line 9) | int main()

FILE: Examples/NoModules/Chapter 15/Ex15_11/ToughPack.h
  function class (line 6) | class ToughPack : public Box

FILE: Examples/NoModules/Chapter 15/Ex15_11/Vessel.h
  function class (line 5) | class Vessel

FILE: Examples/NoModules/Chapter 16/Ex16_01/Ex16_01.cpp
  function main (line 4) | int main()

FILE: Examples/NoModules/Chapter 16/Ex16_02/Ex16_02.cpp
  function main (line 7) | int main()
  function trySomething (line 23) | void trySomething(int i)

FILE: Examples/NoModules/Chapter 16/Ex16_02/Troubles.h
  function class (line 7) | class Trouble

FILE: Examples/NoModules/Chapter 16/Ex16_03/Ex16_03.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 16/Ex16_03/Troubles.h
  function class (line 7) | class Trouble
  function class (line 21) | class MoreTrouble : public Trouble
  function class (line 30) | class BigTrouble : public MoreTrouble

FILE: Examples/NoModules/Chapter 16/Ex16_04/Ex16_04.cpp
  function main (line 6) | int main()

FILE: Examples/NoModules/Chapter 16/Ex16_04/Troubles.h
  function class (line 7) | class Trouble
  function class (line 21) | class MoreTrouble : public Trouble
  function class (line 30) | class BigTrouble : public MoreTrouble

FILE: Examples/NoModules/Chapter 16/Ex16_05/Ex16_05.cpp
  function main (line 6) | int main()

FILE: Examples/NoModules/Chapter 16/Ex16_05/Troubles.h
  function class (line 7) | class Trouble
  function class (line 21) | class MoreTrouble : public Trouble
  function class (line 30) | class BigTrouble : public MoreTrouble

FILE: Examples/NoModules/Chapter 16/Ex16_06/Ex16_06.cpp
  function main (line 6) | int main()

FILE: Examples/NoModules/Chapter 16/Ex16_06/Troubles.h
  function class (line 7) | class Trouble
  function class (line 21) | class MoreTrouble : public Trouble
  function class (line 30) | class BigTrouble : public MoreTrouble

FILE: Examples/NoModules/Chapter 16/Ex16_07/Ex16_07.cpp
  function main (line 9) | int main()
  function computeValue (line 31) | double computeValue(size_t x)

FILE: Examples/NoModules/Chapter 16/Ex16_07/Troubles.h
  function class (line 7) | class Trouble
  function class (line 21) | class MoreTrouble : public Trouble
  function class (line 30) | class BigTrouble : public MoreTrouble

FILE: Examples/NoModules/Chapter 16/Ex16_07A/Ex16_07A.cpp
  function main (line 9) | int main()
  function computeValue (line 40) | double computeValue(size_t x)

FILE: Examples/NoModules/Chapter 16/Ex16_07A/Troubles.h
  function class (line 7) | class Trouble
  function class (line 21) | class MoreTrouble : public Trouble
  function class (line 30) | class BigTrouble : public MoreTrouble

FILE: Examples/NoModules/Chapter 16/Ex16_07B/DoubleArrayRAII.h
  function new (line 10) | new double[size] } {}
  function noexcept (line 22) | double& operator[](size_t index) noexcept { return m_resource[index]; }
  function const (line 23) | const double& operator[](size_t index) const noexcept { return m_resourc...

FILE: Examples/NoModules/Chapter 16/Ex16_07B/Ex16_07B.cpp
  function main (line 10) | int main()
  function computeValue (line 32) | double computeValue(size_t x)

FILE: Examples/NoModules/Chapter 16/Ex16_07B/Troubles.h
  function class (line 7) | class Trouble
  function class (line 21) | class MoreTrouble : public Trouble
  function class (line 30) | class BigTrouble : public MoreTrouble

FILE: Examples/NoModules/Chapter 16/Ex16_07C/Ex16_07C.cpp
  function main (line 13) | int main()
  function computeValues (line 25) | std::unique_ptr<double[]> computeValues(size_t howMany)
  function computeValue (line 33) | double computeValue(size_t x)

FILE: Examples/NoModules/Chapter 16/Ex16_07C/Troubles.h
  function class (line 7) | class Trouble
  function class (line 21) | class MoreTrouble : public Trouble
  function class (line 30) | class BigTrouble : public MoreTrouble

FILE: Examples/NoModules/Chapter 16/Ex16_07D/Ex16_07D.cpp
  function main (line 13) | int main()
  function computeValues (line 25) | std::vector<double> computeValues(size_t howMany)
  function computeValue (line 33) | double computeValue(size_t x)

FILE: Examples/NoModules/Chapter 16/Ex16_07D/Troubles.h
  function class (line 7) | class Trouble
  function class (line 21) | class MoreTrouble : public Trouble
  function class (line 30) | class BigTrouble : public MoreTrouble

FILE: Examples/NoModules/Chapter 16/Ex16_09/Box.h
  function class (line 6) | class Box
  function m_width (line 18) | double m_width{ 1.0 };

FILE: Examples/NoModules/Chapter 16/Ex16_09/DimensionError.h
  function class (line 7) | class DimensionError : public std::out_of_range

FILE: Examples/NoModules/Chapter 16/Ex16_09/Ex16_09.cpp
  function main (line 6) | int main()

FILE: Examples/NoModules/Chapter 17/Ex17_01/Array.h
  function new (line 31) | new T[size] {}
  function m_size (line 31) | m_size {size}

FILE: Examples/NoModules/Chapter 17/Ex17_01/Box.h
  function class (line 4) | class Box

FILE: Examples/NoModules/Chapter 17/Ex17_01/Ex17_01.cpp
  function main (line 7) | int main()

FILE: Examples/NoModules/Chapter 17/Ex17_01A/Array.h
  function new (line 32) | new T[size] {}
  function m_size (line 32) | m_size {size}

FILE: Examples/NoModules/Chapter 17/Ex17_01A/Box.h
  function class (line 4) | class Box

FILE: Examples/NoModules/Chapter 17/Ex17_01A/Ex17_01A.cpp
  function main (line 7) | int main()

FILE: Examples/NoModules/Chapter 17/Ex17_02/Array.h
  function new (line 28) | new T[size] {}
  function m_size (line 28) | m_size{ size }

FILE: Examples/NoModules/Chapter 17/Ex17_02/Box.h
  function class (line 4) | class Box

FILE: Examples/NoModules/Chapter 17/Ex17_02/Ex17_02.cpp
  function main (line 8) | int main()

FILE: Examples/NoModules/Chapter 17/Ex17_02A/Array.h
  function new (line 28) | new T[size] {}
  function m_size (line 28) | m_size{ size }
  function actualIndex (line 49) | const int actualIndex{ index - startIndex };

FILE: Examples/NoModules/Chapter 17/Ex17_02A/Box.h
  function class (line 4) | class Box

FILE: Examples/NoModules/Chapter 17/Ex17_02A/Ex17_02A.cpp
  function main (line 10) | int main()

FILE: Examples/NoModules/Chapter 17/Ex17_03/Array.h
  function new (line 30) | new T[size] {}
  function m_size (line 30) | m_size {size}

FILE: Examples/NoModules/Chapter 17/Ex17_03/Box.h
  function class (line 4) | class Box

FILE: Examples/NoModules/Chapter 17/Ex17_03/Ex17_03.cpp
  function main (line 7) | int main()

FILE: Examples/NoModules/Chapter 17/Ex17_04/Ex17_04.cpp
  function main (line 6) | int main()

FILE: Examples/NoModules/Chapter 17/Ex17_04/Stack.h
  function Node (line 29) | Node* m_next{}
  function Node (line 32) | Node* m_head{}
  function Node (line 42) | Node* oldNode {stack.m_head};      // Points to the top node of the orig...
  function Node (line 78) | Node* node{ new Node{item} }
  function T (line 91) | T item {m_head->m_item};     // Save the T value to return later

FILE: Examples/NoModules/Chapter 17/Ex17_04A/Ex17_04A.cpp
  function main (line 7) | int main()

FILE: Examples/NoModules/Chapter 17/Ex17_04A/Stack.h
  function Node (line 30) | Node* m_next{}
  function Node (line 33) | Node* m_head{}
  function Node (line 43) | Node* oldNode {stack.m_head};      // Points to the top node of the orig...
  function Node (line 74) | Node* node{ new Node{item} }
  function T (line 87) | T item {m_head->m_item};     // Save the T value to return later

FILE: Examples/NoModules/Chapter 17/Ex17_04B/Ex17_04B.cpp
  function main (line 9) | int main()

FILE: Examples/NoModules/Chapter 17/Ex17_04B/Stack.h
  function Node (line 53) | Node* oldNode {stack.m_head.get()}; // Points to the top node of the ori...
  function node (line 78) | auto node{ std::make_unique<Node>(item) }; // Create the new node
  function next (line 91) | auto next {std::move(m_head->m_next)}; // Save pointer to the next node

FILE: Examples/NoModules/Chapter 17/Ex17_05/Ex17_05A.cpp
  class Outer (line 4) | class Outer
    class Nested (line 7) | class Nested { /* ... */ }
  function someFunction (line 14) | void someFunction() { /*typename*/ Outer<T>::Nested* nested; /* ... */ }

FILE: Examples/NoModules/Chapter 17/Ex17_05/Ex17_05B.cpp
  class Outer (line 6) | class Outer
    class Nested (line 9) | class Nested { /* ... */ }
  function someOtherFunction (line 14) | void someOtherFunction()

FILE: Examples/NoModules/Chapter 17/Ex17_05/Ex17_05C.cpp
  class Outer (line 7) | class Outer
    class Nested (line 10) | class Nested { /* ... */ }
  class MyClass (line 15) | class MyClass

FILE: Examples/NoModules/Chapter 17/Ex17_06/Ex17_06.cpp
  class Base (line 7) | class Base
    method baseFun (line 10) | void baseFun() { /* ... */ }
  class Derived (line 16) | class Derived : public Base<T>
  function main (line 44) | int main()

FILE: Examples/NoModules/Chapter 18/Ex18_01/Array.h
  function new (line 29) | new T[size] {}
  function m_size (line 29) | m_size {size}

FILE: Examples/NoModules/Chapter 18/Ex18_01/Ex18_01.cpp
  function buildStringArray (line 7) | Array<std::string> buildStringArray(const size_t size)
  function main (line 15) | int main()

FILE: Examples/NoModules/Chapter 18/Ex18_02/Array.h
  function new (line 30) | new T[size] {}
  function m_size (line 30) | m_size {size}

FILE: Examples/NoModules/Chapter 18/Ex18_02/Ex18_02.cpp
  function buildStringArray (line 7) | Array<std::string> buildStringArray(const size_t size)
  function main (line 15) | int main()

FILE: Examples/NoModules/Chapter 18/Ex18_03/Array.h
  function new (line 31) | new T[size] {}
  function m_size (line 31) | m_size {size}

FILE: Examples/NoModules/Chapter 18/Ex18_03/Ex18_03.cpp
  function buildStringArray (line 6) | Array<std::string> buildStringArray(const size_t size)
  function main (line 14) | int main()

FILE: Examples/NoModules/Chapter 18/Ex18_04/Array.h
  function new (line 31) | new T[size] {}
  function m_size (line 31) | m_size {size}

FILE: Examples/NoModules/Chapter 18/Ex18_04/Ex18_04.cpp
  function buildStringArray (line 6) | Array<std::string> buildStringArray(const size_t size)
  function main (line 14) | int main()

FILE: Examples/NoModules/Chapter 18/Ex18_05A/Array.h
  function new (line 42) | new T[size] {}
  function m_size (line 42) | m_size {size}

FILE: Examples/NoModules/Chapter 18/Ex18_05A/Ex18_05A.cpp
  function buildStringArray (line 6) | Array<std::string> buildStringArray(const size_t size)
  function main (line 14) | int main()

FILE: Examples/NoModules/Chapter 18/Ex18_05B/Array.h
  function new (line 41) | new T[size] {}
  function m_size (line 41) | m_size {size}

FILE: Examples/NoModules/Chapter 18/Ex18_05B/Ex18_05B.cpp
  function buildStringArray (line 8) | Array<std::string> buildStringArray(const size_t size)
  function main (line 16) | int main()

FILE: Examples/NoModules/Chapter 18/Ex18_06/Array.h
  function T (line 15) | const T&>
  function new (line 50) | new T[size] {}
  function m_size (line 50) | m_size {size}

FILE: Examples/NoModules/Chapter 18/Ex18_06/Ex18_06.cpp
  function buildStringArray (line 9) | Array<std::string> buildStringArray(const size_t size)
  function main (line 17) | int main()

FILE: Examples/NoModules/Chapter 18/Ex18_07/Array.h
  function new (line 40) | new T[size] {}
  function m_size (line 40) | m_size {size}

FILE: Examples/NoModules/Chapter 18/Ex18_07/Ex18_07.cpp
  function buildStringArray (line 9) | Array<std::string> buildStringArray(const size_t size)
  function main (line 17) | int main()

FILE: Examples/NoModules/Chapter 19/Ex19_01/Ex19_01.cpp
  function main (line 7) | int main()
  function product (line 20) | long product(long a, long b) { return a * b; }
  function sum (line 23) | long sum(long a, long b) { return a + b; }

FILE: Examples/NoModules/Chapter 19/Ex19_02/Ex19_02.cpp
  function main (line 11) | int main()
  function less (line 23) | bool less(const int& one, const int& other) { return one < other; }
  function greater (line 26) | bool greater(const T& one, const T& other) { return one > other; }
  function longer (line 28) | bool longer(const std::string& one, const std::string& other)

FILE: Examples/NoModules/Chapter 19/Ex19_02/Optimum.h
  function T (line 13) | const T* optimum{ &values[0] };

FILE: Examples/NoModules/Chapter 19/Ex19_03/Ex19_03.cpp
  function greater (line 7) | bool greater(const T& one, const T& other) { return one > other; }
  function main (line 9) | int main()

FILE: Examples/NoModules/Chapter 19/Ex19_03/Less.h
  function class (line 5) | class Less

FILE: Examples/NoModules/Chapter 19/Ex19_03/Optimum.h
  function T (line 13) | const T* optimum{ &values[0] };

FILE: Examples/NoModules/Chapter 19/Ex19_03A/Ex19_03A.cpp
  function main (line 6) | int main()

FILE: Examples/NoModules/Chapter 19/Ex19_03A/Optimum.h
  function T (line 13) | const T* optimum{ &values[0] };

FILE: Examples/NoModules/Chapter 19/Ex19_04/Ex19_04.cpp
  function main (line 7) | int main()

FILE: Examples/NoModules/Chapter 19/Ex19_04/Nearer.h
  function class (line 8) | class Nearer

FILE: Examples/NoModules/Chapter 19/Ex19_04/Optimum.h
  function T (line 13) | const T* optimum{ &values[0] };

FILE: Examples/NoModules/Chapter 19/Ex19_05/Ex19_05.cpp
  function main (line 7) | int main()

FILE: Examples/NoModules/Chapter 19/Ex19_05/Optimum.h
  function T (line 13) | const T* optimum{ &values[0] };

FILE: Examples/NoModules/Chapter 19/Ex19_05A/Ex19_05A.cpp
  function main (line 9) | int main()

FILE: Examples/NoModules/Chapter 19/Ex19_05A/Optimum.h
  function T (line 13) | const T* optimum{ &values[0] };

FILE: Examples/NoModules/Chapter 19/Ex19_06/Ex19_06.cpp
  function main (line 6) | int main()

FILE: Examples/NoModules/Chapter 19/Ex19_06/Optimum.h
  function T (line 13) | const T* optimum{ &values[0] };

FILE: Examples/NoModules/Chapter 19/Ex19_07/Ex19_07.cpp
  function main (line 6) | int main()

FILE: Examples/NoModules/Chapter 19/Ex19_07/Finder.h
  function class (line 8) | class Finder

FILE: Examples/NoModules/Chapter 19/Ex19_07/Optimum.h
  function T (line 13) | const T* optimum{ &values[0] };

FILE: Examples/NoModules/Chapter 19/Ex19_08/Ex19_08.cpp
  function less (line 7) | bool less(int x, int y) { return x < y; }
  function main (line 9) | int main()

FILE: Examples/NoModules/Chapter 20/Ex20_01/Ex20_01.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 20/Ex20_02/Ex20_02.cpp
  function main (line 6) | int main()

FILE: Examples/NoModules/Chapter 20/Ex20_03/Ex20_03.cpp
  function main (line 7) | int main()
  function printSet (line 30) | void printSet(const std::set<int>& my_set)

FILE: Examples/NoModules/Chapter 20/Ex20_04/Ex20_04.cpp
  function main (line 6) | int main()

FILE: Examples/NoModules/Chapter 20/Ex20_05/Ex20_05.cpp
  function main (line 19) | int main()
  function Words (line 38) | Words extractWords(std::string_view text, std::string_view separators)
  function WordCounts (line 56) | WordCounts countWords(const Words& words)
  function maxWordLength (line 64) | size_t maxWordLength(const WordCounts& wordCounts)
  function showWordCounts (line 72) | void showWordCounts(const WordCounts& wordCounts)

FILE: Examples/NoModules/Chapter 20/Ex20_06/Ex20_06.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 20/Ex20_07/Ex20_07.cpp
  function main (line 5) | int main()

FILE: Examples/NoModules/Chapter 20/Ex20_08/Box.h
  function class (line 5) | class Box
  function setLength (line 17) | void setLength(double length) { if (length > 0) m_length = length; }
  function setWidth (line 18) | void setWidth(double width)   { if (width > 0) m_width = width; }
  function setHeight (line 19) | void setHeight(double height) { if (height > 0) m_height = height; }
  function m_width (line 26) | double m_width{ 1.0 };

FILE: Examples/NoModules/Chapter 20/Ex20_08/Ex20_08.cpp
  function main (line 6) | int main()

FILE: Examples/NoModules/Chapter 20/Ex20_09/Ex20_09.cpp
  function main (line 7) | int main()
  function printVector (line 26) | void printVector(const std::vector<int>& v)

FILE: Examples/NoModules/Chapter 20/Ex20_10/Ex20_10.cpp
  function removeEvenNumbers (line 10) | void removeEvenNumbers(auto& numbers)    /* Correct! */
  function main (line 21) | int main()
  function fillVector_1toN (line 34) | std::vector<int> fillVector_1toN(size_t N)
  function printVector (line 42) | void printVector(std::string_view message, const std::vector<int>& numbers)

FILE: Examples/NoModules/Chapter 20/Ex20_11/Ex20_11.cpp
  function main (line 7) | int main()

FILE: Examples/NoModules/Chapter 20/Ex20_11A/Ex20_11A.cpp
  function main (line 8) | int main()

FILE: Examples/NoModules/Chapter 20/Ex20_12/Box.h
  function class (line 6) | class Box
  function m_width (line 33) | double m_width{ 1.0 };

FILE: Examples/NoModules/Chapter 20/Ex20_12/Ex20_12.cpp
  function main (line 7) | int main()

FILE: Examples/NoModules/Chapter 20/Ex20_12A/Box.h
  function class (line 6) | class Box
  function m_width (line 33) | double m_width{ 1.0 };

FILE: Examples/NoModules/Chapter 20/Ex20_12A/Ex20_12A.cpp
  function main (line 7) | int main()

FILE: Examples/NoModules/Chapter 20/Ex20_13/Ex20_13.cpp
  function main (line 10) | int main()
  function fillSet_1toN (line 24) | std::set<int> fillSet_1toN(size_t N)   // Fill a set with 1, 2, ..., N
  function printVector (line 32) | void printVector(const std::vector<int>& v)

FILE: Examples/NoModules/Chapter 20/Ex20_13A/Ex20_13A.cpp
  function main (line 11) | int main()
  function fillSet_1toN (line 24) | std::set<int> fillSet_1toN(size_t N)   // Fill a set with 1, 2, ..., N
  function printVector (line 32) | void printVector(const std::vector<int>& v)

FILE: Examples/NoModules/Chapter 20/Ex20_13B/Ex20_13B.cpp
  function main (line 12) | int main()
  function fillSet_1toN (line 25) | std::set<int> fillSet_1toN(size_t N)   // Fill a set with 1, 2, ..., N
  function printVector (line 33) | void printVector(const std::vector<int>& v)

FILE: Examples/NoModules/Chapter 20/Ex20_14/Ex20_14.cpp
  function removeEvenNumbers (line 11) | void removeEvenNumbers(std::vector<int>& numbers)
  function main (line 20) | int main()
  function fillVector_1toN (line 33) | std::vector<int> fillVector_1toN(size_t N)
  function printVector (line 41) | void printVector(std::string_view message, const std::vector<int>& numbers)

FILE: Examples/NoModules/Chapter 20/Ex20_14A/Ex20_14A.cpp
  function removeEvenNumbers (line 9) | void removeEvenNumbers(std::vector<int>& numbers)
  function main (line 14) | int main()
  function fillVector_1toN (line 27) | std::vector<int> fillVector_1toN(size_t N)
  function printVector (line 35) | void printVector(std::string_view message, const std::vector<int>& numbers)

FILE: Examples/NoModules/Chapter 20/Ex20_14B/Ex20_14B.cpp
  function removeEvenNumbers (line 14) | void removeEvenNumbers(std::vector<int>& numbers)
  function main (line 23) | int main()
  function fillVector_1toN (line 36) | std::vector<int> fillVector_1toN(size_t N)
  function printVector (line 44) | void printVector(std::string_view message, const std::vector<int>& numbers)

FILE: Examples/NoModules/Chapter 20/Ex20_15/Ex20_15.cpp
  function main (line 7) | int main()

FILE: Examples/NoModules/Chapter 20/Ex20_15A/Ex20_15A.cpp
  function main (line 7) | int main()

FILE: Examples/NoModules/Chapter 20/Ex20_16/Box.h
  function class (line 6) | class Box
  function m_width (line 33) | double m_width{ 1.0 };

FILE: Examples/NoModules/Chapter 20/Ex20_16/Ex20_16.cpp
  function main (line 11) | int main()

FILE: Examples/NoModules/Chapter 20/Ex20_17/Ex20_17.cpp
  function isEven (line 7) | bool isEven(int i) { return i % 2 == 0; }
  function squared (line 8) | int squared(int i) { return i * i; }
  function main (line 10) | int main()

FILE: Examples/NoModules/Chapter 20/Ex20_18/Ex20_18.cpp
  function isEven (line 6) | bool isEven(int i) { return i % 2 == 0; }
  function main (line 8) | int main()

FILE: Examples/NoModules/Chapter 21/Ex21_01/Ex21_01.cpp
  class MyClass (line 7) | class MyClass { /* just a dummy class */ }
  function main (line 9) | int main()

FILE: Examples/NoModules/Chapter 21/Ex21_02/Ex21_02.cpp
  function main (line 59) | int main()

FILE: Examples/NoModules/Chapter 21/Ex21_03/Array.h
  function new (line 40) | new T[size] {}
  function m_size (line 40) | m_size {size}
  function requires (line 84) | requires std::copyable<T>

FILE: Examples/NoModules/Chapter 21/Ex21_03/Ex21_03.cpp
  function main (line 8) | int main()

FILE: Examples/NoModules/Chapter 21/Ex21_04/Ex21_04.cpp
  function distanceBetween (line 10) | auto distanceBetween(Iter first, Iter last)
  function distanceBetween (line 19) | auto distanceBetween(Iter first, Iter last)
  function main (line 25) | int main()

FILE: Exercises/Modules/Chapter 01/Soln1_01.cpp
  function main (line 5) | int main()

FILE: Exercises/Modules/Chapter 01/Soln1_02.cpp
  function main (line 7) | int main()

FILE: Exercises/Modules/Chapter 02/Soln2_01A.cpp
  function main (line 16) | int main()

FILE: Exercises/Modules/Chapter 02/Soln2_01B.cpp
  function main (line 16) | int main()

FILE: Exercises/Modules/Chapter 02/Soln2_02A.cpp
  function main (line 8) | int main()

FILE: Exercises/Modules/Chapter 02/Soln2_02B.cpp
  function main (line 10) | int main()

FILE: Exercises/Modules/Chapter 02/Soln2_03.cpp
  function main (line 7) | int main()

FILE: Exercises/Modules/Chapter 02/Soln2_04.cpp
  function main (line 7) | int main()

FILE: Exercises/Modules/Chapter 02/Soln2_05.cpp
  function main (line 6) | int main()

FILE: Exercises/Modules/Chapter 02/Soln2_06.cpp
  function main (line 7) | int main()

FILE: Exercises/Modules/Chapter 02/Soln2_07.cpp
  function main (line 10) | int main()

FILE: Exercises/Modules/Chapter 02/Soln2_08.cpp
  function main (line 4) | int main()

FILE: Exercises/Modules/Chapter 03/Soln3_01.cpp
  function main (line 14) | int main()

FILE: Exercises/Modules/Chapter 03/Soln3_02.cpp
  function main (line 12) | int main()

FILE: Exercises/Modules/Chapter 03/Soln3_03.cpp
  function main (line 18) | int main()

FILE: Exercises/Modules/Chapter 03/Soln3_04.cpp
  function main (line 11) | int main()

FILE: Exercises/Modules/Chapter 03/Soln3_05.cpp
  function main (line 9) | int main()

FILE: Exercises/Modules/Chapter 03/Soln3_06.cpp
  function main (line 5) | int main()

FILE: Exercises/Modules/Chapter 04/Soln4_01.cpp
  function main (line 5) | int main()

FILE: Exercises/Modules/Chapter 04/Soln4_02.cpp
  function main (line 8) | int main()

FILE: Exercises/Modules/Chapter 04/Soln4_03.cpp
  function main (line 5) | int main()

FILE: Exercises/Modules/Chapter 04/Soln4_04.cpp
  type AcademicDegree (line 9) | enum class AcademicDegree
  function main (line 14) | int main()

FILE: Exercises/Modules/Chapter 04/Soln4_05.cpp
  function main (line 6) | int main()

FILE: Exercises/Modules/Chapter 04/Soln4_06.cpp
  function main (line 10) | int main()

FILE: Exercises/Modules/Chapter 04/Soln4_07.cpp
  function main (line 16) | int main()

FILE: Exercises/Modules/Chapter 04/Soln4_08.cpp
  function main (line 6) | int main()

FILE: Exercises/Modules/Chapter 05/Soln5_01.cpp
  function main (line 5) | int main()

FILE: Exercises/Modules/Chapter 05/Soln5_02.cpp
  function main (line 7) | int main()

FILE: Exercises/Modules/Chapter 05/Soln5_03.cpp
  function main (line 4) | int main()

FILE: Exercises/Modules/Chapter 05/Soln5_04.cpp
  function main (line 4) | int main()

FILE: Exercises/Modules/Chapter 05/Soln5_05.cpp
  function main (line 4) | int main()

FILE: Exercises/Modules/Chapter 05/Soln5_06.cpp
  function main (line 6) | int main()

FILE: Exercises/Modules/Chapter 05/Soln5_07.cpp
  function main (line 10) | int main()

FILE: Exercises/Modules/Chapter 05/Soln5_08.cpp
  function main (line 13) | int main()

FILE: Exercises/Modules/Chapter 06/Soln6_01.cpp
  function main (line 10) | int main()

FILE: Exercises/Modules/Chapter 06/Soln6_02.cpp
  function main (line 8) | int main()

FILE: Exercises/Modules/Chapter 06/Soln6_03.cpp
  function main (line 9) | int main()

FILE: Exercises/Modules/Chapter 06/Soln6_04.cpp
  function main (line 24) | int main()

FILE: Exercises/Modules/Chapter 06/Soln6_05.cpp
  function main (line 12) | int main()

FILE: Exercises/Modules/Chapter 06/Soln6_06.cpp
  function main (line 10) | int main()

FILE: Exercises/Modules/Chapter 08/Soln8_01.cpp
  function main (line 13) | int main()
  function validate_input (line 33) | int validate_input(int lower, int upper, const std::string& description)
  function year (line 47) | int year()
  function month (line 55) | int month()
  function date (line 63) | int date(int month_number, int year)
  function ending (line 83) | std::string ending(int date_day)

FILE: Exercises/Modules/Chapter 08/Soln8_02.cpp
  function main (line 11) | int main()
  function reverse (line 30) | std::string reverse(std::string str)

FILE: Exercises/Modules/Chapter 08/Soln8_03.cpp
  function main (line 4) | int main(int numArguments, char* arguments[])

FILE: Exercises/Modules/Chapter 08/Soln8_04.cpp
  function main (line 9) | int main()
  function plus (line 34) | int plus(int a, int b)
  function plus (line 40) | double plus(double x, double y)
  function plus (line 46) | std::string plus(const std::string& s1, const std::string& s2)

FILE: Exercises/Modules/Chapter 08/Soln8_05.cpp
  function main (line 24) | int main()
  function isPrime (line 56) | bool isPrime(unsigned number)
  function generateNumbers (line 73) | std::vector<unsigned> generateNumbers(unsigned to, unsigned from)
  function filterPrimeNumbers (line 82) | std::vector<unsigned> filterPrimeNumbers(const std::vector<unsigned>& nu...

FILE: Exercises/Modules/Chapter 08/Soln8_06.cpp
  function main (line 48) | int main()
  function swap (line 87) | void swap(std::vector<unsigned>& numbers, size_t first, size_t second)
  function sort (line 96) | void sort(std::vector<unsigned>& numbers, size_t start, size_t end)
  function sort (line 120) | void sort(std::vector<unsigned>& numbers)
  function getHighest (line 126) | void getHighest(const std::vector<unsigned>& sortedNumbers, unsigned(&hi...
  function getLowest (line 140) | void getLowest(const std::vector<unsigned>& sortedNumbers, unsigned(&low...
  function computeAverage (line 151) | double computeAverage(const std::vector<unsigned>& numbers)
  function computeMedian (line 162) | double computeMedian(const std::vector<unsigned>& numbers)
  function computeStandardDeviation (line 179) | double computeStandardDeviation(const std::vector<unsigned>& numbers)
  function computeVariance (line 191) | double computeVariance(const std::vector<unsigned>& numbers)
  function printNumber (line 200) | void printNumber(const std::string& label, double number)
  function printNumbers (line 212) | void printNumbers(const std::string& label, const unsigned(&numbers)[5])

FILE: Exercises/Modules/Chapter 08/Soln8_07.cpp
  function main (line 10) | int main()
  function fib (line 20) | unsigned long long fib(size_t n)

FILE: Exercises/Modules/Chapter 08/Soln8_07A.cpp
  function main (line 8) | int main()
  function fib (line 18) | unsigned long long fib(size_t n)

FILE: Exercises/Modules/Chapter 08/Soln8_08.cpp
  function main (line 8) | int main()
  function power (line 17) | long double power(double x, int n)

FILE: Exercises/Modules/Chapter 08/Soln8_09.cpp
  function main (line 8) | int main()
  function mult (line 13) | inline auto mult(long double l, long double r)
  function power (line 21) | long double power(double x, int n)

FILE: Exercises/Modules/Chapter 09/Soln9_01.cpp
  function main (line 10) | int main()
  function find_last (line 30) | std::optional<size_t> find_last(std::string_view string, char to_find,

FILE: Exercises/Modules/Chapter 09/Soln9_02.cpp
  function main (line 19) | int main()
  function show_data (line 35) | void show_data(
  function show_data (line 52) | void show_data(int data, std::string_view title, size_t width)

FILE: Exercises/Modules/Chapter 09/Soln9_03.cpp
  function main (line 18) | int main()
  function show_data (line 32) | void show_data(std::span<const double> data,
  function smallest (line 48) | std::optional<double> smallest(std::span<const double> data)
  function shift_range (line 60) | std::span<double> shift_range(std::span<double> data, double delta)
  function largest (line 67) | std::optional<double> largest(std::span<const double> data)
  function scale_range (line 79) | std::span<double> scale_range(std::span<double> data, double divisor)
  function normalize_range (line 88) | std::span<double> normalize_range(std::span<double> data)

FILE: Exercises/Modules/Chapter 09/Soln9_04.cpp
  function main (line 14) | int main()
  function largest (line 30) | std::optional<double> largest(std::span<const double> data)
  function largest (line 41) | std::optional<int> largest(std::span<const int> data)
  function largest (line 52) | std::optional<std::string> largest(std::span<const std::string> words)

FILE: Exercises/Modules/Chapter 09/Soln9_05.cpp
  function main (line 7) | int main()
  function average10 (line 15) | double average10(std::span<const double, 10> data)

FILE: Exercises/Modules/Chapter 09/Soln9_06.cpp
  function main (line 8) | int main()
  function average10 (line 17) | double average10(std::span<const double, 10> data)

FILE: Exercises/Modules/Chapter 10/Soln10_01.cpp
  function main (line 22) | int main()
  function T (line 42) | const T& my_clamp(const T& value, const T& low, const T& high)

FILE: Exercises/Modules/Chapter 10/Soln10_02.cpp
  function main (line 24) | int main()
  function T (line 40) | T larger(T a, T b)

FILE: Exercises/Modules/Chapter 10/Soln10_03.cpp
  function T (line 10) | T plus(const T& a, const T& b)
  function T (line 17) | T plus(const T* a, const T* b)
  function plus (line 25) | std::string plus(const char* a, const char* b)
  function main (line 30) | int main()

FILE: Exercises/Modules/Chapter 10/Soln10_04.cpp
  function my_size (line 10) | size_t my_size(const T (&array)[N]) { return N; }
  function my_size (line 14) | size_t my_size(const std::vector<T>& vector) { return vector.size(); }
  function my_size (line 17) | size_t my_size(const std::array<T,N>& array) { return N; }
  function main (line 35) | int main()

FILE: Exercises/Modules/Chapter 10/Soln10_05.cpp
  function main (line 13) | int main()
  function T (line 29) | T larger(T a, T b)

FILE: Exercises/Modules/Chapter 10/Soln10_06.cpp
  function main (line 16) | int main()
  function swap (line 40) | void swap(std::vector<T>& data, size_t first, size_t second)
  function sort (line 49) | void sort(std::vector<T>& data)
  function sort (line 56) | void sort(std::vector<T>& data, size_t start, size_t end)
  function show (line 80) | void show(const std::vector<T>& data, size_t width)

FILE: Exercises/Modules/Chapter 11/Soln11_01/Soln11_01.cpp
  function main (line 7) | int main()

FILE: Exercises/Modules/Chapter 11/Soln11_02/Soln11_02.cpp
  function main (line 7) | int main()

FILE: Exercises/Modules/Chapter 11/Soln11_02/words.cpp
  function swap (line 23) | void swap(words::Words& words, size_t first, size_t second)
  function sort (line 39) | void sort(words::Words& words, size_t start, size_t end)
  function max_word_length (line 62) | size_t max_word_length(const words::Words& words)

FILE: Exercises/Modules/Chapter 11/Soln11_03/Soln11_03.cpp
  function main (line 7) | int main()

FILE: Exercises/Modules/Chapter 11/Soln11_03/words.sorting.cpp
  function swap (line 4) | void swap(words::Words& words, size_t first, size_t second)
  function sort (line 20) | void sort(words::Words& words, size_t start, size_t end)

FILE: Exercises/Modules/Chapter 11/Soln11_03/words.utils.cpp
  function max_word_length (line 6) | size_t max_word_length(const words::Words& words)

FILE: Exercises/Modules/Chapter 11/Soln11_04/Soln11_04.cpp
  function main (line 6) | int main()

FILE: Exercises/Modules/Chapter 11/Soln11_04/internals.cpp
  function swap (line 5) | void swap(words::Words& words, size_t first, size_t second)
  function max_word_length (line 12) | size_t max_word_length(const words::Words& words)

FILE: Exercises/Modules/Chapter 11/Soln11_04/words.cpp
  function sort (line 31) | void sort(words::Words& words, size_t start, size_t end)

FILE: Exercises/Modules/Chapter 11/Soln11_05/Soln11_05.cpp
  function main (line 6) | int main()

FILE: Exercises/Modules/Chapter 11/Soln11_05/internals.cpp
  function swap (line 5) | void swap(words::Words& words, size_t first, size_t second)
  function max_word_length (line 12) | size_t max_word_length(const words::Words& words)

FILE: Exercises/Modules/Chapter 11/Soln11_06/Soln11_06.cpp
  type wrds (line 6) | namespace wrds
  function main (line 15) | int main()

FILE: Exercises/Modules/Chapter 11/Soln11_06/words.cpp
  function swap (line 23) | void swap(words::Words& words, size_t first, size_t second)
  function sort (line 39) | void sort(words::Words& words, size_t start, size_t end)
  function max_word_length (line 62) | size_t max_word_length(const words::Words& words)

FILE: Exercises/Modules/Chapter 12/Soln12_01/Soln12_01.cpp
  function main (line 5) | int main()

FILE: Exercises/Modules/Chapter 12/Soln12_02/Soln12_02.cpp
  function main (line 20) | int main()

FILE: Exercises/Modules/Chapter 12/Soln12_03/Integer.cpp
  function Integer (line 16) | Integer& Integer::add(const Integer& obj)
  function Integer (line 22) | Integer& Integer::subtract(const Integer& obj)
  function Integer (line 28) | Integer& Integer::multiply(const Integer& obj)

FILE: Exercises/Modules/Chapter 12/Soln12_03/Soln12_03.cpp
  function main (line 16) | int main()

FILE: Exercises/Modules/Chapter 12/Soln12_04/Integer.cpp
  function compare (line 38) | int compare(const Integer& obj1, const Integer& obj2)
  function nonFriendCompare (line 49) | int nonFriendCompare(const Integer& obj1, const Integer& obj2)

FILE: Exercises/Modules/Chapter 12/Soln12_04/Soln12_04.cpp
  function main (line 5) | int main()

FILE: Exercises/Modules/Chapter 12/Soln12_05/Soln12_05.cpp
  function showIntegerVal (line 5) | void showIntegerVal(Integer it)
  function showIntegerRef (line 10) | void showIntegerRef(const Integer& it)
  function main (line 16) | int main()

FILE: Exercises/Modules/Chapter 12/Soln12_06/Soln12_06.cpp
  function main (line 26) | int main()
  function SharedBox (line 70) | SharedBox findLargestBox(const Truckload& truckload)
  function SharedBox (line 86) | SharedBox findSmallestBox(const Truckload& truckload)

FILE: Exercises/Modules/Chapter 12/Soln12_06/Truckload.cpp
  class Truckload::Package (line 8) | class Truckload::Package
    method Package (line 14) | Package(SharedBox box) : m_box{ box }, m_next{ nullptr } {}
  function SharedBox (line 64) | SharedBox Truckload::Iterator::getFirstBox()
  function SharedBox (line 72) | SharedBox Truckload::Iterator::getNextBox()

FILE: Exercises/Modules/Chapter 12/Soln12_07/Soln12_07.cpp
  function main (line 13) | int main()
  function SharedBox (line 39) | SharedBox findLargestBox(const Truckload& truckload)
  function SharedBox (line 55) | SharedBox findSmallestBox(const Truckload& truckload)

FILE: Exercises/Modules/Chapter 12/Soln12_07/Truckload.cpp
  class Truckload::Package (line 8) | class Truckload::Package
    method Package (line 15) | Package(SharedBox box) : m_box{ box }, m_next{}, m_previous{} {}
  function SharedBox (line 80) | SharedBox Truckload::Iterator::getFirstBox()
  function SharedBox (line 87) | SharedBox Truckload::Iterator::getLastBox()
  function SharedBox (line 94) | SharedBox Truckload::Iterator::getNextBox()
  function SharedBox (line 104) | SharedBox Truckload::Iterator::getPreviousBox()

FILE: Exercises/Modules/Chapter 12/Soln12_08/Soln12_08.cpp
  function main (line 33) | int main()
  function findLargestBox (line 69) | Truckload::Iterator findLargestBox(const Truckload& truckload)
  function findSmallestBox (line 86) | Truckload::Iterator findSmallestBox(const Truckload& truckload)

FILE: Exercises/Modules/Chapter 12/Soln12_08/Truckload.cpp
  class Truckload::Package (line 8) | class Truckload::Package
    method Package (line 15) | Package(SharedBox box) : m_box{ box }, m_next{}, m_previous{} {}
  function SharedBox (line 80) | SharedBox Truckload::Iterator::getFirstBox()
  function SharedBox (line 87) | SharedBox Truckload::Iterator::getLastBox()
  function SharedBox (line 94) | SharedBox Truckload::Iterator::getNextBox()
  function SharedBox (line 104) | SharedBox Truckload::Iterator::getPreviousBox()
  function SharedBox (line 114) | SharedBox Truckload::Iterator::getCurrentBox() const

FILE: Exercises/Modules/Chapter 13/Soln13_01/Box.cpp
  function Box (line 11) | Box Box::operator+(const Box& aBox) const
  function Box (line 19) | Box Box::operator*(double factor) const

FILE: Exercises/Modules/Chapter 13/Soln13_01/Soln13_01.cpp
  function main (line 7) | int main()

FILE: Exercises/Modules/Chapter 13/Soln13_02/Box.cpp
  function Box (line 11) | Box Box::operator+(const Box& aBox) const
  function Box (line 19) | Box Box::operator*(double factor) const
  function Box (line 24) | Box operator*(double factor, const Box& box)

FILE: Exercises/Modules/Chapter 13/Soln13_02/Soln13_02.cpp
  function main (line 6) | int main()

FILE: Exercises/Modules/Chapter 13/Soln13_03/Box.cpp
  function Box (line 11) | Box Box::operator+(const Box& aBox) const
  function Box (line 18) | Box Box::operator*(double factor) const
  function Box (line 25) | Box Box::operator/(double divisor) const
  function Box (line 32) | Box& Box::operator+=(const Box& aBox)
  function Box (line 41) | Box& Box::operator*=(double factor)
  function Box (line 49) | Box& Box::operator/=(double divisor)
  function Box (line 57) | Box operator*(double factor, const Box& box)

FILE: Exercises/Modules/Chapter 13/Soln13_03/Soln13_03.cpp
  function main (line 6) | int main()

FILE: Exercises/Modules/Chapter 13/Soln13_04/Soln13_04.cpp
  function main (line 12) | int main()

FILE: Exercises/Modules/Chapter 13/Soln13_05/Soln13_05.cpp
  function testBox (line 8) | void testBox(const Box& box)
  function main (line 18) | int main()

FILE: Exercises/Modules/Chapter 13/Soln13_06/Soln13_06.cpp
  function testBox (line 15) | void testBox(const Box& box)
  function main (line 25) | int main()

FILE: Exercises/Modules/Chapter 13/Soln13_07/Soln13_07.cpp
  function main (line 6) | int main()

FILE: Exercises/Modules/Chapter 13/Soln13_08/Box.cpp
  function Box (line 13) | Box& Box::operator+=(const Box& aBox)
  function Box (line 23) | Box Box::operator+(const Box& aBox) const

FILE: Exercises/Modules/Chapter 13/Soln13_08/Soln13_08.cpp
  function main (line 14) | int main()

FILE: Exercises/Modules/Chapter 13/Soln13_09/Soln13_09.cpp
  function createUniformPseudoRandomNumberGenerator (line 10) | auto createUniformPseudoRandomNumberGenerator(double max)
  function main (line 18) | int main()

FILE: Exercises/Modules/Chapter 13/Soln13_09/Truckload.cpp
  class Truckload::Package (line 8) | class Truckload::Package
    method Package (line 14) | Package(SharedBox box) : m_box{ box }, m_next{ nullptr } {}
  function Truckload (line 42) | Truckload& Truckload::operator=(const Truckload& other)
  function SharedBox (line 70) | SharedBox Truckload::Iterator::getFirstBox()
  function SharedBox (line 78) | SharedBox Truckload::Iterator::getNextBox()
  function SharedBox (line 128) | SharedBox& Truckload::operator[](size_t index) const

FILE: Exercises/Modules/Chapter 14/Soln14_01/Soln14_01.cpp
  function main (line 5) | int main()

FILE: Exercises/Modules/Chapter 14/Soln14_02/Soln14_02.cpp
  function main (line 7) | int main()

FILE: Exercises/Modules/Chapter 14/Soln14_03/Soln14_03.cpp
  function main (line 7) | int main()

FILE: Exercises/Modules/Chapter 14/Soln14_04/Soln14_04.cpp
  function main (line 7) | int main()

FILE: Exercises/Modules/Chapter 15/Soln15_01/Soln15_01.cpp
  function createUniformPseudoRandomNumberGenerator (line 13) | auto createUniformPseudoRandomNumberGenerator(unsigned min, unsigned max)
  function main (line 21) | int main()

FILE: Exercises/Modules/Chapter 15/Soln15_02/Soln15_02.cpp
  function createUniformPseudoRandomNumberGenerator (line 13) | auto createUniformPseudoRandomNumberGenerator(unsigned min, unsigned max)
  function main (line 21) | int main()

FILE: Exercises/Modules/Chapter 15/Soln15_03/Soln15_03.cpp
  function createUniformPseudoRandomNumberGenerator (line 13) | auto createUniformPseudoRandomNumberGenerator(unsigned min, unsigned max)
  function main (line 21) | int main()

FILE: Exercises/Modules/Chapter 15/Soln15_04/Soln15_04.cpp
  function createUniformPseudoRandomNumberGenerator (line 13) | auto createUniformPseudoRandomNumberGenerator(unsigned min, unsigned max)
  function main (line 21) | int main()

FILE: Exercises/Modules/Chapter 15/Soln15_05/Soln15_05.cpp
  function createUniformPseudoRandomNumberGenerator (line 13) | auto createUniformPseudoRandomNumberGenerator(unsigned min, unsigned max)
  function main (line 21) | int main()

FILE: Exercises/Modules/Chapter 15/Soln15_06/Soln15_06.cpp
  function main (line 11) | int main()
  function calculateSumAreas (line 30) | double calculateSumAreas(const std::vector<Shape*>& shapes)
  function calculateSumPerimeters (line 40) | double calculateSumPerimeters(const std::vector<Shape*>& shapes)
  function printSums (line 50) | void printSums(const std::vector<Shape*>& shapes)

FILE: Exercises/Modules/Chapter 16/Exer16_06/DB.cpp
  type QueryResult (line 10) | struct QueryResult
  class Database (line 16) | class Database
    method Database (line 19) | Database() = default;
    method hasConnection (line 21) | bool hasConnection() const { return m_connected; }
    method connect (line 22) | void connect() { m_connected = true; }
    method disconnect (line 23) | void disconnect() { m_connected = false; }
  function DB_CONNECTION (line 32) | DB_CONNECTION* db_connect()
  function db_disconnect (line 47) | void db_disconnect(DB_CONNECTION* connection)
  function DB_QUERY_RESULT (line 54) | DB_QUERY_RESULT* db_query(DB_CONNECTION* connection, const char* query)
  function QueryResult (line 59) | QueryResult* Database::query(const char* query)
  function db_num_fields (line 84) | int db_num_fields(DB_QUERY_RESULT* result)
  function DB_ROW (line 97) | DB_ROW db_fetch_row(DB_QUERY_RESULT* result)
  function db_free_result (line 110) | void db_free_result(DB_QUERY_RESULT* result)

FILE: Exercises/Modules/Chapter 16/Exer16_06/Exer16_06.cpp
  function main (line 17) | int main()
  function readCustomers (line 54) | std::vector<Customer> readCustomers(DB_QUERY_RESULT* result)
  function verifyCustomerFields (line 80) | void verifyCustomerFields(DB_QUERY_RESULT* result)
  function print (line 93) | void print(std::ostream& stream, const Customer& customer)

FILE: Exercises/Modules/Chapter 16/Soln16_01/Soln16_01.cpp
  function main (line 11) | int main()
  function createUniformPseudoRandomNumberGenerator (line 33) | auto createUniformPseudoRandomNumberGenerator(double min, double max)
  function throwCurveballSometimes (line 42) | void throwCurveballSometimes()
  function createUniformPseudoRandomBooleanGenerator (line 56) | auto createUniformPseudoRandomBooleanGenerator(double probabilityOfTrue)
  function throwCurveballSometimesBernouilli (line 65) | void throwCurveballSometimesBernouilli()

FILE: Exercises/Modules/Chapter 16/Soln16_02/Soln16_02.cpp
  function main (line 12) | int main()
  function createUniformPseudoRandomBooleanGenerator (line 35) | auto createUniformPseudoRandomBooleanGenerator(double probabilityOfTrue)
  function throwCurveballSometimes (line 44) | void throwCurveballSometimes()

FILE: Exercises/Modules/Chapter 16/Soln16_03/Soln16_03.cpp
  function main (line 7) | int main()

FILE: Exercises/Modules/Chapter 16/Soln16_03/Truckload.cpp
  class Truckload::Package (line 10) | class Truckload::Package
    method Package (line 16) | Package(SharedBox box) : m_box{ box }, m_next{ nullptr } {}
  function Truckload (line 44) | Truckload& Truckload::operator=(const Truckload& other)
  function SharedBox (line 72) | SharedBox Truckload::Iterator::getFirstBox()
  function SharedBox (line 80) | SharedBox Truckload::Iterator::getNextBox()
  function SharedBox (line 130) | SharedBox& Truckload::operator[](size_t index) const

FILE: Exercises/Modules/Chapter 16/Soln16_04/Soln16_04.cpp
  class BaseClass (line 21) | class BaseClass
  class DerivedClass1 (line 27) | class DerivedClass1 : public BaseClass {}
  class DerivedClass2 (line 28) | class DerivedClass2 : public BaseClass {}
  function main (line 30) | int main()

FILE: Exercises/Modules/Chapter 16/Soln16_05/Soln16_05.cpp
  function main (line 17) | int main()
  function askEvenNumber (line 35) | void askEvenNumber()
  function readEvenNumber (line 91) | int readEvenNumber()
  function createUniformPseudoRandomBooleanGenerator (line 114) | auto createUniformPseudoRandomBooleanGenerator(double probabilityOfTrue)
  function throwCurveballSometimes (line 123) | void throwCurveballSometimes()

FILE: Exercises/Modules/Chapter 16/Soln16_06/DB.cpp
  type QueryResult (line 10) | struct QueryResult
  class Database (line 16) | class Database
    method Database (line 19) | Database() = default;
    method hasConnection (line 21) | bool hasConnection() const { return m_connected; }
    method connect (line 22) | void connect() { m_connected = true; }
    method disconnect (line 23) | void disconnect() { m_connected = false; }
  function DB_CONNECTION (line 32) | DB_CONNECTION* db_connect()
  function db_disconnect (line 47) | void db_disconnect(DB_CONNECTION* connection)
  function DB_QUERY_RESULT (line 54) | DB_QUERY_RESULT* db_query(DB_CONNECTION* connection, const char* query)
  function QueryResult (line 59) | QueryResult* Database::query(const char* query)
  function db_num_fields (line 84) | int db_num_fields(DB_QUERY_RESULT* result)
  function DB_ROW (line 97) | DB_ROW db_fetch_row(DB_QUERY_RESULT* result)
  function db_free_result (line 110) | void db_free_result(DB_QUERY_RESULT* result)

FILE: Exercises/Modules/Chapter 16/Soln16_06/Soln16_06.cpp
  function main (line 43) | int main()
  function readCustomers (line 74) | std::vector<Customer> readCustomers(DB_QUERY_RESULT* result)
  function verifyCustomerFields (line 100) | void verifyCustomerFields(DB_QUERY_RESULT* result)
  function print (line 113) | void print(std::ostream& stream, const Customer& customer)

FILE: Exercises/Modules/Chapter 17/Soln17_01/Soln17_01.cpp
  function main (line 6) | int main()

FILE: Exercises/Modules/Chapter 17/Soln17_02/Soln17_02.cpp
  function main (line 7) | int main()

FILE: Exercises/Modules/Chapter 17/Soln17_03/Soln17_03.cpp
  function main (line 6) | int main()

FILE: Exercises/Modules/Chapter 17/Soln17_04/Soln17_04.cpp
  function createUniformPseudoRandomNumberGenerator (line 17) | auto createUniformPseudoRandomNumberGenerator(int min, int max)
  function main (line 25) | int main()

FILE: Exercises/Modules/Chapter 17/Soln17_05/Soln17_05.cpp
  function main (line 8) | int main()

FILE: Exercises/Modules/Chapter 17/Soln17_06/Soln17_06.cpp
  function main (line 11) | int main()

FILE: Exercises/Modules/Chapter 17/Soln17_07/Soln17_07.cpp
  function main (line 6) | int main()

FILE: Exercises/Modules/Chapter 17/Soln17_07A/Soln17_07A.cpp
  function main (line 7) | int main()

FILE: Exercises/Modules/Chapter 18/Soln18_01/Soln18_01.cpp
  function main (line 14) | int main()

FILE: Exercises/Modules/Chapter 18/Soln18_01/Truckload.cpp
  class Truckload::Package (line 11) | class Truckload::Package
    method Package (line 17) | Package(SharedBox box) : m_box{ box }, m_next{ nullptr } {}
  function Truckload (line 52) | Truckload& Truckload::operator=(const Truckload& src)
  function Truckload (line 69) | Truckload& Truckload::operator=(Truckload&& src) noexcept
  function swap (line 84) | void swap(Truckload& one, Truckload& other) noexcept
  function SharedBox (line 92) | SharedBox Truckload::Iterator::getFirstBox()
  function SharedBox (line 100) | SharedBox Truckload::Iterator::getNextBox()
  function SharedBox (line 150) | SharedBox& Truckload::operator[](size_t index) const

FILE: Exercises/Modules/Chapter 18/Soln18_02/Soln18_02.cpp
  function printList (line 9) | void printList(std::string_view message, const LinkedList<std::unique_pt...
  function main (line 19) | int main()

FILE: Exercises/Modules/Chapter 18/Soln18_03/DB.cpp
  type QueryResult (line 10) | struct QueryResult
  class Database (line 16) | class Database
    method Database (line 19) | Database() = default;
    method hasConnection (line 21) | bool hasConnection() const { return m_connected; }
    method connect (line 22) | void connect() { m_connected = true; }
    method disconnect (line 23) | void disconnect() { m_connected = false; }
  function DB_CONNECTION (line 32) | DB_CONNECTION* db_connect()
  function db_disconnect (line 47) | void db_disconnect(DB_CONNECTION* connection)
  function DB_QUERY_RESULT (line 54) | DB_QUERY_RESULT* db_query(DB_CONNECTION* connection, const char* query)
  function QueryResult (line 59) | QueryResult* Database::query(const char* query)
  function db_num_fields (line 84) | int db_num_fields(DB_QUERY_RESULT* result)
  function DB_ROW (line 97) | DB_ROW db_fetch_row(DB_QUERY_RESULT* result)
  function db_free_result (line 110) | void db_free_result(DB_QUERY_RESULT* result)

FILE: Exercises/Modules/Chapter 18/Soln18_03/Soln18_03.cpp
  function main (line 19) | int main()
  function readCustomers (line 63) | std::vector<Customer> readCustomers(DB_QUERY_RESULT* result)
  function verifyCustomerFields (line 89) | void verifyCustomerFields(DB_QUERY_RESULT* result)
  function print (line 102) | void print(std::ostream& stream, const Customer& customer)

FILE: Exercises/Modules/Chapter 18/Soln18_04/DB.cpp
  type QueryResult (line 10) | struct QueryResult
  class Database (line 16) | class Database
    method Database (line 19) | Database() = default;
    method hasConnection (line 21) | bool hasConnection() const { return m_connected; }
    method connect (line 22) | void connect() { m_connected = true; }
    method disconnect (line 23) | void disconnect() { m_connected = false; }
  function DB_CONNECTION (line 32) | DB_CONNECTION* db_connect()
  function db_disconnect (line 47) | void db_disconnect(DB_CONNECTION* connection)
  function DB_QUERY_RESULT (line 54) | DB_QUERY_RESULT* db_query(DB_CONNECTION* connection, const char* query)
  function QueryResult (line 59) | QueryResult* Database::query(const char* query)
  function db_num_fields (line 84) | int db_num_fields(DB_QUERY_RESULT* result)
  function DB_ROW (line 97) | DB_ROW db_fetch_row(DB_QUERY_RESULT* result)
  function db_free_result (line 110) | void db_free_result(DB_QUERY_RESULT* result)

FILE: Exercises/Modules/Chapter 18/Soln18_04/Soln18_04.cpp
  function main (line 19) | int main()
  function readCustomers (line 55) | std::vector<Customer> readCustomers(DB_QUERY_RESULT* result)
  function verifyCustomerFields (line 81) | void verifyCustomerFields(DB_QUERY_RESULT* result)
  function print (line 94) | void print(std::ostream& stream, const Customer& customer)

FILE: Exercises/Modules/Chapter 18/Soln18_05/DB.cpp
  type QueryResult (line 10) | struct QueryResult
  class Database (line 16) | class Database
    method Database (line 19) | Database() = default;
    method hasConnection (line 21) | bool hasConnection() const { return m_connected; }
    method connect (line 22) | void connect() { m_connected = true; }
    method disconnect (line 23) | void disconnect() { m_connected = false; }
  function DB_CONNECTION (line 32) | DB_CONNECTION* db_connect()
  function db_disconnect (line 47) | void db_disconnect(DB_CONNECTION* connection)
  function DB_QUERY_RESULT (line 54) | DB_QUERY_RESULT* db_query(DB_CONNECTION* connection, const char* query)
  function QueryResult (line 59) | QueryResult* Database::query(const char* query)
  function db_num_fields (line 84) | int db_num_fields(DB_QUERY_RESULT* result)
  function DB_ROW (line 97) | DB_ROW db_fetch_row(DB_QUERY_RESULT* result)
  function db_free_result (line 110) | void db_free_result(DB_QUERY_RESULT* result)

FILE: Exercises/Modules/Chapter 18/Soln18_05/Soln18_05.cpp
  function main (line 16) | int main()
  function readCustomers (line 52) | std::vector<Customer> readCustomers(DB_QUERY_RESULT* result)
  function verifyCustomerFields (line 78) | void verifyCustomerFields(DB_QUERY_RESULT* result)
  function print (line 91) | void print(std::ostream& stream, const Customer& customer)

FILE: Exercises/Modules/Chapter 19/Soln19_01/Soln19_01.cpp
  function main (line 9) | int main()

FILE: Exercises/Modules/Chapter 19/Soln19_02/Soln19_02.cpp
  function list (line 16) | void list(const std::vector<T>& values, size_t width = 5)
  function main (line 23) | int main()

FILE: Exercises/Modules/Chapter 19/Soln19_03/Soln19_03.cpp
  function createUniformPseudoRandomNumberGenerator (line 29) | auto createUniformPseudoRandomNumberGenerator()
  function generateRandomNumbers (line 37) | auto generateRandomNumbers(unsigned number)
  function main (line 46) | int main()

FILE: Exercises/Modules/Chapter 19/Soln19_04/Soln19_04.cpp
  function list (line 25) | void list(const std::vector<T>& values, size_t width = 5)
  function is_palindrome (line 32) | bool is_palindrome(std::string_view s)
  function main (line 38) | int main()

FILE: Exercises/Modules/Chapter 19/Soln19_05/Soln19_05.cpp
  function logDelivary (line 11) | void logDelivary(SharedBox box)
  function main (line 16) | int main()

FILE: Exercises/Modules/Chapter 19/Soln19_05/Truckload.cpp
  class Truckload::Package (line 10) | class Truckload::Package
    method Package (line 16) | Package(SharedBox box) : m_box{ box }, m_next{ nullptr } {}
  function Truckload (line 44) | Truckload& Truckload::operator=(const Truckload& other)
  function SharedBox (line 72) | SharedBox Truckload::Iterator::getFirstBox()
  function SharedBox (line 80) | SharedBox Truckload::Iterator::getNextBox()
  function SharedBox (line 130) | SharedBox& Truckload::operator[](size_t index) const

FILE: Exercises/Modules/Chapter 20/Soln20_01/Soln20_01.cpp
  function main (line 14) | int main()

FILE: Exercises/Modules/Chapter 20/Soln20_01/Truckload.cpp
  function swap (line 25) | void swap(Truckload& one, Truckload& other) noexcept
  function SharedBox (line 33) | SharedBox Truckload::Iterator::getFirstBox()
  function SharedBox (line 41) | SharedBox Truckload::Iterator::getNextBox()
  function SharedBox (line 77) | SharedBox& Truckload::operator[](size_t index)
  function SharedBox (line 83) | SharedBox Truckload::operator[](size_t index) const

FILE: Exercises/Modules/Chapter 20/Soln20_02/Soln20_02.cpp
  function main (line 14) | int main()

FILE: Exercises/Modules/Chapter 20/Soln20_03/Soln20_03.cpp
  function main (line 25) | int main()

FILE: Exercises/Modules/Chapter 20/Soln20_03A/Soln20_03A.cpp
  function main (line 22) | int main()

FILE: Exercises/Modules/Chapter 20/Soln20_04/Soln20_04.cpp
  function removeEvenNumbers (line 20) | void removeEvenNumbers(std::vector<int>& numbers)
  function main (line 29) | int main()
  function fillVector_1toN (line 42) | std::vector<int> fillVector_1toN(size_t N)
  function printVector (line 50) | void printVector(std::string_view message, const std::vector<int>& numbers)

FILE: Exercises/Modules/Chapter 20/Soln20_05/Soln20_05.cpp
  function average (line 12) | std::optional<T> average(IterType begin, IterType end)
  function main (line 35) | int main()

FILE: Exercises/Modules/Chapter 20/Soln20_06/Soln20_06.cpp
  function removeEvenNumbers (line 21) | void removeEvenNumbers(Auto& numbers)    /* Using more elegant std::eras...
  function main (line 26) | int main()
  function fillVector_1toN (line 39) | std::vector<int> fillVector_1toN(size_t N)
  function printVector (line 46) | void printVector(std::string_view message, const std::vector<int>& numbers)

FILE: Exercises/Modules/Chapter 20/Soln20_07/Soln20_07.cpp
  function printVector (line 11) | void printVector(std::string_view message, Auto& numbers)
  function main (line 18) | int main()

FILE: Exercises/Modules/Chapter 20/Soln20_08/Soln20_08.cpp
  function createUniformPseudoRandomNumberGenerator (line 12) | auto createUniformPseudoRandomNumberGenerator(unsigned min, unsigned max)
  function main (line 20) | int main()

FILE: Exercises/Modules/Chapter 20/Soln20_09/Soln20_09.cpp
  function createUniformPseudoRandomNumberGenerator (line 13) | auto createUniformPseudoRandomNumberGenerator(unsigned min, unsigned max)
  function main (line 21) | int main()

FILE: Exercises/Modules/Chapter 20/Soln20_10/Soln20_10.cpp
  function main (line 7) | int main()

FILE: Exercises/Modules/Chapter 20/Soln20_11/Soln20_11.cpp
  function isPrime (line 9) | bool isPrime(unsigned number)
  function main (line 20) | int main()

FILE: Exercises/Modules/Chapter 20/Soln20_12/Soln20_12.cpp
  function isPrime (line 9) | bool isPrime(unsigned number)
  function main (line 20) | int main()

FILE: Exercises/Modules/Chapter 20/Soln20_13/Soln20_13.cpp
  function maxWordLength (line 27) | size_t maxWordLength(const WordCounts& wordCounts)
  function maxWordLength_1 (line 39) | size_t maxWordLength_1(const WordCounts& wordCounts)
  function maxWordLength_2 (line 52) | size_t maxWordLength_2(const WordCounts& wordCounts)
  function maxWordLength_3 (line 66) | size_t maxWordLength_3(const WordCounts& wordCounts)
  function main (line 84) | int main()
  function Words (line 103) | Words extractWords(std::string_view text, std::string_view separators)
  function WordCounts (line 121) | WordCounts countWords(const Words& words)
  function showWordCounts (line 129) | void showWordCounts(const WordCounts& wordCounts)

FILE: Exercises/Modules/Chapter 20/Soln20_14/Soln20_14.cpp
  function isPrime (line 10) | bool isPrime(unsigned number)
  function main (line 19) | int main()

FILE: Exercises/Modules/Chapter 21/Soln21_01/Soln21_01.cpp
  function main (line 78) | int main()

FILE: Exercises/Modules/Chapter 21/Soln21_02/Soln21_02.cpp
  function Iterator (line 20) | Iterator original_find_optimum(Iterator begin, Iterator end, Comparison ...
  function Iterator (line 38) | Iterator find_optimum(Iterator begin, Sentinel end, Comparison compare =...
  class Box (line 56) | class Box
    method Box (line 59) | Box() : Box{ 1, 1, 1 } {}
    method Box (line 60) | Box(double length, double width, double height)
    method volume (line 64) | double volume() const { return m_length * m_width * m_height; }
    method isSmallerThan (line 65) | double isSmallerThan(const Box& other) const { return volume() < other...
  function main (line 71) | int main()

FILE: Exercises/Modules/Chapter 21/Soln21_03/Soln21_03.cpp
  function medianOfSorted (line 34) | auto medianOfSorted(std::span<T, N> span)
  function main (line 40) | int main()

FILE: Exercises/Modules/Chapter 21/Soln21_04/Soln21_04.cpp
  function medianOfSorted (line 55) | auto medianOfSorted(Range&& range)
  function main (line 73) | int main()

FILE: Exercises/Modules/Chapter 21/Soln21_05/Soln21_05.cpp
  function my_advance (line 10) | auto my_advance(Iter iter, std::iter_difference_t<Iter> n)
  function my_advance (line 16) | auto my_advance(Iter iter, std::iter_difference_t<Iter> n)
  function my_advance (line 24) | auto my_advance(Iter iter, std::iter_difference_t<Iter> n)
  function main (line 30) | int main()

FILE: Exercises/Modules/Chapter 21/Soln21_06/Soln21_06.cpp
  function buildStringArray (line 6) | Array<std::string> buildStringArray(const size_t size)
  function main (line 14) | int main()

FILE: Exercises/NoModules/Appendix A/SolnA_01/SolnA_01.cpp
  function main (line 7) | int main()

FILE: Exercises/NoModules/Appendix A/SolnA_02/SolnA_02.cpp
  function main (line 9) | int main()

FILE: Exercises/NoModules/Appendix A/SolnA_03/SmartException.h
  function class (line 7) | class SmartException : public std::logic_error

FILE: Exercises/NoModules/Appendix A/SolnA_03/SolnA_03.cpp
  function main (line 6) | int main()

FILE: Exercises/NoModules/Appendix A/SolnA_04/SmartException.h
  function throwFromHere (line 33) | inline void SmartException::throwFromHere(std::source_location location)

FILE: Exercises/NoModules/Appendix A/SolnA_04/SolnA_04.cpp
  function main (line 5) | int main()

FILE: Exercises/NoModules/Appendix A/SolnA_05/Print.cpp
  function print (line 4) | void print(std::string_view string)

FILE: Exercises/NoModules/Appendix A/SolnA_05/PrintThat.cpp
  function print_that (line 7) | void print_that(std::string_view string)

FILE: Exercises/NoModules/Appendix A/SolnA_05/PrintThis.cpp
  function print_this (line 7) | void print_this(std::string_view string)

FILE: Exercises/NoModules/Appendix A/SolnA_05/SolnA_05.cpp
  function main (line 6) | int main()

FILE: Exercises/NoModules/Appendix A/SolnA_06/Print.h
  function print (line 7) | inline void print(std::string_view string)

FILE: Exercises/NoModules/Appendix A/SolnA_06/PrintThat.cpp
  function print_that (line 4) | void print_that(std::string_view string)

FILE: Exercises/NoModules/Appendix A/SolnA_06/PrintThis.cpp
  function print_this (line 4) | void print_this(std::string_view string)

FILE: Exercises/NoModules/Appendix A/SolnA_06/SolnA_06.cpp
  function main (line 6) | int main()

FILE: Exercises/NoModules/Appendix A/SolnA_07A/Print.cpp
  function print (line 6) | void print(std::string_view string)

FILE: Exercises/NoModules/Appendix A/SolnA_07A/PrintThat.cpp
  function print_that (line 7) | void print_that(std::string_view string)

FILE: Exercises/NoModules/Appendix A/SolnA_07A/PrintThis.cpp
  function print_this (line 7) | void print_this(std::string_view string)

FILE: Exercises/NoModules/Appendix A/SolnA_07A/SolnA_07A.cpp
  function main (line 8) | int main()

FILE: Exercises/NoModules/Appendix A/SolnA_07B/Print.h
  function count (line 7) | inline int count {}
  function print (line 9) | inline void print(std::string_view string)

FILE: Exercises/NoModules/Appendix A/SolnA_07B/PrintThat.cpp
  function print_that (line 4) | void print_that(std::string_view string)

FILE: Exercises/NoModules/Appendix A/SolnA_07B/PrintThis.cpp
  function print_this (line 4) | void print_this(std::string_view string)

FILE: Exercises/NoModules/Appendix A/SolnA_07B/SolnA_07B.cpp
  function main (line 7) | int main()

FILE: Exercises/NoModules/Chapter 01/Soln1_01.cpp
  function main (line 5) | int main()

FILE: Exercises/NoModules/Chapter 01/Soln1_02.cpp
  function main (line 7) | int main()

FILE: Exercises/NoModules/Chapter 02/Soln2_01A.cpp
  function main (line 16) | int main()

FILE: Exercises/NoModules/Chapter 02/Soln2_01B.cpp
  function main (line 16) | int main()

FILE: Exercises/NoModules/Chapter 02/Soln2_02A.cpp
  function main (line 8) | int main()

FILE: Exercises/NoModules/Chapter 02/Soln2_02B.cpp
  function main (line 10) | int main()

FILE: Exercises/NoModules/Chapter 02/Soln2_03.cpp
  function main (line 6) | int main()

FILE: Exercises/NoModules/Chapter 02/Soln2_04.cpp
  function main (line 7) | int main()

FILE: Exercises/NoModules/Chapter 02/Soln2_05.cpp
  function main (line 6) | int main()

FILE: Exercises/NoModules/Chapter 02/Soln2_06.cpp
  function main (line 7) | int main()

FILE: Exercises/NoModules/Chapter 02/Soln2_07.cpp
  function main (line 9) | int main()

FILE: Exercises/NoModules/Chapter 02/Soln2_08.cpp
  function main (line 4) | int main()

FILE: Exercises/NoModules/Chapter 03/Soln3_01.cpp
  function main (line 14) | int main()

FILE: Exercises/NoModules/Chapter 03/Soln3_02.cpp
  function main (line 12) | int main()

FILE: Exercises/NoModules/Chapter 03/Soln3_03.cpp
  function main (line 18) | int main()

FILE: Exercises/NoModules/Chapter 03/Soln3_04.cpp
  function main (line 11) | int main()

FILE: Exercises/NoModules/Chapter 03/Soln3_05.cpp
  function main (line 9) | int main()

FILE: Exercises/NoModules/Chapter 03/Soln3_06.cpp
  function main (line 5) | int main()

FILE: Exercises/NoModules/Chapter 04/Soln4_01.cpp
  function main (line 5) | int main()

FILE: Exercises/NoModules/Chapter 04/Soln4_02.cpp
  function main (line 8) | int main()

FILE: Exercises/NoModules/Chapter 04/Soln4_03.cpp
  function main (line 5) | int main()

FILE: Exercises/NoModules/Chapter 04/Soln4_04.cpp
  type AcademicDegree (line 8) | enum class AcademicDegree
  function main (line 13) | int main()

FILE: Exercises/NoModules/Chapter 04/Soln4_05.cpp
  function main (line 6) | int main()

FILE: Exercises/NoModules/Chapter 04/Soln4_06.cpp
  function main (line 10) | int main()

FILE: Exercises/NoModules/Chapter 04/Soln4_07.cpp
  function main (line 15) | int main()

FILE: Exercises/NoModules/Chapter 04/Soln4_08.cpp
  function main (line 6) | int main()

FILE: Exercises/NoModules/Chapter 05/Soln5_01.cpp
  function main (line 5) | int main()

FILE: Exercises/NoModules/Chapter 05/Soln5_02.cpp
  function main (line 6) | int main()

FILE: Exercises/NoModules/Chapter 05/Soln5_03.cpp
  function main (line 4) | int main()

FILE: Exercises/NoModules/Chapter 05/Soln5_04.cpp
  function main (line 4) | int main()

FILE: Exercises/NoModules/Chapter 05/Soln5_05.cpp
  function main (line 4) | int main()

FILE: Exercises/NoModules/Chapter 05/Soln5_06.cpp
  function main (line 6) | int main()

FILE: Exercises/NoModules/Chapter 05/Soln5_07.cpp
  function main (line 9) | int main()

FILE: Exercises/NoModules/Chapter 05/Soln5_08.cpp
  function main (line 13) | int main()

FILE: Exercises/NoModules/Chapter 06/Soln6_01.cpp
  function main (line 10) | int main()

FILE: Exercises/NoModules/Chapter 06/Soln6_02.cpp
  function main (line 8) | int main()

FILE: Exercises/NoModules/Chapter 06/Soln6_03.cpp
  function main (line 8) | int main()

FILE: Exercises/NoModules/Chapter 06/Soln6_04.cpp
  function main (line 23) | int main()

FILE: Exercises/NoModules/Chapter 06/Soln6_05.cpp
  function main (line 11) | int main()

FILE: Exercises/NoModules/Chapter 06/Soln6_06.cpp
  function main (line 9) | int main()

FILE: Exercises/NoModules/Chapter 07/Soln7_01.cpp
  function main (line 9) | int main()

FILE: Exercises/NoModules/Chapter 07/Soln7_02.cpp
  function main (line 7) | int main()

FILE: Exercises/NoModules/Chapter 07/Soln7_03.cpp
  function main (line 8) | int main()

FILE: Exercises/NoModules/Chapter 07/Soln7_04.cpp
  function main (line 9) | int main()

FILE: Exercises/NoModules/Chapter 07/Soln7_05.cpp
  function main (line 7) | int main()

FILE: Exercises/NoModules/Chapter 07/Soln7_06.cpp
  function main (line 14) | int main()

FILE: Exercises/NoModules/Chapter 07/Soln7_07.cpp
  function main (line 6) | int main()

FILE: Exercises/NoModules/Chapter 07/Soln7_08A.cpp
  function main (line 15) | int main()

FILE: Exercises/NoModules/Chapter 07/Soln7_08B.cpp
  function main (line 12) | int main()

FILE: Exercises/NoModules/Chapter 07/Soln7_09A.cpp
  function main (line 7) | int main()

FILE: Exercises/NoModules/Chapter 07/Soln7_09B.cpp
  function main (line 7) | int main()

FILE: Exercises/NoModules/Chapter 08/Soln8_01.cpp
  function main (line 13) | int main()
  function validate_input (line 33) | int validate_input(int lower, int upper, const std::string& description)
  function year (line 47) | int year()
  function month (line 55) | int month()
  function date (line 63) | int date(int month_number, int year)
  function ending (line 83) | std::string ending(int date_day)

FILE: Exercises/NoModules/Chapter 08/Soln8_02.cpp
  function main (line 11) | int main()
  function reverse (line 30) | std::string reverse(std::string str)

FILE: Exercises/NoModules/Chapter 08/Soln8_03.cpp
  function main (line 4) | int main(int numArguments, char* arguments[])

FILE: Exercises/NoModules/Chapter 08/Soln8_04.cpp
  function main (line 9) | int main()
  function plus (line 34) | int plus(int a, int b)
  function plus (line 40) | double plus(double x, double y)
  function plus (line 46) | std::string plus(const std::string& s1, const std::string& s2)

FILE: Exercises/NoModules/Chapter 08/Soln8_05.cpp
  function main (line 23) | int main()
  function isPrime (line 55) | bool isPrime(unsigned number)
  function generateNumbers (line 72) | std::vector<unsigned> generateNumbers(unsigned to, unsigned from)
  function filterPrimeNumbers (line 81) | std::vector<unsigned> filterPrimeNumbers(const std::vector<unsigned>& nu...

FILE: Exercises/NoModules/Chapter 08/Soln8_06.cpp
  function main (line 47) | int main()
  function swap (line 86) | void swap(std::vector<unsigned>& numbers, size_t first, size_t second)
  function sort (line 95) | void sort(std::vector<unsigned>& numbers, size_t start, size_t end)
  function sort (line 119) | void sort(std::vector<unsigned>& numbers)
  function getHighest (line 125) | void getHighest(const std::vector<unsigned>& sortedNumbers, unsigned(&hi...
  function getLowest (line 139) | void getLowest(const std::vector<unsigned>& sortedNumbers, unsigned(&low...
  function computeAverage (line 150) | double computeAverage(const std::vector<unsigned>& numbers)
  function computeMedian (line 161) | double computeMedian(const std::vector<unsigned>& numbers)
  function computeStandardDeviation (line 178) | double computeStandardDeviation(const std::vector<unsigned>& numbers)
  function computeVariance (line 190) | double computeVariance(const std::vector<unsigned>& numbers)
  function printNumber (line 199) | void printNumber(const std::string& label, double number)
  function printNumbers (line 211) | void printNumbers(const std::string& label, const unsigned(&numbers)[5])

FILE: Exercises/NoModules/Chapter 08/Soln8_07.cpp
  function main (line 10) | int main()
  function fib (line 20) | unsigned long long fib(size_t n)

FILE: Exercises/NoModules/Chapter 08/Soln8_07A.cpp
  function main (line 8) | int main()
  function fib (line 18) | unsigned long long fib(size_t n)

FILE: Exercises/NoModules/Chapter 08/Soln8_08.cpp
  function main (line 8) | int main()
  function power (line 17) | long double power(double x, int n)

FILE: Exercises/NoModules/Chapter 08/Soln8_09.cpp
  function main (line 8) | int main()
  function mult (line 13) | inline auto mult(long double l, long double r)
  function power (line 21) | long double power(double x, int n)

FILE: Exercises/NoModules/Chapter 09/Soln9_01.cpp
  function main (line 10) | int main()
  function find_last (line 30) | std::optional<size_t> find_last(std::string_view string, char to_find,

FILE: Exercises/NoModules/Chapter 09/Soln9_02.cpp
  function main (line 19) | int main()
  function show_data (line 35) | void show_data(
  function show_data (line 52) | void show_data(int data, std::string_view title, size_t width)

FILE: Exercises/NoModules/Chapter 09/Soln9_03.cpp
  function main (line 18) | int main()
  function show_data (line 32) | void show_data(std::span<const double> data,
  function smallest (line 48) | std::optional<double> smallest(std::span<const double> data)
  function shift_range (line 60) | std::span<double> shift_range(std::span<double> data, double delta)
  function largest (line 67) | std::optional<double> largest(std::span<const double> data)
  function scale_range (line 79) | std::span<double> scale_range(std::span<double> data, double divisor)
  function normalize_range (line 88) | std::span<double> normalize_range(std::span<double> data)

FILE: Exercises/NoModules/Chapter 09/Soln9_04.cpp
  function main (line 14) | int main()
  function largest (line 30) | std::optional<double> largest(std::span<const double> data)
  function largest (line 41) | std::optional<int> largest(std::span<const int> data)
  function largest (line 52) | std::optional<std::string> largest(std::span<const std::string> words)

FILE: Exercises/NoModules/Chapter 09/Soln9_05.cpp
  function main (line 7) | int main()
  function average10 (line 15) | double average10(std::span<const double, 10> data)

FILE: Exercises/NoModules/Chapter 09/Soln9_06.cpp
  function main (line 8) | int main()
  function average10 (line 17) | double average10(std::span<const double, 10> data)

FILE: Exercises/NoModules/Chapter 10/Soln10_01.cpp
  function main (line 22) | int main()
  function T (line 42) | const T& my_clamp(const T& value, const T& low, const T& high)

FILE: Exercises/NoModules/Chapter 10/Soln10_02.cpp
  function main (line 24) | int main()
  function T (line 40) | T larger(T a, T b)

FILE: Exercises/NoModules/Chapter 10/Soln10_03.cpp
  function T (line 10) | T plus(const T& a, const T& b)
  function T (line 17) | T plus(const T* a, const T* b)
  function plus (line 25) | std::string plus(const char* a, const char* b)
  function main (line 30) | int main()

FILE: Exercises/NoModules/Chapter 10/Soln10_04.cpp
  function my_size (line 10) | size_t my_size(const T (&array)[N]) { return N; }
  function my_size (line 14) | size_t my_size(const std::vector<T>& vector) { return vector.size(); }
  function my_size (line 17) | size_t my_size(const std::array<T,N>& array) { return N; }
  function main (line 35) | int main()

FILE: Exercises/NoModules/Chapter 10/Soln10_05.cpp
  function main (line 13) | int main()
  function T (line 29) | T larger(T a, T b)

FILE: Exercises/NoModules/Chapter 10/Soln10_06.cpp
  function main (line 16) | int main()
  function swap (line 40) | void swap(std::vector<T>& data, size_t first, size_t second)
  function sort (line 49) | void sort(std::vector<T>& data)
  function sort (line 56) | void sort(std::vector<T>& data, size_t start, size_t end)
  function show (line 80) | void show(const std::vector<T>& data, size_t width)

FILE: Exercises/NoModules/Chapter 12/Soln12_01/Integer.h
  function class (line 4) | class Integer

FILE: Exercises/NoModules/Chapter 12/Soln12_01/Soln12_01.cpp
  function main (line 5) | int main()

FILE: Exercises/NoModules/Chapter 12/Soln12_02/Integer.h
  function class (line 16) | class Integer

FILE: Exercises/NoModules/Chapter 12/Soln12_02/Soln12_02.cpp
  function main (line 20) | int main()

FILE: Exercises/NoModules/Chapter 12/Soln12_03/Integer.cpp
  function Integer (line 16) | Integer& Integer::add(const Integer& obj)
  function Integer (line 22) | Integer& Integer::subtract(const Integer& obj)
  function Integer (line 28) | Integer& Integer::multiply(const Integer& obj)

FILE: Exercises/NoModules/Chapter 12/Soln12_03/Integer.h
  function class (line 4) | class Integer

FILE: Exercises/NoModules/Chapter 12/Soln12_03/Soln12_03.cpp
  function main (line 16) | int main()

FILE: Exercises/NoModules/Chapter 12/Soln12_04/Integer.cpp
  function compare (line 38) | int compare(const Integer& obj1, const Integer& obj2)
  function nonFriendCompare (line 49) | int nonFriendCompare(const Integer& obj1, const Integer& obj2)

FILE: Exercises/NoModules/Chapter 12/Soln12_04/Integer.h
  function setValue (line 11) | void setValue(int value) { m_value = value; }

FILE: Exercises/NoModules/Chapter 12/Soln12_04/Soln12_04.cpp
  function main (line 5) | int main()

FILE: Exercises/NoModules/Chapter 12/Soln12_05/Integer.h
  function class (line 4) | class Integer

FILE: Exercises/NoModules/Chapter 12/Soln12_05/Soln12_05.cpp
  function showIntegerVal (line 5) | void showIntegerVal(Integer it)
  function showIntegerRef (line 10) | void showIntegerRef(const Integer& it)
  function main (line 16) | int main()

FILE: Exercises/NoModules/Chapter 12/Soln12_06/Box.h
  function compare (line 19) | int compare(const Box& box) const
  function m_height (line 34) | double m_height {1.0};

FILE: Exercises/NoModules/Chapter 12/Soln12_06/RandomBoxes.h
  function dimLimit (line 20) | const int dimLimit{ 100 };          // Upper limit on Box dimensions

FILE: Exercises/NoModules/Chapter 12/Soln12_06/Soln12_06.cpp
  function main (line 25) | int main()
  function SharedBox (line 69) | SharedBox findLargestBox(const Truckload& truckload)
  function SharedBox (line 85) | SharedBox findSmallestBox(const Truckload& truckload)

FILE: Exercises/NoModules/Chapter 12/Soln12_06/Truckload.cpp
  class Truckload::Package (line 8) | class Truckload::Package
    method Package (line 14) | Package(SharedBox box) : m_box{ box }, m_next{ nullptr } {}
  function SharedBox (line 64) | SharedBox Truckload::Iterator::getFirstBox()
  function SharedBox (line 72) | SharedBox Truckload::Iterator::getNextBox()

FILE: Exercises/NoModules/Chapter 12/Soln12_06/Truckload.h
  function class (line 11) | class Truckload
  function explicit (line 51) | explicit Iterator(Package* head) : m_head{ head }, m_current{ nullptr } {}

FILE: Exercises/NoModules/Chapter 12/Soln12_07/Box.h
  function compare (line 19) | int compare(const Box& box) const
  function m_height (line 34) | double m_height {1.0};

FILE: Exercises/NoModules/Chapter 12/Soln12_07/RandomBoxes.h
  function dimLimit (line 20) | const int dimLimit{ 100 };          // Upper limit on Box dimensions

FILE: Exercises/NoModules/Chapter 12/Soln12_07/Soln12_07.cpp
  function main (line 12) | int main()
  function SharedBox (line 38) | SharedBox findLargestBox(const Truckload& truckload)
  function SharedBox (line 54) | SharedBox findSmallestBox(const Truckload& truckload)

FILE: Exercises/NoModules/Chapter 12/Soln12_07/Truckload.cpp
  class Truckload::Package (line 8) | class Truckload::Package
    method Package (line 15) | Package(SharedBox box) : m_box{ box }, m_next{}, m_previous{} {}
  function SharedBox (line 80) | SharedBox Truckload::Iterator::getFirstBox()
  function SharedBox (line 87) | SharedBox Truckload::Iterator::getLastBox()
  function SharedBox (line 94) | SharedBox Truckload::Iterator::getNextBox()
  function SharedBox (line 104) | SharedBox Truckload::Iterator::getPreviousBox()

FILE: Exercises/NoModules/Chapter 12/Soln12_07/Truckload.h
  function class (line 11) | class Truckload

FILE: Exercises/NoModules/Chapter 12/Soln12_08/Box.h
  function compare (line 19) | int compare(const Box& box) const
  function m_height (line 34) | double m_height {1.0};

FILE: Exercises/NoModules/Chapter 12/Soln12_08/RandomBoxes.h
  function dimLimit (line 20) | const int dimLimit{ 100 };          // Upper limit on Box dimensions

FILE: Exercises/NoModules/Chapter 12/Soln12_08/Soln12_08.cpp
  function main (line 32) | int main()
  function findLargestBox (line 68) | Truckload::Iterator findLargestBox(const Truckload& truckload)
  function findSmallestBox (line 85) | Truckload::Iterator findSmallestBox(const Truckload& truckload)

FILE: Exercises/NoModules/Chapter 12/Soln12_08/Truckload.cpp
  class Truckload::Package (line 8) | class Truckload::Package
    method Package (line 15) | Package(SharedBox box) : m_box{ box }, m_next{}, m_previous{} {}
  function SharedBox (line 80) | SharedBox Truckload::Iterator::getFirstBox()
  function SharedBox (line 87) | SharedBox Truckload::Iterator::getLastBox()
  function SharedBox (line 94) | SharedBox Truckload::Iterator::getNextBox()
  function SharedBox (line 104) | SharedBox Truckload::Iterator::getPreviousBox()
  function SharedBox (line 114) | SharedBox Truckload::Iterator::getCurrentBox() const

FILE: Exercises/NoModules/Chapter 12/Soln12_08/Truckload.h
  function class (line 11) | class Truckload

FILE: Exercises/NoModules/Chapter 13/Soln13_01/Box.cpp
  function Box (line 11) | Box Box::operator+(const Box& aBox) const
  function Box (line 19) | Box Box::operator*(double factor) const

FILE: Exercises/NoModules/Chapter 13/Soln13_01/Box.h
  function m_height (line 35) | double m_height {1.0};

FILE: Exercises/NoModules/Chapter 13/Soln13_01/Soln13_01.cpp
  function main (line 7) | int main()

FILE: Exercises/NoModules/Chapter 13/Soln13_02/Box.cpp
  function Box (line 11) | Box Box::operator+(const Box& aBox) const
  function Box (line 19) | Box Box::operator*(double factor) const
  function Box (line 24) | Box operator*(double factor, const Box& box)

FILE: Exercises/NoModules/Chapter 13/Soln13_02/Box.h
  function m_height (line 35) | double m_height {1.0};

FILE: Exercises/NoModules/Chapter 13/Soln13_02/Soln13_02.cpp
  function main (line 6) | int main()

FILE: Exercises/NoModules/Chapter 13/Soln13_03/Box.cpp
  function Box (line 11) | Box Box::operator+(const Box& aBox) const
  function Box (line 18) | Box Box::operator*(double factor) const
  function Box (line 25) | Box Box::operator/(double divisor) const
  function Box (line 32) | Box& Box::operator+=(const Box& aBox)
  function Box (line 41) | Box& Box::operator*=(double factor)
  function Box (line 49) | Box& Box::operator/=(double divisor)
  function Box (line 57) | Box operator*(double factor, const Box& box)

FILE: Exercises/NoModules/Chapter 13/Soln13_03/Box.h
  function m_height (line 40) | double m_height {1.0};

FILE: Exercises/NoModules/Chapter 13/Soln13_03/Soln13_03.cpp
  function main (line 6) | int main()

FILE: Exercises/NoModules/Chapter 13/Soln13_04/Box.h
  function class (line 8) | class Box
  function m_height (line 41) | double m_height{ 1.0 };

FILE: Exercises/NoModules/Chapter 13/Soln13_04/Soln13_04.cpp
  function main (line 12) | int main()

FILE: Exercises/NoModules/Chapter 13/Soln13_05/Box.h
  function class (line 8) | class Box
  function m_height (line 42) | double m_height{ 1.0 };

FILE: Exercises/NoModules/Chapter 13/Soln13_05/Soln13_05.cpp
  function testBox (line 8) | void testBox(const Box& box)
  function main (line 18) | int main()

FILE: Exercises/NoModules/Chapter 13/Soln13_06/Box.h
  function class (line 8) | class Box
  function m_height (line 39) | double m_height{ 1.0 };

FILE: Exercises/NoModules/Chapter 13/Soln13_06/Soln13_06.cpp
  function testBox (line 15) | void testBox(const Box& box)
  function main (line 25) | int main()

FILE: Exercises/NoModules/Chapter 13/Soln13_07/Rational.h
  function class (line 7) | class Rational
  function setNumerator (line 20) | void setNumerator(int numerator) { m_numerator = numerator; }
  function setDenominator (line 21) | void setDenominator(int denominator) { m_denominator = denominator; }
  function operator (line 35) | auto operator<=>(double value)
  function operator (line 43) | bool operator==(double value)

FILE: Exercises/NoModules/Chapter 13/Soln13_07/Soln13_07.cpp
  function main (line 6) | int main()

FILE: Exercises/NoModules/Chapter 13/Soln13_08/Box.cpp
  function Box (line 12) | Box& Box::operator+=(const Box& aBox)
  function Box (line 22) | Box Box::operator+(const Box& aBox) const

FILE: Exercises/NoModules/Chapter 13/Soln13_08/Box.h
  function m_height (line 35) | double m_height {1.0};

FILE: Exercises/NoModules/Chapter 13/Soln13_08/PRNG.h
  function class (line 4) | class PseudoRandomNumberGenerator

FILE: Exercises/NoModules/Chapter 13/Soln13_08/Soln13_08.cpp
  function main (line 14) | int main()

FILE: Exercises/NoModules/Chapter 13/Soln13_09/Box.h
  function compare (line 20) | int compare(const Box& box) const
  function m_height (line 42) | double m_height {1.0};

FILE: Exercises/NoModules/Chapter 13/Soln13_09/Soln13_09.cpp
  function createUniformPseudoRandomNumberGenerator (line 10) | auto createUniformPseudoRandomNumberGenerator(double max)
  function main (line 18) | int main()

FILE: Exercises/NoModules/Chapter 13/Soln13_09/Truckload.cpp
  class Truckload::Package (line 8) | class Truckload::Package
    method Package (line 14) | Package(SharedBox box) : m_box{ box }, m_next{ nullptr } {}
  function Truckload (line 42) | Truckload& Truckload::operator=(const Truckload& other)
  function SharedBox (line 70) | SharedBox Truckload::Iterator::getFirstBox()
  function SharedBox (line 78) | SharedBox Truckload::Iterator::getNextBox()
  function SharedBox (line 128) | SharedBox& Truckload::operator[](size_t index) const

FILE: Exercises/NoModules/Chapter 13/Soln13_09/Truckload.h
  function class (line 12) | class Truckload
  function explicit (line 56) | explicit Iterator(Package* head) : m_head{ head }, m_current{ nullptr } {}

FILE: Exercises/NoModules/Chapter 14/Soln14_01/Animals.h
  function class (line 16) | class Animal
  function class (line 36) | class Aardvark : public Animal

FILE: Exercises/NoModules/Chapter 14/Soln14_01/Soln14_01.cpp
  function main (line 5) | int main()

FILE: Exercises/NoModules/Chapter 14/Soln14_02/Animals.h
  function class (line 9) | class Animal
  function class (line 22) | class Lion : public Animal
  function class (line 34) | class Aardvark : public Animal

FILE: Exercises/NoModules/Chapter 14/Soln14_02/Soln14_02.cpp
  function main (line 7) | int main()

FILE: Exercises/NoModules/Chapter 14/Soln14_03/Animals.h
  function class (line 9) | class Animal
  function class (line 21) | class Lion : public Animal
  function class (line 31) | class Aardvark : public Animal

FILE: Exercises/NoModules/Chapter 14/Soln14_03/Soln14_03.cpp
  function main (line 7) | int main()

FILE: Exercises/NoModules/Chapter 14/Soln14_04/Person.h
  type class (line 27) | enum class
  function who (line 35) | void who() const;     // Display details
  function Gender (line 51) | Gender m_gender{ Gender::female };
  function class (line 54) | class Employee : public Person
  function class (line 70) | class Executive : public Employee

FILE: Exercises/NoModules/Chapter 14/Soln14_04/Soln14_04.cpp
  function main (line 7) | int main()

FILE: Exercises/NoModules/Chapter 15/Soln15_01/Animals.h
  function virtual (line 14) | virtual std::string who() const;               // Return string containi...
  function class (line 29) | class Dog : public Animal
  function class (line 36) | class Cow : public Animal

FILE: Exercises/NoModules/Chapter 15/Soln15_01/Soln15_01.cpp
  function createUniformPseudoRandomNumberGenerator (line 13) | auto createUniformPseudoRandomNumberGenerator(unsigned min, unsigned max)
  function main (line 21) | int main()

FILE: Exercises/NoModules/Chapter 15/Soln15_01/Zoo.h
  function class (line 11) | class Zoo

FILE: Exercises/NoModules/Chapter 15/Soln15_02/Animals.h
  function class (line 8) | class Animal
  function class (line 26) | class Sheep : public Animal
  function class (line 39) | class Dog : public Animal
  function class (line 47) | class Cow : public Animal

FILE: Exercises/NoModules/Chapter 15/Soln15_02/Soln15_02.cpp
  function createUniformPseudoRandomNumberGenerator (line 13) | auto createUniformPseudoRandomNumberGenerator(unsigned min, unsigned max)
  function main (line 21) | int main()

FILE: Exercises/NoModules/Chapter 15/Soln15_02/Zoo.h
  function class (line 11) | class Zoo

FILE: Exercises/NoModules/Chapter 15/Soln15_03/Animals.h
  function class (line 8) | class Animal
  function class (line 26) | class Sheep : public Animal
  function class (line 42) | class Dog : public Animal
  function class (line 50) | class Cow : public Animal

FILE: Exercises/NoModules/Chapter 15/Soln15_03/Soln15_03.cpp
  function createUniformPseudoRandomNumberGenerator (line 13) | auto createUniformPseudoRandomNumberGenerator(unsigned min, unsigned max)
  function main (line 21) | int main()

FILE: Exercises/NoModules/Chapter 15/Soln15_03/Zoo.h
  function class (line 11) | class Zoo

FILE: Exercises/NoModules/Chapter 15/Soln15_04/Animals.h
  function class (line 9) | class Animal
  function class (line 28) | class Sheep : public Animal
  function class (line 45) | class Dog : public Animal
  function class (line 53) | class Cow : public Animal

FILE: Exercises/NoModules/Chapter 15/Soln15_04/Soln15_04.cpp
  function createUniformPseudoRandomNumberGenerator (line 13) | auto createUniformPseudoRandomNumberGenerator(unsigned min, unsigned max)
  function main (line 21) | int main()

FILE: Exercises/NoModules/Chapter 15/Soln15_04/Zoo.h
  function class (line 11) | class Zoo

FILE: Exercises/NoModules/Chapter 15/Soln15_05/Animals.h
  function class (line 9) | class Animal
  function class (line 28) | class Sheep : public Animal
  function class (line 45) | class Dog : public Animal
  function class (line 53) | class Cow : public Animal

FILE: Exercises/NoModules/Chapter 15/Soln15_05/Soln15_05.cpp
  function createUniformPseudoRandomNumberGenerator (line 13) | auto createUniformPseudoRandomNumberGenerator(unsigned min, unsigned max)
  function main (line 21) | int main()

FILE: Exercises/NoModules/Chapter 15/Soln15_05/Zoo.h
  function class (line 12) | class Zoo

FILE: Exercises/NoModules/Chapter 15/Soln15_06/Point.h
  function class (line 5) | class Point final
  function setX (line 13) | void setX(double x) { m_x = x; }
  function setY (line 14) | void setY(double y) { m_y = y; }

FILE: Exercises/NoModules/Chapter 15/Soln15_06/Shapes.h
  function class (line 9) | class Shape
  function perimeter (line 36) | double perimeter() const override
  function scale (line 59) | void scale(double factor) override

FILE: Exercises/NoModules/Chapter 15/Soln15_06/Soln15_06.cpp
  function main (line 10) | int main()
  function calculateSumAreas (line 29) | double calculateSumAreas(const std::vector<Shape*>& shapes)
  function calculateSumPerimeters (line 39) | double calculateSumPerimeters(const std::vector<Shape*>& shapes)
  function printSums (line 49) | void printSums(const std::vector<Shape*>& shapes)

FILE: Exercises/NoModules/Chapter 16/Exer16_06/Customer.h
  function class (line 9) | class Customer

FILE: Exercises/NoModules/Chapter 16/Exer16_06/DB.cpp
  type QueryResult (line 10) | struct QueryResult
  class Database (line 16) | class Database
    method Database (line 19) | Database() = default;
    method hasConnection (line 21) | bool hasConnection() const { return m_connected; }
    method connect (line 22) | void connect() { m_connected = true; }
    method disconnect (line 23) | void disconnect() { m_connected = false; }
  function DB_CONNECTION (line 32) | DB_CONNECTION* db_connect()
  function db_disconnect (line 47) | void db_disconnect(DB_CONNECTION* connection)
  function DB_QUERY_RESULT (line 54) | DB_QUERY_RESULT* db_query(DB_CONNECTION* connection, const char* query)
  function QueryResult (line 59) | QueryResult* Database::query(const char* query)
  function db_num_fields (line 84) | int db_num_fields(DB_QUERY_RESULT* result)
  function DB_ROW (line 97) | DB_ROW db_fetch_row(DB_QUERY_RESULT* result)
  function db_free_result (line 110) | void db_free_result(DB_QUERY_RESULT* result)

FILE: Exercises/NoModules/Chapter 16/Exer16_06/DBException.h
  function class (line 8) | class DatabaseException : public std::runtime_error

FILE: Exercises/NoModules/Chapter 16/Exer16_06/Exer16_06.cpp
  function main (line 17) | int main()
  function readCustomers (line 54) | std::vector<Customer> readCustomers(DB_QUERY_RESULT* result)
  function verifyCustomerFields (line 80) | void verifyCustomerFields(DB_QUERY_RESULT* result)
  function print (line 93) | void print(std::ostream& stream, const Customer& customer)

FILE: Exercises/NoModules/Chapter 16/Soln16_01/Curveball.h
  function class (line 7) | class Curveball : public std::exception

FILE: Exercises/NoModules/Chapter 16/Soln16_01/Soln16_01.cpp
  function main (line 11) | int main()
  function createUniformPseudoRandomNumberGenerator (line 33) | auto createUniformPseudoRandomNumberGenerator(double min, double max)
  function throwCurveballSometimes (line 42) | void throwCurveballSometimes()
  function createUniformPseudoRandomBooleanGenerator (line 56) | auto createUniformPseudoRandomBooleanGenerator(double probabilityOfTrue)
  function throwCurveballSometimesBernouilli (line 65) | void throwCurveballSometimesBernouilli()

FILE: Exercises/NoModules/Chapter 16/Soln16_02/Curveball.h
  function class (line 7) | class Curveball : public std::exception

FILE: Exercises/NoModules/Chapter 16/Soln16_02/Soln16_02.cpp
  function main (line 13) | int main()
  function createUniformPseudoRandomBooleanGenerator (line 36) | auto createUniformPseudoRandomBooleanGenerator(double probabilityOfTrue)
  function throwCurveballSometimes (line 45) | void throwCurveballSometimes()

FILE: Exercises/NoModules/Chapter 16/Soln16_02/TooManyExceptions.h
  function class (line 13) | class TooManyExceptions : public std::exception

FILE: Exercises/NoModules/Chapter 16/Soln16_03/Box.h
  function m_height (line 27) | double m_height {1.0};

FILE: Exercises/NoModules/Chapter 16/Soln16_03/RandomBoxes.h
  function dimLimit (line 20) | const int dimLimit{ 100 };          // Upper limit on Box dimensions

FILE: Exercises/NoModules/Chapter 16/Soln16_03/Soln16_03.cpp
  function main (line 7) | int main()

FILE: Exercises/NoModules/Chapter 16/Soln16_03/Truckload.cpp
  class Truckload::Package (line 10) | class Truckload::Package
    method Package (line 16) | Package(SharedBox box) : m_box{ box }, m_next{ nullptr } {}
  function Truckload (line 44) | Truckload& Truckload::operator=(const Truckload& other)
  function SharedBox (line 72) | SharedBox Truckload::Iterator::getFirstBox()
  function SharedBox (line 80) | SharedBox Truckload::Iterator::getNextBox()
  function SharedBox (line 130) | SharedBox& Truckload::operator[](size_t index) const

FILE: Exercises/NoModules/Chapter 16/Soln16_03/Truckload.h
  function class (line 12) | class Truckload
  function explicit (line 54) | explicit Iterator(Package* head) : m_head{ head }, m_current{ nullptr } {}

FILE: Exercises/NoModules/Chapter 16/Soln16_04/Soln16_04.cpp
  class BaseClass (line 21) | class BaseClass
  class DerivedClass1 (line 27) | class DerivedClass1 : public BaseClass {}
  class DerivedClass2 (line 28) | class DerivedClass2 : public BaseClass {}
  function main (line 30) | int main()

FILE: Exercises/NoModules/Chapter 16/Soln16_05/Curveball.h
  function class (line 7) | class Curveball : public std::exception

FILE: Exercises/NoModules/Chapter 16/Soln16_05/DomainExceptions.h
  function class (line 16) | class NotANumber : public std::domain_error
  function class (line 24) | class NegativeNumber : public std::domain_error
  function class (line 32) | class OddNumber : public std::domain_error

FILE: Exercises/NoModules/Chapter 16/Soln16_05/Soln16_05.cpp
  function main (line 16) | int main()
  function askEvenNumber (line 34) | void askEvenNumber()
  function readEvenNumber (line 90) | int readEvenNumber()
  function createUniformPseudoRandomBooleanGenerator (line 113) | auto createUniformPseudoRandomBooleanGenerator(double probabilityOfTrue)
  function throwCurveballSometimes (line 122) | void throwCurveballSometimes()

FILE: Exercises/NoModules/Chapter 16/Soln16_06/Customer.h
  function class (line 9) | class Customer

FILE: Exercises/NoModules/Chapter 16/Soln16_06/DB.cpp
  type QueryResult (line 10) | struct QueryResult
  class Database (line 16) | class Database
    method Database (line 19) | Database() = default;
    method hasConnection (line 21) | bool hasConnection() const { return m_connected; }
    method connect (line 22) | void connect() { m_connected = true; }
    method disconnect (line 23) | void disconnect() { m_connected = false; }
  function DB_CONNECTION (line 32) | DB_CONNECTION* db_connect()
  function db_disconnect (line 47) | void db_disconnect(DB_CONNECTION* connection)
  function DB_QUERY_RESULT (line 54) | DB_QUERY_RESULT* db_query(DB_CONNECTION* connection, const char* query)
  function QueryResult (line 59) | QueryResult* Database::query(const char* query)
  function db_num_fields (line 84) | int db_num_fields(DB_QUERY_RESULT* result)
  function DB_ROW (line 97) | DB_ROW db_fetch_row(DB_QUERY_RESULT* result)
  function db_free_result (line 110) | void db_free_result(DB_QUERY_RESULT* result)

FILE: Exercises/NoModules/Chapter 16/Soln16_06/DBException.h
  function class (line 8) | class DatabaseException : public std::runtime_error

FILE: Exercises/NoModules/Chapter 16/Soln16_06/DB_RAII.h
  function class (line 18) | class DBConnectionRAII

FILE: Exercises/NoModules/Chapter 16/Soln16_06/Soln16_06.cpp
  function main (line 43) | int main()
  function readCustomers (line 74) | std::vector<Customer> readCustomers(DB_QUERY_RESULT* result)
  function verifyCustomerFields (line 100) | void verifyCustomerFields(DB_QUERY_RESULT* result)
  function print (line 113) | void print(std::ostream& stream, const Customer& customer)

FILE: Exercises/NoModules/Chapter 17/Soln17_01/Array.h
  function new (line 36) | new T[size] {}
  function m_size (line 36) | m_size {size}

FILE: Exercises/NoModules/Chapter 17/Soln17_01/Soln17_01.cpp
  function main (line 6) | int main()

FILE: Exercises/NoModules/Chapter 17/Soln17_02/Soln17_02.cpp
  function main (line 7) | int main()

FILE: Exercises/NoModules/Chapter 17/Soln17_03/Soln17_03.cpp
  function main (line 6) | int main()

FILE: Exercises/NoModules/Chapter 17/Soln17_04/Soln17_04.cpp
  function createUniformPseudoRandomNumberGenerator (line 17) | auto createUniformPseudoRandomNumberGenerator(int min, int max)
  function main (line 25) | int main()

FILE: Exercises/NoModules/Chapter 17/Soln17_04/SparseArray.h
  function throw (line 53) | throw std::out_of_range{"No value exists at index " + std::to_string(ind...

FILE: Exercises/NoModules/Chapter 17/Soln17_05/LinkedList.h
  function T (line 34) | const T& front() const;                      // Get the object at the he...
  function Node (line 61) | Node* m_tail{}
  function m_size (line 62) | size_t m_size{}
  function Node (line 154) | Node* oldHead{ m_head };
  function Node (line 173) | Node* oldTail{ m_tail };
  function next (line 257) | void next() { m_current = m_current->m_next; }
  function previous (line 258) | void previous() { m_current = m_current->m_previous; }

FILE: Exercises/NoModules/Chapter 17/Soln17_05/Soln17_05.cpp
  function main (line 8) | int main()

FILE: Exercises/NoModules/Chapter 17/Soln17_06/LinkedList.h
  function T (line 34) | const T& front() const;                      // Get the object at the he...
  function Node (line 61) | Node* m_tail{}
  function m_size (line 62) | size_t m_size{}
  function Node (line 154) | Node* oldHead{ m_head };
  function Node (line 173) | Node* oldTail{ m_tail };
  function next (line 257) | void next() { m_current = m_current->m_next; }
  function previous (line 258) | void previous() { m_current = m_current->m_previous; }

FILE: Exercises/NoModules/Chapter 17/Soln17_06/Soln17_06.cpp
  function main (line 10) | int main()

FILE: Exercises/NoModules/Chapter 17/Soln17_06/SparseArray.h
  function throw (line 53) | throw std::out_of_range{"No value exists at index " + std::to_string(ind...

FILE: Exercises/NoModules/Chapter 17/Soln17_07/Box.h
  function m_height (line 23) | double m_height {1.0};

FILE: Exercises/NoModules/Chapter 17/Soln17_07/BoxFormatter.h
  function iter (line 27) | auto iter{ std::format_to(context.out(), "Box(") };

FILE: Exercises/NoModules/Chapter 17/Soln17_07/Soln17_07.cpp
  function main (line 6) | int main()

FILE: Exercises/NoModules/Chapter 17/Soln17_07A/Box.h
  function m_height (line 23) | double m_height {1.0};

FILE: Exercises/NoModules/Chapter 17/Soln17_07A/BoxFormatter.h
  function iter (line 28) | auto iter{ context.begin() };

FILE: Exercises/NoModules/Chapter 17/Soln17_07A/Soln17_07A.cpp
  function main (line 7) | int main()

FILE: Exercises/NoModules/Chapter 18/Soln18_01/Box.h
  function m_height (line 27) | double m_height {1.0};

FILE: Exercises/NoModules/Chapter 18/Soln18_01/RandomBoxes.h
  function dimLimit (line 20) | const int dimLimit{ 100 };          // Upper limit on Box dimensions

FILE: Exercises/NoModules/Chapter 18/Soln18_01/Soln18_01.cpp
  function main (line 14) | int main()

FILE: Exercises/NoModules/Chapter 18/Soln18_01/Truckload.cpp
  class Truckload::Package (line 11) | class Truckload::Package
    method Package (line 17) | Package(SharedBox box) : m_box{ box }, m_next{ nullptr } {}
  function Truckload (line 52) | Truckload& Truckload::operator=(const Truckload& src)
  function Truckload (line 69) | Truckload& Truckload::operator=(Truckload&& src) noexcept
  function swap (line 84) | void swap(Truckload& one, Truckload& other) noexcept
  function SharedBox (line 92) | SharedBox Truckload::Iterator::getFirstBox()
  function SharedBox (line 100) | SharedBox Truckload::Iterator::getNextBox()
  function SharedBox (line 150) | SharedBox& Truckload::operator[](size_t index) const

FILE: Exercises/NoModules/Chapter 18/Soln18_01/Truckload.h
  function class (line 12) | class Truckload
  function explicit (line 58) | explicit Iterator(Package* head) : m_head{ head }, m_current{ nullptr } {}

FILE: Exercises/NoModules/Chapter 18/Soln18_02/LinkedList.h
  function T (line 57) | const T& front() const;                  // Get the object at the head (...
  function Node (line 229) | Node* oldHead{ m_head };
  function Node (line 248) | Node* oldTail{ m_tail };
  function next (line 332) | void next() { m_current = m_current->m_next; }
  function previous (line 333) | void previous() { m_current = m_current->m_previous; }

FILE: Exercises/NoModules/Chapter 18/Soln18_02/Soln18_02.cpp
  function printList (line 9) | void printList(std::string_view message, const LinkedList<std::unique_pt...
  function main (line 19) | int main()

FILE: Exercises/NoModules/Chapter 18/Soln18_03/Customer.h
  function class (line 9) | class Customer

FILE: Exercises/NoModules/Chapter 18/Soln18_03/DB.cpp
  type QueryResult (line 10) | struct QueryResult
  class Database (line 16) | class Database
    method Database (line 19) | Database() = default;
    method hasConnection (line 21) | bool hasConnection() const { return m_connected; }
    method connect (line 22) | void connect() { m_connected = true; }
    method disconnect (line 23) | void disconnect() { m_connected = false; }
  function DB_CONNECTION (line 32) | DB_CONNECTION* db_connect()
  function db_disconnect (line 47) | void db_disconnect(DB_CONNECTION* connection)
  function DB_QUERY_RESULT (line 54) | DB_QUERY_RESULT* db_query(DB_CONNECTION* connection, const char* query)
  function QueryResult (line 59) | QueryResult* Database::query(const char* query)
  function db_num_fields (line 84) | int db_num_fields(DB_QUERY_RESULT* result)
  function DB_ROW (line 97) | DB_ROW db_fetch_row(DB_QUERY_RESULT* result)
  function db_free_result (line 110) | void db_free_result(DB_QUERY_RESULT* result)

FILE: Exercises/NoModules/Chapter 18/Soln18_03/DBException.h
  function class (line 8) | class DatabaseException : public std::runtime_error

FILE: Exercises/NoModules/Chapter 18/Soln18_03/DB_RAII.h
  function class (line 22) | class DBConnectionRAII
  function class (line 51) | class DBQueryResultRAII

FILE: Exercises/NoModules/Chapter 18/Soln18_03/Soln18_03.cpp
  function main (line 19) | int main()
  function readCustomers (line 63) | std::vector<Customer> readCustomers(DB_QUERY_RESULT* result)
  function verifyCustomerFields (line 89) | void verifyCustomerFields(DB_QUERY_RESULT* result)
  function print (line 102) | void print(std::ostream& stream, const Customer& customer)

FILE: Exercises/NoModules/Chapter 18/Soln18_04/Customer.h
  function class (line 9) | class Customer

FILE: Exercises/NoModules/Chapter 18/Soln18_04/DB.cpp
  type QueryResult (line 10) | struct QueryResult
  class Database (line 16) | class Database
    method Database (line 19) | Database() = default;
    method hasConnection (line 21) | bool hasConnection() const { return m_connected; }
    method connect (line 22) | void connect() { m_connected = true; }
    method disconnect (line 23) | void disconnect() { m_connected = false; }
  function DB_CONNECTION (line 32) | DB_CONNECTION* db_connect()
  function db_disconnect (line 47) | void db_disconnect(DB_CONNECTION* connection)
  function DB_QUERY_RESULT (line 54) | DB_QUERY_RESULT* db_query(DB_CONNECTION* connection, const char* query)
  function QueryResult (line 59) | QueryResult* Database::query(const char* query)
  function db_num_fields (line 84) | int db_num_fields(DB_QUERY_RESULT* result)
  function DB_ROW (line 97) | DB_ROW db_fetch_row(DB_QUERY_RESULT* result)
  function db_free_result (line 110) | void db_free_result(DB_QUERY_RESULT* result)

FILE: Exercises/NoModules/Chapter 18/Soln18_04/DBException.h
  function class (line 8) | class DatabaseException : public std::runtime_error

FILE: Exercises/NoModules/Chapter 18/Soln18_04/DB_RAII.h
  function class (line 23) | class DBConnectionRAII
  function class (line 66) | class DBQueryResultRAII

FILE: Exercises/NoModules/Chapter 18/Soln18_04/Soln18_04.cpp
  function main (line 19) | int main()
  function readCustomers (line 55) | std::vector<Customer> readCustomers(DB_QUERY_RESULT* result)
  function verifyCustomerFields (line 81) | void verifyCustomerFields(DB_QUERY_RESULT* result)
  function print (line 94) | void print(std::ostream& stream, const Customer& customer)

FILE: Exercises/NoModules/Chapter 18/Soln18_05/Customer.h
  function class (line 9) | class Customer

FILE: Exercises/NoModules/Chapter 18/Soln18_05/DB.cpp
  type QueryResult (line 10) | struct QueryResult
  class Database (line 16) | class Database
    method Database (line 19) | Database() = default;
    method hasConnection (line 21) | bool hasConnection() const { return m_connected; }
    method connect (line 22) | void connect() { m_connected = true; }
    method disconnect (line 23) | void disconnect() { m_connected = false; }
  function DB_CONNECTION (line 32) | DB_CONNECTION* db_connect()
  function db_disconnect (line 47) | void db_disconnect(DB_CONNECTION* connection)
  function DB_QUERY_RESULT (line 54) | DB_QUERY_RESULT* db_query(DB_CONNECTION* connection, const char* query)
  function QueryResult (line 59) | QueryResult* Database::query(const char* query)
  function db_num_fields (line 84) | int db_num_fields(DB_QUERY_RESULT* result)
  function DB_ROW (line 97) | DB_ROW db_fetch_row(DB_QUERY_RESULT* result)
  function db_free_result (line 110) | void db_free_result(DB_QUERY_RESULT* result)

FILE: Exercises/NoModules/Chapter 18/Soln18_05/DBException.h
  function class (line 8) | class DatabaseException : public std::runtime_error

FILE: Exercises/NoModules/Chapter 18/Soln18_05/DB_RAII.h
  function class (line 66) | class DBQueryResultRAII

FILE: Exercises/NoModules/Chapter 18/Soln18_05/Soln18_05.cpp
  function main (line 16) | int main()
  function readCustomers (line 52) | std::vector<Customer> readCustomers(DB_QUERY_RESULT* result)
  function verifyCustomerFields (line 78) | void verifyCustomerFields(DB_QUERY_RESULT* result)
  function print (line 91) | void print(std::ostream& stream, const Customer& customer)

FILE: Exercises/NoModules/Chapter 19/Soln19_01/Soln19_01.cpp
  function main (line 9) | int main()

FILE: Exercises/NoModules/Chapter 19/Soln19_02/Soln19_02.cpp
  function list (line 13) | void list(const std::vector<T>& values, size_t width = 5)
  function main (line 20) | int main()

FILE: Exercises/NoModules/Chapter 19/Soln19_03/Soln19_03.cpp
  function createUniformPseudoRandomNumberGenerator (line 26) | auto createUniformPseudoRandomNumberGenerator()
  function generateRandomNumbers (line 34) | auto generateRandomNumbers(unsigned number)
  function main (line 43) | int main()

FILE: Exercises/NoModules/Chapter 19/Soln19_03/Sort.h
  function swapped (line 66) | bool swapped{ false };    // Becomes true when not all values are in order

FILE: Exercises/NoModules/Chapter 19/Soln19_04/Soln19_04.cpp
  function list (line 22) | void list(const std::vector<T>& values, size_t width = 5)
  function is_palindrome (line 29) | bool is_palindrome(std::string_view s)
  function main (line 35) | int main()

FILE: Exercises/NoModules/Chapter 19/Soln19_05/Box.h
  function m_height (line 27) | double m_height {1.0};

FILE: Exercises/NoModules/Chapter 19/Soln19_05/DeliveryTruck.h
  function class (line 9) | class DeliveryTruck

FILE: Exercises/NoModules/Chapter 19/Soln19_05/RandomBoxes.h
  function dimLimit (line 20) | const int dimLimit{ 100 };          // Upper limit on Box dimensions

FILE: Exercises/NoModules/Chapter 19/Soln19_05/Soln19_05.cpp
  function logDelivary (line 10) | void logDelivary(SharedBox box)
  function main (line 15) | int main()

FILE: Exercises/NoModules/Chapter 19/Soln19_05/Truckload.cpp
  class Truckload::Package (line 10) | class Truckload::Package
    method Package (line 16) | Package(SharedBox box) : m_box{ box }, m_next{ nullptr } {}
  function Truckload (line 44) | Truckload& Truckload::operator=(const Truckload& other)
  function SharedBox (line 72) | SharedBox Truckload::Iterator::getFirstBox()
  function SharedBox (line 80) | SharedBox Truckload::Iterator::getNextBox()
  function SharedBox (line 130) | SharedBox& Truckload::operator[](size_t index) const

FILE: Exercises/NoModules/Chapter 19/Soln19_05/Truckload.h
  function class (line 12) | class Truckload
  function explicit (line 54) | explicit Iterator(Package* head) : m_head{ head }, m_current{ nullptr } {}

FILE: Exercises/NoModules/Chapter 20/Soln20_01/Box.h
  function m_height (line 27) | double m_height {1.0};

FILE: Exercises/NoModules/Chapter 20/Soln20_01/RandomBoxes.h
  function dimLimit (line 20) | const int dimLimit{ 100 };          // Upper limit on Box dimensions

FILE: Exercises/NoModules/Chapter 20/Soln20_01/Soln20_01.cpp
  function main (line 14) | int main()

FILE: Exercises/NoModules/Chapter 20/Soln20_01/Truckload.cpp
  function swap (line 25) | void swap(Truckload& one, Truckload& other) noexcept
  function SharedBox (line 33) | SharedBox Truckload::Iterator::getFirstBox()
  function SharedBox (line 41) | SharedBox Truckload::Iterator::getNextBox()
  function SharedBox (line 77) | SharedBox& Truckload::operator[](size_t index)
  function SharedBox (line 83) | SharedBox Truckload::operator[](size_t index) const

FILE: Exercises/NoModules/Chapter 20/Soln20_01/Truckload.h
  function explicit (line 49) | explicit Iterator(const std::vector<SharedBox>& boxes)

FILE: Exercises/NoModules/Chapter 20/Soln20_02/Soln20_02.cpp
  function main (line 14) | int main()

FILE: Exercises/NoModules/Chapter 20/Soln20_03/Soln20_03.cpp
  function main (line 24) | int main()

FILE: Exercises/NoModules/Chapter 20/Soln20_03A/Soln20_03A.cpp
  function main (line 21) | int main()

FILE: Exercises/NoModules/Chapter 20/Soln20_04/Soln20_04.cpp
  function removeEvenNumbers (line 20) | void removeEvenNumbers(std::vector<int>& numbers)
  function main (line 29) | int main()
  function fillVector_1toN (line 42) | std::vector<int> fillVector_1toN(size_t N)
  function printVector (line 50) | void printVector(std::string_view message, const std::vector<int>& numbers)

FILE: Exercises/NoModules/Chapter 20/Soln20_05/Soln20_05.cpp
  function average (line 12) | std::optional<T> average(IterType begin, IterType end)
  function main (line 35) | int main()

FILE: Exercises/NoModules/Chapter 20/Soln20_06/Soln20_06.cpp
  function removeEvenNumbers (line 21) | void removeEvenNumbers(Auto& numbers)    /* Using more elegant std::eras...
  function main (line 26) | int main()
  function fillVector_1toN (line 39) | std::vector<int> fillVector_1toN(size_t N)
  function printVector (line 46) | void printVector(std::string_view message, const std::vector<int>& numbers)

FILE: Exercises/NoModules/Chapter 20/Soln20_07/Soln20_07.cpp
  function printVector (line 11) | void printVector(std::string_view message, Auto& numbers)
  function main (line 18) | int main()

FILE: Exercises/NoModules/Chapter 20/Soln20_08/Soln20_08.cpp
  function createUniformPseudoRandomNumberGenerator (line 12) | auto createUniformPseudoRandomNumberGenerator(unsigned min, unsigned max)
  function main (line 20) | int main()

FILE: Exercises/NoModules/Chapter 20/Soln20_09/Soln20_09.cpp
  function createUniformPseudoRandomNumberGenerator (line 13) | auto createUniformPseudoRandomNumberGenerator(unsigned min, unsigned max)
  function main (line 21) | int main()

FILE: Exercises/NoModules/Chapter 20/Soln20_10/Soln20_10.cpp
  function main (line 7) | int main()

FILE: Exercises/NoModules/Chapter 20/Soln20_11/Soln20_11.cpp
  function isPrime (line 9) | bool isPrime(unsigned number)
  function main (line 20) | int main()

FILE: Exercises/NoModules/Chapter 20/Soln20_12/Soln20_12.cpp
  function isPrime (line 9) | bool isPrime(unsigned number)
  function main (line 20) | int main()

FILE: Exercises/NoModules/Chapter 20/Soln20_13/Soln20_13.cpp
  function maxWordLength (line 27) | size_t maxWordLength(const WordCounts& wordCounts)
  function maxWordLength_1 (line 39) | size_t maxWordLength_1(const WordCounts& wordCounts)
  function maxWordLength_2 (line 52) | size_t maxWordLength_2(const WordCounts& wordCounts)
  function maxWordLength_3 (line 66) | size_t maxWordLength_3(const WordCounts& wordCounts)
  function main (line 84) | int main()
  function Words (line 103) | Words extractWords(std::string_view text, std::string_view separators)
  function WordCounts (line 121) | WordCounts countWords(const Words& words)
  function showWordCounts (line 129) | void showWordCounts(const WordCounts& wordCounts)

FILE: Exercises/NoModules/Chapter 20/Soln20_14/Soln20_14.cpp
  function isPrime (line 10) | bool isPrime(unsigned number)
  function main (line 19) | int main()

FILE: Exercises/NoModules/Chapter 21/Soln21_01/Soln21_01.cpp
  function main (line 78) | int main()

FILE: Exercises/NoModules/Chapter 21/Soln21_02/Soln21_02.cpp
  function Iterator (line 20) | Iterator original_find_optimum(Iterator begin, Iterator end, Comparison ...
  function Iterator (line 38) | Iterator find_optimum(Iterator begin, Sentinel end, Comparison compare =...
  class Box (line 56) | class Box
    method Box (line 59) | Box() : Box{ 1, 1, 1 } {}
    method Box (line 60) | Box(double length, double width, double height)
    method volume (line 64) | double volume() const { return m_length * m_width * m_height; }
    method isSmallerThan (line 65) | double isSmallerThan(const Box& other) const { return volume() < other...
  function main (line 71) | int main()

FILE: Exercises/NoModules/Chapter 21/Soln21_03/Soln21_03.cpp
  function medianOfSorted (line 34) | auto medianOfSorted(std::span<T, N> span)
  function main (line 40) | int main()

FILE: Exercises/NoModules/Chapter 21/Soln21_04/Soln21_04.cpp
  function medianOfSorted (line 55) | auto medianOfSorted(Range&& range)
  function main (line 73) | int main()

FILE: Exercises/NoModules/Chapter 21/Soln21_05/Soln21_05.cpp
  function my_advance (line 10) | auto my_advance(Iter iter, std::iter_difference_t<Iter> n)
  function my_advance (line 16) | auto my_advance(Iter iter, std::iter_difference_t<Iter> n)
  function my_advance (line 24) | auto my_advance(Iter iter, std::iter_difference_t<Iter> n)
  function main (line 30) | int main()

FILE: Exercises/NoModules/Chapter 21/Soln21_06/Array.h
  function noexcept (line 31) | auto&& move_assign_if_noexcept(NoThrowMoveAssignable auto& x) noexcept {...
  function new (line 63) | new T[size] {}
  function m_size (line 63) | m_size {size}

FILE: Exercises/NoModules/Chapter 21/Soln21_06/Soln21_06.cpp
  function buildStringArray (line 6) | Array<std::string> buildStringArray(const size_t size)
  function main (line 14) | int main()
Condensed preview — 1522 files, each showing path, character count, and a content snippet. Download the .json file or copy for the full structured content (1,977K chars).
[
  {
    "path": ".gitmodules",
    "chars": 206,
    "preview": "[submodule \"Workarounds/fmt\"]\n\tpath = Workarounds/fmt\n\turl = https://github.com/fmtlib/fmt.git\n[submodule \"Workarounds/r"
  },
  {
    "path": "Contributing.md",
    "chars": 690,
    "preview": "# Contributing to Apress Source Code\r\n\r\nCopyright for Apress source code belongs to the author(s). However, under fair u"
  },
  {
    "path": "Examples/Modules/Chapter 01/Ex1_01.cpp",
    "chars": 257,
    "preview": "// A complete C++ program\nimport <iostream>;\n\nint main()\n{\n  int answer {42};              // Defines answer with value "
  },
  {
    "path": "Examples/Modules/Chapter 01/Ex1_02.cpp",
    "chars": 139,
    "preview": "// Using escape sequences\nimport <iostream>;\n\nint main()\n{\n  std::cout << \"\\\"Least \\'said\\' \\\\\\n\\t\\tsoonest \\'mended\\'.\\"
  },
  {
    "path": "Examples/Modules/Chapter 02/Ex2_01.cpp",
    "chars": 581,
    "preview": "// Writing values of variables to cout\nimport <iostream>;    // For user input and output through std::cin / cout\n\nint m"
  },
  {
    "path": "Examples/Modules/Chapter 02/Ex2_02.cpp",
    "chars": 1103,
    "preview": "// Converting distances\nimport <iostream>;    // For user input and output through std::cin / cout\n\nint main() \n{\n  unsi"
  },
  {
    "path": "Examples/Modules/Chapter 02/Ex2_03.cpp",
    "chars": 1056,
    "preview": "// Sizing a pond for happy fish\nimport <iostream>;\nimport <numbers>;   // For the pi constant\n\n#include <cmath>    // Fo"
  },
  {
    "path": "Examples/Modules/Chapter 02/Ex2_03A.cpp",
    "chars": 1234,
    "preview": "// Expressions with mixed variables types\n// (The difference with the original example \n//  is the type of fish_count an"
  },
  {
    "path": "Examples/Modules/Chapter 02/Ex2_03B.cpp",
    "chars": 1097,
    "preview": "// Formatting text using std::format()\nimport <iostream>;\nimport <format>;\nimport <numbers>;   // For the pi constant\n\n#"
  },
  {
    "path": "Examples/Modules/Chapter 02/Ex2_03C.cpp",
    "chars": 1100,
    "preview": "// Format specifiers for std::format()\nimport <iostream>;\nimport <format>;\nimport <numbers>;   // For the pi constant\n\n#"
  },
  {
    "path": "Examples/Modules/Chapter 02/Ex2_03D.cpp",
    "chars": 1285,
    "preview": "// Debugging format specifiers for std::format() using try/catch\nimport <iostream>;\nimport <format>;\nimport <numbers>;  "
  },
  {
    "path": "Examples/Modules/Chapter 02/Ex2_04.cpp",
    "chars": 858,
    "preview": "// Using explicit type conversions\nimport <iostream>;\n\nint main()\n{\n  const unsigned feet_per_yard{ 3 };\n  const unsigne"
  },
  {
    "path": "Examples/Modules/Chapter 02/Ex2_05.cpp",
    "chars": 565,
    "preview": "// The width, alignment, fill, and 0 formatting options of std::format() \nimport <iostream>;\nimport <format>;\n\nint main("
  },
  {
    "path": "Examples/Modules/Chapter 02/Ex2_06.cpp",
    "chars": 715,
    "preview": "// Formatting numeric values with std::format() \nimport <iostream>;\nimport <format>;\nimport <numbers>;\n\nint main()\n{\n  c"
  },
  {
    "path": "Examples/Modules/Chapter 02/Ex2_06B.cpp",
    "chars": 676,
    "preview": "// Argument indices for std::format()\nimport <iostream>;\nimport <format>;\nimport <numbers>;\n\nint main()\n{\n  const double"
  },
  {
    "path": "Examples/Modules/Chapter 02/Ex2_07.cpp",
    "chars": 1221,
    "preview": "// Finding maximum and minimum values for data types\nimport <iostream>;\nimport <limits>;\nimport <format>;\n\nint main()\n{\n"
  },
  {
    "path": "Examples/Modules/Chapter 03/Ex3_01.cpp",
    "chars": 1706,
    "preview": "// Using the bitwise operators\nimport <iostream>;\nimport <format>;\n\nint main()\n{\n  const unsigned int red{ 0xFF0000u }; "
  },
  {
    "path": "Examples/Modules/Chapter 03/Ex3_02.cpp",
    "chars": 1822,
    "preview": "// Demonstrating scope, lifetime, and global variables\nimport <iostream>;\n\nlong count1{999L};         // Global count1\nd"
  },
  {
    "path": "Examples/Modules/Chapter 03/Ex3_03.cpp",
    "chars": 1083,
    "preview": "// Operations with enumerations\nimport <iostream>;\nimport <format>;\n\nint main()\n{\n  enum class Day { Monday, Tuesday, We"
  },
  {
    "path": "Examples/Modules/Chapter 04/Ex4_01.cpp",
    "chars": 628,
    "preview": "// Comparing data values\nimport <iostream>;\n\nint main()\n{\n  char first {};      // Stores the first character\n  char sec"
  },
  {
    "path": "Examples/Modules/Chapter 04/Ex4_01A.cpp",
    "chars": 608,
    "preview": "// Comparing data values (output using std::format())\nimport <iostream>;\nimport <format>;\n\nint main()\n{\n  char first {};"
  },
  {
    "path": "Examples/Modules/Chapter 04/Ex4_02.cpp",
    "chars": 565,
    "preview": "// Three-way comparison of integers\nimport <compare>;  // Required when using operator <=> (even for fundamental types)\n"
  },
  {
    "path": "Examples/Modules/Chapter 04/Ex4_02A.cpp",
    "chars": 565,
    "preview": "// Using the named comparison functions\nimport <compare>;  // Required when using operator <=> (even for fundamental typ"
  },
  {
    "path": "Examples/Modules/Chapter 04/Ex4_03.cpp",
    "chars": 504,
    "preview": "// Using an if statement\nimport <iostream>;\n\nint main()\n{\n  std::cout << \"Enter an integer between 50 and 100: \";\n\n  int"
  },
  {
    "path": "Examples/Modules/Chapter 04/Ex4_04.cpp",
    "chars": 779,
    "preview": "// Using a nested if\nimport <iostream>;\n\nint main()\n{\n  char letter {};                      // Store input here\n  std::"
  },
  {
    "path": "Examples/Modules/Chapter 04/Ex4_04A.cpp",
    "chars": 566,
    "preview": "// Using the std::isupper() / islower() character classification functions\nimport <iostream>;\n\n#include <cctype>\n\nint ma"
  },
  {
    "path": "Examples/Modules/Chapter 04/Ex4_05.cpp",
    "chars": 423,
    "preview": "// Using the if-else statement\nimport <iostream>;\n\nint main()\n{\n  long number {};      // Stores input\n  std::cout << \"E"
  },
  {
    "path": "Examples/Modules/Chapter 04/Ex4_06.cpp",
    "chars": 1267,
    "preview": "// Combining logical operators for loan approval\nimport <iostream>;\n\nint main()\n{\n  int age {};                  // Age "
  },
  {
    "path": "Examples/Modules/Chapter 04/Ex4_07.cpp",
    "chars": 530,
    "preview": "// Using the conditional operator to select output.\nimport <iostream>;\nimport <format>;\n\nint main()\n{\n  int mice {};    "
  },
  {
    "path": "Examples/Modules/Chapter 04/Ex4_08.cpp",
    "chars": 859,
    "preview": "// Using the switch statement\nimport <iostream>;\n\nint main()\n{\n  std::cout << \"Your electronic recipe book is at your se"
  },
  {
    "path": "Examples/Modules/Chapter 04/Ex4_09.cpp",
    "chars": 522,
    "preview": "// Multiple case actions\nimport <iostream>;\n\n#include <cctype>\n\nint main()\n{\n  char letter {};\n  std::cout << \"Enter a l"
  },
  {
    "path": "Examples/Modules/Chapter 04/Ex4_09A.cpp",
    "chars": 655,
    "preview": "// Using a return statement to exit a switch statement\nimport <iostream>;\n\n#include <cctype>\n\nint main()\n{\n  char letter"
  },
  {
    "path": "Examples/Modules/Chapter 05/Ex5_01.cpp",
    "chars": 663,
    "preview": "// Using a for loop with an array\nimport <iostream>;\n\nint main()\n{\n  const unsigned size {6};                        // "
  },
  {
    "path": "Examples/Modules/Chapter 05/Ex5_02.cpp",
    "chars": 486,
    "preview": "// Obtaining the number of array elements\nimport <iostream>;\nimport <array>;       // for std::size()\n\nint main()\n{\n  in"
  },
  {
    "path": "Examples/Modules/Chapter 05/Ex5_03.cpp",
    "chars": 693,
    "preview": "// Floating-point control in a for loop\nimport <format>;\nimport <iostream>;\nimport <numbers>;\n\nint main()\n{\n  const size"
  },
  {
    "path": "Examples/Modules/Chapter 05/Ex5_03A.cpp",
    "chars": 700,
    "preview": "// Floating-point control in a for loop\nimport <format>;\nimport <iostream>;\nimport <numbers>;\n\nint main()\n{\n  const size"
  },
  {
    "path": "Examples/Modules/Chapter 05/Ex5_04.cpp",
    "chars": 791,
    "preview": "// Multiple initializations in a loop expression\nimport <iostream>;\nimport <format>;\n\nint main()\n{\n  unsigned int limit "
  },
  {
    "path": "Examples/Modules/Chapter 05/Ex5_04A.cpp",
    "chars": 800,
    "preview": "// Multiple calculations in a loop expression's third control expression\n// by using the comma operator\nimport <iostream"
  },
  {
    "path": "Examples/Modules/Chapter 05/Ex5_05.cpp",
    "chars": 868,
    "preview": "// Using a while loop to calculate the sum of integers from 1 to n and n!\nimport <iostream>;\nimport <format>;\n\nint main("
  },
  {
    "path": "Examples/Modules/Chapter 05/Ex5_06.cpp",
    "chars": 1041,
    "preview": "// Using a do-while loop to manage input\nimport <iostream>;\n\n#include <cctype>                                  // For t"
  },
  {
    "path": "Examples/Modules/Chapter 05/Ex5_07.cpp",
    "chars": 1664,
    "preview": "// Generating multiplication tables using nested loops\nimport <iostream>;\nimport <format>;\n\n#include <cctype>\n\nint main("
  },
  {
    "path": "Examples/Modules/Chapter 05/Ex5_07A.cpp",
    "chars": 2162,
    "preview": "// Generating multiplication tables using nested loops\n// In this version an indefinite for loop is used, in combination"
  },
  {
    "path": "Examples/Modules/Chapter 05/Ex5_08.cpp",
    "chars": 665,
    "preview": "// Using the continue statement to display ASCII character codes\nimport <iostream>;\nimport <format>;\n\n#include <cctype>\n"
  },
  {
    "path": "Examples/Modules/Chapter 05/Ex5_09.cpp",
    "chars": 1786,
    "preview": "// Sorting an array in ascending sequence - using an indefinite while loop\nimport <iostream>;\nimport <format>;\n\nint main"
  },
  {
    "path": "Examples/Modules/Chapter 05/Ex5_10.cpp",
    "chars": 1084,
    "preview": "// Classifying the letters in a C-style string\nimport <iostream>;\n\n#include <cctype>\n\nint main()\n{\n  const int max_lengt"
  },
  {
    "path": "Examples/Modules/Chapter 05/Ex5_11.cpp",
    "chars": 810,
    "preview": "// Working with strings in an array\nimport <iostream>;\nimport <array>; // for std::size()\n\nint main()\n{\n  const size_t m"
  },
  {
    "path": "Examples/Modules/Chapter 05/Ex5_12.cpp",
    "chars": 1152,
    "preview": "// Allocating an array at runtime\n// This example does not work with some compilers (such as Visual C++)\n// because dyna"
  },
  {
    "path": "Examples/Modules/Chapter 05/Ex5_12A.cpp",
    "chars": 1114,
    "preview": "// Allocating an array at runtime (for loop merged into preceding while loop)\n// This example does not work with some co"
  },
  {
    "path": "Examples/Modules/Chapter 05/Ex5_13.cpp",
    "chars": 1403,
    "preview": "// Comparing array<> objects and plain arrays\nimport <iostream>;\nimport <array>;\n\nint main()\n{\n  {\n    std::cout << \"Fir"
  },
  {
    "path": "Examples/Modules/Chapter 05/Ex5_14.cpp",
    "chars": 2181,
    "preview": "// Using array<T,N> to create Body Mass Index (BMI) table\n// BMI = weight/(height*height)\n// weight in kilograms, height"
  },
  {
    "path": "Examples/Modules/Chapter 05/Ex5_15.cpp",
    "chars": 1533,
    "preview": "// Sorting an array in ascending sequence - using a vector<T> container\nimport <iostream>;\nimport <format>;\nimport <vect"
  },
  {
    "path": "Examples/Modules/Chapter 06/Ex6_01.cpp",
    "chars": 317,
    "preview": "// The size of pointers\nimport <iostream>;\n\nint main()\n{\n  // Print out the size (in number of bytes) of some data types"
  },
  {
    "path": "Examples/Modules/Chapter 06/Ex6_02.cpp",
    "chars": 1327,
    "preview": "// Dereferencing pointers\n// Calculates the purchase price for a given quantity of items\nimport <iostream>;\nimport <form"
  },
  {
    "path": "Examples/Modules/Chapter 06/Ex6_03.cpp",
    "chars": 1107,
    "preview": "// Initializing pointers with strings\nimport <iostream>;\n\nint main()\n{\n  const char* pstar1 {\"Fatty Arbuckle\"};\n  const "
  },
  {
    "path": "Examples/Modules/Chapter 06/Ex6_04.cpp",
    "chars": 718,
    "preview": "// Using an array of pointers\nimport <iostream>;\nimport <array>;      // for std::size()\n\nint main()\n{\n  const char* pst"
  },
  {
    "path": "Examples/Modules/Chapter 06/Ex6_05.cpp",
    "chars": 1128,
    "preview": "// Calculating primes using pointer notation\nimport <iostream>;\nimport <format>;\n\nint main()\n{\n  const size_t max {100};"
  },
  {
    "path": "Examples/Modules/Chapter 06/Ex6_06.cpp",
    "chars": 1474,
    "preview": "// Calculating primes using dynamic memory allocation\nimport <iostream>;\nimport <format>;\n\n#include <cmath>       // For"
  },
  {
    "path": "Examples/Modules/Chapter 06/Ex6_07.cpp",
    "chars": 1504,
    "preview": "// Using smart pointers\nimport <iostream>;\nimport <format>;\nimport <memory>;   // For smart pointers\nimport <vector>;   "
  },
  {
    "path": "Examples/Modules/Chapter 08/Ex8_01.cpp",
    "chars": 502,
    "preview": "// Calculating powers\nimport <iostream>;\nimport <format>;\n\n// Function to calculate x to the power n\ndouble power(double"
  },
  {
    "path": "Examples/Modules/Chapter 08/Ex8_02.cpp",
    "chars": 623,
    "preview": "// Calculating powers - rearranged\nimport <iostream>;\nimport <format>;\n\n//double power(double x, int n);               /"
  },
  {
    "path": "Examples/Modules/Chapter 08/Ex8_03.cpp",
    "chars": 570,
    "preview": "// Failing to modify the original value of a function argument\nimport <iostream>;\n\ndouble changeIt(double value_to_be_ch"
  },
  {
    "path": "Examples/Modules/Chapter 08/Ex8_04.cpp",
    "chars": 574,
    "preview": "// Modifying the value of a caller variable\nimport <iostream>;\n\ndouble changeIt(double* pointer_to_it);    // Function p"
  },
  {
    "path": "Examples/Modules/Chapter 08/Ex8_05.cpp",
    "chars": 640,
    "preview": "// Passing an array to a function\nimport <iostream>;\nimport <array>;          // For std::size()\n\ndouble average(double "
  },
  {
    "path": "Examples/Modules/Chapter 08/Ex8_05A.cpp",
    "chars": 844,
    "preview": "// Passing an array to a function - false expectations\n// Note: with main() as defined in this file, \n// this program wi"
  },
  {
    "path": "Examples/Modules/Chapter 08/Ex8_06.cpp",
    "chars": 742,
    "preview": "// Passing a two-dimensional array to a function\nimport <iostream>;\nimport <array>;\t          // For std::size()\n\ndouble"
  },
  {
    "path": "Examples/Modules/Chapter 08/Ex8_06A.cpp",
    "chars": 726,
    "preview": "// Passing a two-dimensional array to a function (range-based for loop)\nimport <iostream>;\nimport <array>;\t          // "
  },
  {
    "path": "Examples/Modules/Chapter 08/Ex8_07.cpp",
    "chars": 794,
    "preview": "// Modifying the value of a caller variable  references vs pointers\nimport <iostream>;\n\nvoid change_it_by_pointer(double"
  },
  {
    "path": "Examples/Modules/Chapter 08/Ex8_08.cpp",
    "chars": 1668,
    "preview": "// Using a reference parameter\nimport <iostream>;\nimport <format>;\nimport <string>;\nimport <vector>;\n\nusing std::string;"
  },
  {
    "path": "Examples/Modules/Chapter 08/Ex8_09A.cpp",
    "chars": 842,
    "preview": "// Passing an array to a function - pass by reference\n// Note: with main() as defined in this file, this program will no"
  },
  {
    "path": "Examples/Modules/Chapter 08/Ex8_09B.cpp",
    "chars": 715,
    "preview": "// Passing an array to a function - pass by reference improved\nimport <iostream>;\nimport <array>;          // for std::s"
  },
  {
    "path": "Examples/Modules/Chapter 08/Ex8_09C.cpp",
    "chars": 723,
    "preview": "// Passing an array to a function - use std::array<>\nimport <iostream>;\nimport <array>;\n\ndouble average10(const std::arr"
  },
  {
    "path": "Examples/Modules/Chapter 08/Ex8_10.cpp",
    "chars": 330,
    "preview": "// Implicit conversions of reference parameters\nimport <iostream>;\n\nvoid double_it(double& it)      { it *= 2; }\nvoid pr"
  },
  {
    "path": "Examples/Modules/Chapter 08/Ex8_11.cpp",
    "chars": 1190,
    "preview": "// Using multiple default parameter values\nimport <iostream>;\nimport <format>;\nimport <string>;\n\n// The function prototy"
  },
  {
    "path": "Examples/Modules/Chapter 08/Ex8_12.cpp",
    "chars": 177,
    "preview": "// Program that lists its command line arguments\nimport <iostream>;\n\nint  main(int argc, char* argv[])\n{\n  for (int i{};"
  },
  {
    "path": "Examples/Modules/Chapter 08/Ex8_13.cpp",
    "chars": 2747,
    "preview": "// Returning a pointer\nimport <iostream>;\nimport <format>;\nimport <string>;\nimport <array>;                  // for std:"
  },
  {
    "path": "Examples/Modules/Chapter 08/Ex8_14.cpp",
    "chars": 2029,
    "preview": "// Overloading a function\nimport <iostream>;\nimport <string>;\nimport <vector>;\n\n// Function prototypes\ndouble largest(co"
  },
  {
    "path": "Examples/Modules/Chapter 08/Ex8_15.cpp",
    "chars": 966,
    "preview": "// Overloading a function with reference parameters\nimport <iostream>;\nimport <format>;\n\ndouble larger(double a, double "
  },
  {
    "path": "Examples/Modules/Chapter 08/Ex8_16.cpp",
    "chars": 532,
    "preview": "// Recursive version of function for x to the power n, n positive or negative\nimport <iostream>;\nimport <format>;\n\ndoubl"
  },
  {
    "path": "Examples/Modules/Chapter 08/Ex8_17.cpp",
    "chars": 3528,
    "preview": "// Sorting words recursively\nimport <iostream>;\nimport <format>;\nimport <memory>;\nimport <string>;\nimport <vector>;\nusin"
  },
  {
    "path": "Examples/Modules/Chapter 09/Ex9_01.cpp",
    "chars": 1735,
    "preview": "// Working with std::optional<>\nimport <optional>;     // std::optional<> is defined in the <optional> module\nimport <io"
  },
  {
    "path": "Examples/Modules/Chapter 09/Ex9_02.cpp",
    "chars": 1821,
    "preview": "// Using std::string_view parameters\nimport <iostream>;\nimport <format>;\nimport <string>;\nimport <string_view>;\nimport <"
  },
  {
    "path": "Examples/Modules/Chapter 09/Ex9_03.cpp",
    "chars": 2242,
    "preview": "// Using std::span<> to reduce the number of overloads of largest()\n// Clearly the three resulting functions are still s"
  },
  {
    "path": "Examples/Modules/Chapter 09/Ex9_03A.cpp",
    "chars": 2101,
    "preview": "// Using std::span<const T> to ensure largest() works for const inputs\nimport <iostream>;\nimport <string>;\nimport <vecto"
  },
  {
    "path": "Examples/Modules/Chapter 10/Ex10_01.cpp",
    "chars": 843,
    "preview": "// Using a function template\nimport <iostream>;\nimport <format>;\nimport <string>;\n\ntemplate<typename T> T larger(T a, T "
  },
  {
    "path": "Examples/Modules/Chapter 10/Ex10_02.cpp",
    "chars": 1387,
    "preview": "// Overloading function templates\nimport <iostream>;\nimport <format>;\nimport <string>;\nimport <vector>;\n\ntemplate<typena"
  },
  {
    "path": "Examples/Modules/Chapter 10/Ex10_03.cpp",
    "chars": 688,
    "preview": "// Using return type deduction with templates\nimport <iostream>;\nimport <string>;\n\n// Template for functions to return t"
  },
  {
    "path": "Examples/Modules/Chapter 10/Ex10_03A.cpp",
    "chars": 959,
    "preview": "// Using return type deduction with templates (decltype(auto) instead of auto)\nimport <iostream>;\nimport <string>;\nimpor"
  },
  {
    "path": "Examples/Modules/Chapter 10/Ex10_04.cpp",
    "chars": 869,
    "preview": "// Defining templates for functions that accept fixed-size arrays\nimport <iostream>;\n\ntemplate <typename T, size_t N>\nT "
  },
  {
    "path": "Examples/Modules/Chapter 11/Ex11_01/Ex11_01.cpp",
    "chars": 681,
    "preview": "// Consuming your own module\nimport <iostream>;\nimport <format>;\nimport math;\n\nint main()\n{\n  std::cout << \"Lambda squar"
  },
  {
    "path": "Examples/Modules/Chapter 11/Ex11_01/math.cppm",
    "chars": 395,
    "preview": "export module math;\n\nexport auto square(const auto& x) { return x * x; }  // An abbreviated function template\n\nexport co"
  },
  {
    "path": "Examples/Modules/Chapter 11/Ex11_01A/Ex11_01A.cpp",
    "chars": 691,
    "preview": "// Exporting multiple entities at once\nimport <iostream>;\nimport <format>;\nimport math;\n\nint main()\n{\n  std::cout << \"La"
  },
  {
    "path": "Examples/Modules/Chapter 11/Ex11_01A/math.cppm",
    "chars": 345,
    "preview": "export module math;\n\nbool isOdd(int x) { return x % 2 != 0; }   // Module-local function (not exported)\n\nexport\n{\n  auto"
  },
  {
    "path": "Examples/Modules/Chapter 11/Ex11_01B/Ex11_01B.cpp",
    "chars": 729,
    "preview": "// Separating implementation from interface within the module interface file\nimport <iostream>;\nimport <format>;\nimport "
  },
  {
    "path": "Examples/Modules/Chapter 11/Ex11_01B/math.cppm",
    "chars": 421,
    "preview": "export module math;\n\nexport\n{\n  auto square(const auto& x);\n\n  const double lambda = 1.303577269034296391257;  // Conway"
  },
  {
    "path": "Examples/Modules/Chapter 11/Ex11_02/Ex11_02.cpp",
    "chars": 276,
    "preview": "// Defining functions in module implementation files\nimport <iostream>;\nimport <string>;\nimport roman;\n\nint main()\n{\n  s"
  },
  {
    "path": "Examples/Modules/Chapter 11/Ex11_02/from_roman.cpp",
    "chars": 710,
    "preview": "// Implementation of the from_roman() function\nmodule roman;\n\nunsigned int from_roman(char c)\n{\n  switch (c)\n  {\n  case "
  },
  {
    "path": "Examples/Modules/Chapter 11/Ex11_02/roman.cppm",
    "chars": 207,
    "preview": "// Interface file for a Roman numerals module\nexport module roman;\nimport <string>;\nimport <string_view>;\n\nexport std::s"
  },
  {
    "path": "Examples/Modules/Chapter 11/Ex11_02/to_roman.cpp",
    "chars": 587,
    "preview": "// Implementation of the to_roman() function\nmodule roman;\n\nstd::string to_roman(unsigned int i)\n{\n  if (i > 3999) retur"
  },
  {
    "path": "Examples/Modules/Chapter 11/Ex11_03/Ex11_03.cpp",
    "chars": 1230,
    "preview": "// Using types with reachable definitions but whose names are not visible\nimport <iostream>;\nimport roman;\n\nint main()\n{"
  },
  {
    "path": "Examples/Modules/Chapter 11/Ex11_03/from_roman.cpp",
    "chars": 710,
    "preview": "// Implementation of the from_roman() function\nmodule roman;\n\nunsigned int from_roman(char c)\n{\n  switch (c)\n  {\n  case "
  },
  {
    "path": "Examples/Modules/Chapter 11/Ex11_03/roman.cppm",
    "chars": 207,
    "preview": "// Interface file for a Roman numerals module\nexport module roman;\nimport <string>;\nimport <string_view>;\n\nexport std::s"
  },
  {
    "path": "Examples/Modules/Chapter 11/Ex11_03/to_roman.cpp",
    "chars": 587,
    "preview": "// Implementation of the to_roman() function\nmodule roman;\n\nstd::string to_roman(unsigned int i)\n{\n  if (i > 3999) retur"
  },
  {
    "path": "Examples/Modules/Chapter 11/Ex11_04/Ex11_04.cpp",
    "chars": 259,
    "preview": "// Module implementation partitions\nimport <iostream>;\nimport <string>;\nimport roman;\n\nint main()\n{\n  std::cout << \"1234"
  },
  {
    "path": "Examples/Modules/Chapter 11/Ex11_04/from_roman.cpp",
    "chars": 489,
    "preview": "// Implementation of the from_roman() function\nmodule roman;\nimport :internals;\n\nunsigned int from_roman(std::string_vie"
  },
  {
    "path": "Examples/Modules/Chapter 11/Ex11_04/roman-internals.cpp",
    "chars": 320,
    "preview": "// Implementation of the internal from_roman() function\nmodule roman:internals;\n\nunsigned int from_roman(char c)\n{\n  swi"
  },
  {
    "path": "Examples/Modules/Chapter 11/Ex11_04/roman.cppm",
    "chars": 207,
    "preview": "// Interface file for a Roman numerals module\nexport module roman;\nimport <string>;\nimport <string_view>;\n\nexport std::s"
  },
  {
    "path": "Examples/Modules/Chapter 11/Ex11_04/to_roman.cpp",
    "chars": 587,
    "preview": "// Implementation of the to_roman() function\nmodule roman;\n\nstd::string to_roman(unsigned int i)\n{\n  if (i > 3999) retur"
  },
  {
    "path": "Examples/Modules/Chapter 11/Ex11_05/Ex11_05.cpp",
    "chars": 263,
    "preview": "// Creating module interface partitions\nimport <iostream>;\nimport <string>;\nimport roman;\n\nint main()\n{\n  std::cout << \""
  },
  {
    "path": "Examples/Modules/Chapter 11/Ex11_05/from_roman.cpp",
    "chars": 489,
    "preview": "// Implementation of the from_roman() function\nmodule roman;\nimport :internals;\n\nunsigned int from_roman(std::string_vie"
  },
  {
    "path": "Examples/Modules/Chapter 11/Ex11_05/roman-from.cppm",
    "chars": 172,
    "preview": "// Module interface file for the from partition of the roman module\nexport module roman:from;\nimport <string_view>;\n\nexp"
  },
  {
    "path": "Examples/Modules/Chapter 11/Ex11_05/roman-internals.cpp",
    "chars": 320,
    "preview": "// Implementation of the internal from_roman() function\nmodule roman:internals;\n\nunsigned int from_roman(char c)\n{\n  swi"
  },
  {
    "path": "Examples/Modules/Chapter 11/Ex11_05/roman-to.cppm",
    "chars": 642,
    "preview": "// Module interface file for the to partition of the roman module\nexport module roman:to;\nimport <string>;\n\nexport std::"
  },
  {
    "path": "Examples/Modules/Chapter 11/Ex11_05/roman.cppm",
    "chars": 277,
    "preview": "// Primary module interface file for the roman module\nexport module roman;\n\nexport import :to;     // Not: 'export impor"
  },
  {
    "path": "Examples/Modules/Chapter 11/Ex11_06/Ex11_06.cpp",
    "chars": 525,
    "preview": "// Defining and using a namespace\n\nimport <iostream>;\nimport <numbers>;\n\nnamespace math\n{\n  const double sqrt2{ 1.414213"
  },
  {
    "path": "Examples/Modules/Chapter 11/Ex11_06A/Ex11_06A.cpp",
    "chars": 345,
    "preview": "// Defining and using a namespace\nimport <iostream>;\nimport <numbers>;\nimport squaring;\n\nint main()\n{\n  std::cout << \"ma"
  },
  {
    "path": "Examples/Modules/Chapter 11/Ex11_06A/squaring.cppm",
    "chars": 240,
    "preview": "export module squaring;\n\nnamespace math\n{\n  export const double sqrt2{ 1.414213562373095 };      // the square root of 2"
  },
  {
    "path": "Examples/Modules/Chapter 11/Ex11_06B/Ex11_06B.cpp",
    "chars": 345,
    "preview": "// Defining and using a namespace\nimport <iostream>;\nimport <numbers>;\nimport squaring;\n\nint main()\n{\n  std::cout << \"ma"
  },
  {
    "path": "Examples/Modules/Chapter 11/Ex11_06B/squaring.cppm",
    "chars": 278,
    "preview": "export module squaring;\n\nexport namespace math         // Exports all nested declarations at once\n{\n  const double sqrt2"
  },
  {
    "path": "Examples/Modules/Chapter 11/Ex11_07/Ex11_07.cpp",
    "chars": 527,
    "preview": "// Separating declarations and definitions of functions\n// declared in a namespace.\nimport <iostream>;\nimport math;\n\nint"
  },
  {
    "path": "Examples/Modules/Chapter 11/Ex11_07/math.cpp",
    "chars": 3862,
    "preview": "module;\n#include <cmath>    // For std::pow(), std::sqrt(), ...\nmodule math;\n\nimport <limits>;   // For std::numeric_lim"
  },
  {
    "path": "Examples/Modules/Chapter 11/Ex11_07/math.cppm",
    "chars": 350,
    "preview": "export module math;\n\nimport <span>;\n\nexport namespace math\n{\n  auto square(const auto& x) { return x * x; };\n\n  namespac"
  },
  {
    "path": "Examples/Modules/Chapter 11/Ex11_08/Ex11_08.cpp",
    "chars": 848,
    "preview": "// Using using declarations and using directives\n// (Note: example was not named in the text)\nimport <iostream>;\nimport "
  },
  {
    "path": "Examples/Modules/Chapter 11/Ex11_08/squaring.cppm",
    "chars": 740,
    "preview": "module;               // Start of the global module fragment (for #include directives)\n#include <cmath>      // For std:"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_01/Ex12_01.cpp",
    "chars": 792,
    "preview": "// Defining a class constructor\nimport <iostream>;\n\n// Class to represent a box\nclass Box\n{\npublic:\n  // Constructor\n  B"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_01A/Ex12_01A.cpp",
    "chars": 921,
    "preview": "// Defining a default constructor\nimport <iostream>;\n\n// Class to represent a box\nclass Box\n{\npublic:\n// Box() {}       "
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_02/Ex12_02.cpp",
    "chars": 1193,
    "preview": "// Defining member functions outside a class\n// Note that, unlike what we said in the text, \n// in this example we put t"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_03/Ex12_03.cpp",
    "chars": 916,
    "preview": "// Using a member initializer list\nimport <iostream>;\n\n// Class to represent a box\nclass Box\n{\npublic:\n  Box() = default"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_04/Ex12_04.cpp",
    "chars": 1158,
    "preview": "// Using the explicit keyword\n// Uncomment \"explicit\" to make the compilation of \n// the expression \"box1.hasLargerVolum"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_05/Ex12_05.cpp",
    "chars": 1210,
    "preview": "// Delegating constructors\nimport <iostream>;\n\nclass Box\n{\npublic:\n  Box(double length, double width, double height);\n  "
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_05A/Ex12_05A.cpp",
    "chars": 1810,
    "preview": "// Implementing the copy constructor\n// Note: this example is explained but not named in the text\nimport <iostream>;\n\ncl"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_06/Box.cppm",
    "chars": 677,
    "preview": "// Module interface file for a module exporting the Box class\nexport module box;\nimport <iostream>;\n\n// Class to represe"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_06/Ex12_06.cpp",
    "chars": 293,
    "preview": "// Exporting a class from a module\nimport <iostream>;   // For use of std::cout, std::endl, etc.\nimport box;          //"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_06A/Box.cpp",
    "chars": 327,
    "preview": "module box;\nimport <iostream>;\n\n// Constructor definition\nBox::Box(double length, double width, double height)\n  : m_len"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_06A/Box.cppm",
    "chars": 302,
    "preview": "export module box;\n\n// Class to represent a box\nexport class Box\n{\npublic:\n  Box() = default;\n  Box(double length, doubl"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_06A/Ex12_06A.cpp",
    "chars": 314,
    "preview": "// Defining class members in a module implementation file\n\nimport <iostream>;  // For use of std::cout, std::endl, etc.\n"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_06B/Box.cppm",
    "chars": 489,
    "preview": "export module box;\nimport <iostream>;\n\n// Class to represent a box\nexport class Box\n{\npublic:\n  Box() = default;\n  Box(d"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_06B/Ex12_06B.cpp",
    "chars": 308,
    "preview": "// Defining classes with in-class member definitions.\n\nimport <iostream>; // For use of std::cout, std::endl, etc.\nimpor"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_07/Box.cpp",
    "chars": 328,
    "preview": "module box;\n\nimport <iostream>;\n\n// Constructor definition\nBox::Box(double length, double width, double height)\n  : m_le"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_07/Box.cppm",
    "chars": 740,
    "preview": "export module box;\n\nexport class Box\n{\npublic:\n  // Constructors\n  Box() = default;\n  Box(double length, double width, d"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_07/Ex12_07.cpp",
    "chars": 600,
    "preview": "// Accessing private members through getters and setters\nimport <iostream>;\nimport box;\n\nint main()\n{\n  Box myBox {3.0, "
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_08/Box.cpp",
    "chars": 631,
    "preview": "module box;\nimport <iostream>;\n\n// Constructor definition\nBox::Box(double length, double width, double height)\n  : m_len"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_08/Box.cppm",
    "chars": 560,
    "preview": "export module box;\n\nexport class Box\n{\npublic:\n  // Constructors\n  Box() = default;\n  Box(double length, double width, d"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_08/Ex12_08.cpp",
    "chars": 622,
    "preview": "// Accessing private members through getters and setters (method chaining variant)\nimport <iostream>;\nimport box;\n\nint m"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_09/Box.cpp",
    "chars": 340,
    "preview": "module box;\n\nimport <iostream>;\n\n// Constructor definition\nBox::Box(double length, double width, double height)\n  : m_le"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_09/Box.cppm",
    "chars": 796,
    "preview": "export module box;\n\nexport class Box\n{\npublic:\n  // Constructors\n  Box() = default;\n  Box(double length, double width, d"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_09/Ex12_09.cpp",
    "chars": 775,
    "preview": "// Const objects and const member functions\nimport <iostream>;\nimport box;\n\nint main()\n{\n  // v-- this const was added.."
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_10/Box.cpp",
    "chars": 339,
    "preview": "module box;\nimport <iostream>;\n\n// Constructor definition\nBox::Box(double length, double width, double height)\n  : m_len"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_10/Box.cppm",
    "chars": 1251,
    "preview": "export module box;\nimport <iostream>;\n\nexport class Box\n{\npublic:\n  // Constructors\n  Box() = default;\n  Box(double leng"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_10/Ex12_10.cpp",
    "chars": 341,
    "preview": "// Overloading on const\nimport <iostream>;\nimport box;\n\nint main()\n{\n  const Box constBox{ 1, 2, 3 };\n  // constBox.leng"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_11/Box.cpp",
    "chars": 691,
    "preview": "module box;\n\nimport <iostream>;\n\n// Constructor definition\nBox::Box(double length, double width, double height)\n  : m_le"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_11/Box.cppm",
    "chars": 961,
    "preview": "export module box;\n\nexport class Box\n{\npublic:\n  // Constructors\n  Box() = default;\n  Box(double length, double width, d"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_11/Ex12_11.cpp",
    "chars": 355,
    "preview": "// Const objects and const member functions\nimport <iostream>;\nimport box;\n\nint main()\n{\n  const Box myBox {3.0, 4.0, 5."
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_12/Box.cpp",
    "chars": 340,
    "preview": "module box;\n\nimport <iostream>;\n\n// Constructor definition\nBox::Box(double length, double width, double height)\n  : m_le"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_12/Box.cppm",
    "chars": 397,
    "preview": "export module box;\n\nexport class Box\n{\npublic:\n  Box() : Box{ 1.0, 1.0, 1.0} {}        // A delegating default construct"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_12/Ex12_12.cpp",
    "chars": 928,
    "preview": "// Using a friend function of a class\nimport <iostream>;\nimport <memory>;\nimport box;\n\nint main()\n{\n  Box box1 {2.2, 1.1"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_13/Box.cpp",
    "chars": 709,
    "preview": "module box;\n\nimport <iostream>;\n\nBox::Box(double length, double width, double height)  // Constructor definition\n  : m_l"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_13/Box.cppm",
    "chars": 421,
    "preview": "export module box;\n\nexport class Box\n{\npublic:\n  /* Constructors */\n  Box(double length, double width, double height);\n "
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_13/Ex12_13.cpp",
    "chars": 493,
    "preview": "// Creating an array of objects\nimport <iostream>;\nimport box;\n\nint main()\n{\n  const Box box1 {2.0, 3.0, 4.0};  // An ar"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_14/Box.cpp",
    "chars": 907,
    "preview": "module box;\nimport <iostream>;\n\nBox::Box(double length, double width, double height)  // Constructor definition\n  : m_le"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_14/Box.cppm",
    "chars": 547,
    "preview": "export module box;\n\nexport class Box\n{\npublic:\n  Box();                     // Default constructor  \n  Box(double side);"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_14/Ex12_14.cpp",
    "chars": 631,
    "preview": "// Using a static member variable\nimport <iostream>;\nimport box;\n\nint main()\n{\n  const Box box1 {2.0, 3.0, 4.0};        "
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_15/CylindricalBox.cpp",
    "chars": 471,
    "preview": "module cylindrical;\n\nimport <iostream>;\n\nCylindricalBox::CylindricalBox(float radius, float height, std::string_view mat"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_15/CylindricalBox.cppm",
    "chars": 610,
    "preview": "export module cylindrical;\n\nimport <string>;\nimport <string_view>;\n\nexport class CylindricalBox\n{\npublic:\n  static inlin"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_15/Ex12_15.cpp",
    "chars": 282,
    "preview": "// Defining and using static constants\nimport <iostream>;\nimport cylindrical;\n\nint main()\n{\n  CylindricalBox bigBox{ 1.2"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_16/Box.cpp",
    "chars": 1041,
    "preview": "module box;\nimport <iostream>;\n\nBox::Box(double length, double width, double height)  // Constructor definition\n  : m_le"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_16/Box.cppm",
    "chars": 574,
    "preview": "export module box;\n\nexport class Box\n{\npublic:\n  Box();                     // Default constructor  \n  Box(double side);"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_16/Ex12_16.cpp",
    "chars": 822,
    "preview": "// Implementing a destructor\nimport <iostream>;\nimport box;\n\nint main()\n{\n  std::cout << \"There are now \" << Box::getObj"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_17/Box.cppm",
    "chars": 646,
    "preview": "export module box;\n\nimport <iostream>;\nimport <format>;\n\nexport class Box\n{\npublic:\n  Box() = default;\n  Box(double leng"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_17/Ex12_17.cpp",
    "chars": 1546,
    "preview": "// Using a linked list\nimport box.random;\nimport truckload;\nimport <iostream>;\n\nint main()  \n{\n  Truckload load1;  // Cr"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_17/Package.cpp",
    "chars": 602,
    "preview": "module truckload:package;\n\nimport :shared_box;\n\nclass Package\n{\npublic:\n  Package(SharedBox box) : m_box{box}, m_next{nu"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_17/RandomBoxes.cppm",
    "chars": 1051,
    "preview": "export module box.random;\nimport box;\nimport <random>;        // For random number generation\nimport <functional>;    //"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_17/SharedBox.cppm",
    "chars": 114,
    "preview": "export module truckload:shared_box;\n\nimport <memory>;\nimport box;\n\nexport using SharedBox = std::shared_ptr<Box>;\n"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_17/Truckload.cpp",
    "chars": 3252,
    "preview": "module truckload;\n\nimport <iostream>;\n\n// Constructor - one Box (moved to source file to gain access to definition of Pa"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_17/Truckload.cppm",
    "chars": 945,
    "preview": "export module truckload;\n\nexport import :shared_box;\nimport :package;\nimport <vector>;\n\nexport class Truckload\n{\npublic:"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_18/Box.cppm",
    "chars": 646,
    "preview": "export module box;\n\nimport <iostream>;\nimport <format>;\n\nexport class Box\n{\npublic:\n  Box() = default;\n  Box(double leng"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_18/Ex12_18.cpp",
    "chars": 1547,
    "preview": "// Using nested classes\nimport box.random;\nimport truckload;\nimport <iostream>;\n\nint main()  \n{\n  Truckload load1;  // C"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_18/RandomBoxes.cppm",
    "chars": 1055,
    "preview": "export module box.random;\n\nimport box;\nimport <random>;        // For random number generation\nimport <functional>;    /"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_18/Truckload.cpp",
    "chars": 3302,
    "preview": "module truckload;\nimport <iostream>;\n\n// Constructor - one Box (moved to source file to gain access to definition of Pac"
  },
  {
    "path": "Examples/Modules/Chapter 12/Ex12_18/Truckload.cppm",
    "chars": 1318,
    "preview": "export module truckload;\nimport box;\n\nimport <memory>;\nimport <vector>;\n\nexport using SharedBox = std::shared_ptr<Box>;\n"
  },
  {
    "path": "Examples/Modules/Chapter 13/Ex13_01/Box.cppm",
    "chars": 581,
    "preview": "export module box;\n\nexport class Box\n{\npublic:\n  // Constructors\n  Box() = default;\n  Box(double l, double w, double h) "
  },
  {
    "path": "Examples/Modules/Chapter 13/Ex13_01/Ex13_01.cpp",
    "chars": 498,
    "preview": "// Implementing a less-than operator\nimport <iostream>;\nimport <vector>;\nimport box;\n\nint main()\n{\n  std::vector boxes {"
  },
  {
    "path": "Examples/Modules/Chapter 13/Ex13_02/Box.cppm",
    "chars": 953,
    "preview": "export module box;\n\nexport class Box\n{\npublic:\n  // Constructors\n  Box() = default;\n  Box(double l, double w, double h) "
  },
  {
    "path": "Examples/Modules/Chapter 13/Ex13_02/Ex13_02.cpp",
    "chars": 780,
    "preview": "// Using the overloaded 'less-than' operators for Box ojects\nimport <iostream>;\nimport <vector>;\nimport <format>;\nimport"
  },
  {
    "path": "Examples/Modules/Chapter 13/Ex13_03/Box.cppm",
    "chars": 954,
    "preview": "export module box;\n\nimport <compare>;  // For std::partial_ordering (see Chapter 4)\n\nexport class Box\n{\npublic:\n  // Con"
  },
  {
    "path": "Examples/Modules/Chapter 13/Ex13_03/Ex13_03.cpp",
    "chars": 1129,
    "preview": "// Overloading <=> and == to fully support all comparison operators\nimport <iostream>;\nimport <format>;\nimport <string_v"
  },
  {
    "path": "Examples/Modules/Chapter 13/Ex13_03A/Box.cppm",
    "chars": 833,
    "preview": "export module box;\n\nimport <compare>;  // For std::partial_ordering (see Chapter 4)\n\nexport class Box\n{\npublic:\n  // Con"
  },
  {
    "path": "Examples/Modules/Chapter 13/Ex13_03A/Ex13_03A.cpp",
    "chars": 1092,
    "preview": "// Defaulting the == operator\n\nimport <iostream>;\nimport <format>;\nimport <string_view>;\nimport <vector>;\nimport box;\n\nv"
  },
  {
    "path": "Examples/Modules/Chapter 13/Ex13_04/Box.cppm",
    "chars": 1115,
    "preview": "export module box;\n\nimport <compare>;  // For std::partial_ordering (see Chapter 4)\nimport <ostream>;  // For std::ostre"
  },
  {
    "path": "Examples/Modules/Chapter 13/Ex13_04/Ex13_04.cpp",
    "chars": 820,
    "preview": "// Overloading the << operator\nimport <iostream>;\nimport <format>;\nimport <string_view>;\nimport <vector>;\nimport box;\n\ni"
  },
  {
    "path": "Examples/Modules/Chapter 13/Ex13_05/Box.cpp",
    "chars": 835,
    "preview": "module box;\n\nimport <format>;\nimport <algorithm>;    // For the min() and max() function templates\n\ndouble Box::volume()"
  },
  {
    "path": "Examples/Modules/Chapter 13/Ex13_05/Box.cppm",
    "chars": 1054,
    "preview": "export module box;\n\nimport <compare>;  // For std::partial_ordering (see Chapter 4)\nimport <ostream>;  // For std::ostre"
  },
  {
    "path": "Examples/Modules/Chapter 13/Ex13_05/Ex13_05.cpp",
    "chars": 2106,
    "preview": "// Using the addition operator for Box objects\nimport <iostream>;\nimport <format>;\nimport <vector>;\nimport <random>;    "
  },
  {
    "path": "Examples/Modules/Chapter 13/Ex13_06/Box.cpp",
    "chars": 996,
    "preview": "module;\n#include <cmath>    // For the min() and max() function templates\nmodule box;\n\nimport <format>;\n\ndouble Box::vol"
  },
  {
    "path": "Examples/Modules/Chapter 13/Ex13_06/Box.cppm",
    "chars": 1126,
    "preview": "export module box;\n\nimport <compare>;  // For std::partial_ordering (see Chapter 4)\nimport <ostream>;  // For std::ostre"
  },
  {
    "path": "Examples/Modules/Chapter 13/Ex13_06/Ex13_06.cpp",
    "chars": 2353,
    "preview": "// Using the addition operator for Box objects\nimport <iostream>;\nimport <format>;\nimport <vector>;\nimport <random>;    "
  },
  {
    "path": "Examples/Modules/Chapter 13/Ex13_07/Ex13_07.cpp",
    "chars": 254,
    "preview": "// Implicit conversions reduce the number of operator functions\nimport <iostream>;\nimport integer;\n\nint main() \n{\n  cons"
  },
  {
    "path": "Examples/Modules/Chapter 13/Ex13_07/Integer.cppm",
    "chars": 794,
    "preview": "export module integer;\n\nexport class Integer\n{\npublic:\n  Integer(int value = 0) : m_value{value} {}\n  int getValue() con"
  },
  {
    "path": "Examples/Modules/Chapter 13/Ex13_08/Box.cppm",
    "chars": 1226,
    "preview": "export module box;\n\nimport <compare>;  // For std::partial_ordering (see Chapter 4)\nimport <ostream>;  // For std::ostre"
  },
  {
    "path": "Examples/Modules/Chapter 13/Ex13_08/Ex13_08.cpp",
    "chars": 152,
    "preview": "// Overloading a unary \"rotate\" operator\nimport <iostream>;\nimport box;\n\nint main()\n{\n  Box someBox{ 1, 2, 3 };\n  std::c"
  },
  {
    "path": "Examples/Modules/Chapter 13/Ex13_09/Box.cppm",
    "chars": 2061,
    "preview": "export module box;\n\nimport <compare>;  // For std::partial_ordering (see Chapter 4)\nimport <ostream>;  // For std::ostre"
  }
]

// ... and 1322 more files (download for full content)

About this extraction

This page contains the full source code of the Apress/beginning-cpp20 GitHub repository, extracted and formatted as plain text for AI agents and large language models (LLMs). The extraction includes 1522 files (1.7 MB), approximately 534.9k tokens, and a symbol index with 2193 extracted functions, classes, methods, constants, and types. Use this with OpenClaw, Claude, ChatGPT, Cursor, Windsurf, or any other AI tool that accepts text input. You can copy the full output to your clipboard or download it as a .txt file.

Extracted by GitExtract — free GitHub repo to text converter for AI. Built by Nikandr Surkov.

Copied to clipboard!