from typing import Dict
from typing import Any
from typing import List


def get_key_mapping(inverse_mapping: Dict[Any, List[str]]) -> Dict[str, Any]:
  """Returns the key mapping from the inverse mapping.

  Args:
    inverse_mapping: A mapping from the mapped input to the list of keys.

  Returns:
    a mapping from the keys to their mapped input.
  """
  mapped_keys = {}
  for mapped_key, keys in inverse_mapping.items():
    for key in keys:
      mapped_keys[key] = mapped_key
  return mapped_keys