Rosetta Problems

Count Prefixes of a Given String

https://leetcode.com/problems/count-prefixes-of-a-given-string