Finally, the algorithm is guaranteed to find a unifying counterexample for every ambiguous grammar, but the search will not terminate when infinite expansions are possible on unambiguous grammars. 
this semi-decision procedure for determining ambiguity is sound and complete. 