python_data_scien/poc1/min_porj_5(Cookie Clicker).py
def strategy_expensive(cookies, cps, history, time_left, build_info):
    """
    Always buy the most expensive item you can afford in the time left.
    """
    build_items_list = build_info.build_items()
    expensive_item_name = None
    for idx in range(len(build_items_list)):
        if build_info.get_cost(build_items_list[idx]) <= cookies + cps * time_left:
            if expensive_item_name == None:
                expensive_item_name = build_items_list[idx]
            else:
                if build_info.get_cost(build_items_list[idx]) > build_info.get_cost(expensive_item_name):
                    expensive_item_name = build_items_list[idx]
    return expensive_item_name

    Always buy the most expensive item you can afford in the time left.
    
Always buy the most expensive item you can afford in the time left.
Always buy the most expensive item you can afford in the time left .
def strategy_expensive(cookies, cps, history, time_left, build_info):
    build_items_list = build_info.build_items()
    expensive_item_name = None
    for idx in range(len(build_items_list)):
        if build_info.get_cost(build_items_list[idx]) <= cookies + cps * time_left:
            if expensive_item_name == None:
                expensive_item_name = build_items_list[idx]
            else:
                if build_info.get_cost(build_items_list[idx]) > build_info.get_cost(expensive_item_name):
                    expensive_item_name = build_items_list[idx]
    return expensive_item_name
def strategy_expensive ( cookies , cps , history , time_left , build_info ) : build_items_list = build_info . build_items ( ) expensive_item_name = None for idx in range ( len ( build_items_list ) ) : if build_info . get_cost ( build_items_list [ idx ] ) <= cookies + cps * time_left : if expensive_item_name == None : expensive_item_name = build_items_list [ idx ] else : if build_info . get_cost ( build_items_list [ idx ] ) > build_info . get_cost ( expensive_item_name ) : expensive_item_name = build_items_list [ idx ] return expensive_item_name
Always buy the most expensive item you can afford in the time left.
Always buy the most expensive item you can afford in the time left .
"""
    Always buy the most expensive item you can afford in the time left.
    """
cookies
cps
history
time_left
build_info