Answer is 4) Statement II : Code 2 gurantees ME and spin lock is possible in it therefore leads to deadlock.
Reasoning :
Counter ex for statement 1)
At the very initial time both have false entries at respective index in shared array ,Now P0 check P1's index which is false and gets preempted and Now P1 hold computation and check P0's index and enters CS and gets Preempted .
After this point both are in CS which leads to Alter the condition of ME.
Condition of Spin lock for statement 3)
P0 asks for CS and make entry true at respective index in shared array and gets preempted
P1 asks for CS and make entry true at respective index in shared array and gets prempted now at this point of time no matter which process gets schedule it gets stuck in while loop and therefore spin lock will result to deadlock.