def _simple_acronym_detection(s, i, words, *args):
    """Detect acronyms based on runs of upper-case letters."""
    # Combine each letter into a single string.
    acronym = ''.join(words[s:i])

    # Remove original letters in word list.
    for _ in xrange(s, i):
        del words[s]

    # Replace them with new word grouping.
    words.insert(s, ''.join(acronym))

    return s
def _simple_acronym_detection ( s , i , words , * args ) : acronym = '' . join ( words [ s : i ] ) for _ in xrange ( s , i ) : del words [ s ] words . insert ( s , '' . join ( acronym ) ) return s
Detect acronyms based on runs of upper-case letters.