This program analyzes the birth and death years of scientists to find the range of years in which the most scientists lived. It also provides a list of scientists who lived during that range.
The program takes the following input:
- The number of scientists.
- For each scientist, their first name, birth year, and death year.
Example input:
5
Alfred 1884 1923
Robert 1733 1892
Sarah 1901 1958
Richard 1999 2013
Harry 1794 1899
and
4
Angela 1488 1560
Andre 1497 1594
Pitter 1577 1602
Ahmad 1599 1612
The program outputs the following:
- The range of years in which the most scientists lived.
- The list of scientists who lived during that range, sorted alphabetically.
Example output:
1884-1892
Alfred
Harry
Robert
and
1497-1560
Andre
Angela
To use the program, follow these steps:
- Clone the repository or download the source code.
- Build the program using a C++ compiler.
- Run the program and provide the input as described above.
- View the output generated by the program.
This program is licensed under the GPL-3.0 License.
Copyright 2023, Max Base