def extract_capital_letters(x):
    """ Extract capital letters from string """
    try:
        return "".join([s for s in x if s.isupper()])
    except Exception as e:
        print(f"Exception raised:\n{e}")
        return ""