from typing import List


def get_all_headings(text: str, num_hashes: int) -> List[str]:
    """
    Returns headings from a markdown file.

    Args:
        text (str): text
        num_hashes (int): indicates the heading "level" to look for

    Returns:
        (List[str]): headers
    """
    hashes_str = "#" * num_hashes + " "

    headings = []
    for line in text.splitlines():
        if hashes_str in line:
            headings.append(line.strip().replace(hashes_str, ""))

    return headings