this one was written one day before the final test. This program counts the number of PF(page faults) and also prints tables for different algorithms (FIFS, LRU, OPT)
Don't pay too much attention to this code, because there is a lot of shitcode, xD.
git clone https://github.com/Hollbrok/Page-fault-counter.git
cd Page-fault-counter/
make
./a __PROC_ALLOC_FRAMES__ [queue of frames]
Перерисовать таблицы, чтобы семер не спросил как вы получили ответ. P.S. для FIFO, перед перенесением в тетрадь, таблицу нужно транспонировать.
./a 3 1 2 3 5 2 1 4 5 2 1 3 4 1 2 5 1 3 2 4
There is 3 -- number of frames allocated to the process.
So there you can see example of output: