Problem 3042 · Easy

Count Prefix and Suffix Pairs I

Check each earlier word against each later word and count the pairs where the earlier word is both a prefix and a suffix.

Open the interactive visualisation