from typing import Dict, Optional # The standard typing module allows the provision of type hints for # better maintainability, etc. Its uses are not required. # The first function is completed for you. # Complete the remaining four functions by replacing "pass" by your code. # # def get_max_value(data_dict: Dict[str, int]) -> int: # find_max_value returns the maximum value of a dictionary # in which the keys are strings and the values are integers. # The function accepts one argument: data_dict. # The argument is a dictionary in which the key is a string and # value of an integer (i.e., (data_dict: Dict[str, int])). # It returns an integer value (i.e., -> int) # # It is ok to use just this: # def get_max_value(data_dict): def get_max_value(data_dict: Dict[str, int]) -> Optional[int]: """Calculates the maximum of all integer values in the dictionary.""" if len(data_dict) == 0: return None else: return max(data_dict.values()) # # def get_total_sum(data_dict: Dict[str, int]) -> int: # def get_total_sum(data_dict: Dict[str, int]) -> Optional[int]: """Calculates and return the sum of all integer values in the dictionary.""" pass # # def get_value_list(data_dict: Dict[str, int]) -> int: # get_value_list returns the list of values in data_dict. # def get_value_list(data_dict: Dict[str, int]) -> list[int]: """returns the list of int values""" pass def increment_all_values(data_dict: Dict[str, int], increment_by: int = 1) -> Dict[str, int]: """Returns a new dictionary with all values incremented by the specified amount.""" pass def value_frequencies(data_dict: Dict[str, int]) -> Dict[int, int]: """return a dictionary of the frequency of each unique integer value in the dictionary data_dict.""" pass