def time_to_min(in_time: str) -> int:
    """
    Turns human given string to time in minutes
    e.g. 10h 15m -> 615
    """
    times = [int(x.strip()) for x in in_time.strip("m").split("h")]
    assert len(times) <= 2
    if len(times) == 1:
        return times[0]
    else:
        return times[0] * 60 + times[1]