slight update to minheap handling in main.cpp