def string_replace(string, variable_dict):
    """Replaces variables in a string with numbers from a dict

    :param string: String with variables in it.
    :param variable_dict: a dictionary with variable names as keys and the number to replace them which as values.
    :return: String with numbers instead of variable names.
    """
    for key in variable_dict:

        string = string.replace(key, '(' + str(variable_dict[key]) + ')')
    return string