import random


def get_epsilon_greedy_action(epsilon, Q_actions):
    """Choose an action using the epsilon-greedy strategy.
    
    :param epsilon: 
    :param Q_actions: 
    :return: 
    """
    if random.random() > epsilon:
        max_actions = []
        max_v = float("-inf")
        for action in Q_actions:
            if Q_actions[action] > max_v:
                max_v = Q_actions[action]
                max_actions = [action]
            elif Q_actions[action] == max_v:
                max_actions.append(action)
        
        return random.choice(max_actions)
    else:
        return random.choice(list(Q_actions.keys()))