Pergunta de entrevista da empresa Accenture

Write a program for deadlock &how to resolve that