Bentley Systems interview question

1)Second highest salary query 2)Generics in C++. Write code for both function and class level generics 3) Function pointer 4) How does C/C++ program compilation happens. All steps in brief (preprocessing,compiling,linking) 5) Memory management in C