Don't feel intimidated by what you don't know. Ask your question anonymously. It's easy! Learn more and upgrade.
class Words(): def __init__( self, sequence, word, length): self.sequence = sequence self.word = word self.length = length def get_sequence( self ): return self.sequence def get_word( self ): return self.word def get_length( self ): return self.length if __name__ == "__main__": our_words =  word_count('declaration.txt') #function omitted mots =  for sequence, word in enumerate( our_words ) : mots.append( Words( sequence, word, length=len(word)) ) for i in range( len( mots ) ) : mot = mots[ i ] print '%d: %d %s: %d' % ( i, mot.get_sequence(), mot.get_word(), mot.get_length() )
Join the community of 500,000 technology professionals and ask your questions.