This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def get_best_profit_brute_force(stock_prices_yesterday): | |
max_profit = 0 | |
# go through every time | |
for outer_time in xrange(len(stock_prices_yesterday)): | |
# for every time, go through every OTHER time | |
for inner_time in xrange(len(stock_prices_yesterday)): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class WordCloudData: | |
def __init__(self, input_string): | |
self.input_string = input_string | |
self.words_to_counts = {} | |
self.populate_hash() | |
def populate_hash(self): | |
# | |
current_word = '' |