from typing import Tuple


def get_input() -> Tuple[int, int]:
    """Returns N x M integer input for Designer Doormat.

    Returns:
        Tuple[int, int]: N x M, representing length & width.
    """
    n, m = [int(x) for x in input().split()]
    if n % 2 == 0: 
        raise Exception("Not odd!")
    if m != 3* n:
        raise Exception("M must be 3n!")
    return n, m