def get_number_of_reviews(num_review: str) -> int:
    """
    >>> get_number_of_reviews('172 reviews')
    172
    >>> get_number_of_reviews('1,822 reviews')
    1822
    """
    num_str = num_review.split(' ')[0]
    num_str = ''.join([n for n in num_str if n != ','])
    return int(num_str)