Ericsson interview question

multi-thread, dead lock, basic in C/C++