Still, this is effort linear in the size of the string.