Implementation of the string library with lines sorting algorithms.
First task in MIPT in the first year of education.
The idea is to understand how to work with text files, how to properly represent them.
The program receives the famous novel by Alexander Sergeevich Pushkin "Eugene Onegin" as input and based on the user's settings (modes of lexicographical line sorting) sorts lines and writes them to the output file.
Also there is documentation generated with doxygen.
- Compare lines without punctuation;
- Compare lines with punctuation;
- Reversed lines comparison. Given two strings, we iterate from the end to the beginning of them and do lexicographical sorting;
- Direct lines comparison. Given two strings, we iterate form the beginning to the end of them and do lexicographical sorting.
Install doxygen;- Add
doxygen/bindirectory to the environmental variables; - Cd (change directory) to the location of the
Oneginproject; - Open
Doxyfilein notepad and setOUTPUT_DIRECTORYto your directory where you want the documentation to be,INPUTto theOnegindirectory path,USE_MDFILE_AS_MAINPAGEto the path of theREADME.mdfile path (e.g. <your_path>/README.md); - Open terminal in the location of
Oneginproject; - Run
doxygencommand in terminal; - Open
htmldirectory and runindex.htmlfile.
Clone the repository
git clone https://github.com/V13kv/Onegin;
cd Onegin
Compiling
make init;
make
./onegin.exe