/* topological sort
* input is sequence of pairs of items (blank-free strings)
* nonidentical pair is a directed edge in graph
/* topological sort
* input is sequence of pairs of items (blank-free strings)
* nonidentical pair is a directed edge in graph