when indexing 'str', it's safe to infer 'str' for the result