How to Group Prefixes? Single-linkage clustering Simple and efficient