1.
1) Fault: the first element of the array is not in the loop.
2) If possible, identify a test case that does not execute the fault(Reachability): x is null.
3) If possible, identify a test case that executes the fault, but does not result in an error state: x={5,2,7},y=7.
4) If possible, identify a test case that results in an error, but not a failure: x={5,2,7},y=1.
2.
1) Fault: the order is reversed in the loop.
2) If possible, identify a test case that does not execute the fault(Reachability): x is null.
3) If possible, identify a test case that executes the fault, but does not result in an error state: x={0}.
4) If possible, identify a test case that results in an error, but not a failure: x={5,2,7}.