Possible Merge Algorithm Pseudocode