<s> __author__ = "<STR_LIT>" <EOL> def reversing_words ( word ) : <EOL> """<STR_LIT>""" <EOL> new_word = [ ] <EOL> words = word . split ( '<STR_LIT:U+0020>' ) <EOL> for word in words [ : : - <NUM_LIT:1> ] : <EOL> new_word . append ( word ) <EOL> return "<STR_LIT:U+0020>" . join ( new_word ) <EOL> def reversing_words2 ( s ) : <EOL> """<STR_LIT>""" <EOL> words = s . split ( ) <EOL> return '<STR_LIT:U+0020>' . join ( reversed ( words ) ) <EOL> def reversing_words3 ( s ) : <EOL> """<STR_LIT>""" <EOL> words = s . split ( '<STR_LIT:U+0020>' ) <EOL> words . reverse ( ) <EOL> return '<STR_LIT:U+0020>' . join ( words ) <EOL> if __name__ == '<STR_LIT:__main__>' : <EOL> import doctest <EOL> doctest . testmod ( ) </s>
