ADP interview question

Locking on two strings and does it causes dead lock