Problem:
 ﻿Score: 100 points    Problem Statement  There is a farm whose length and width are A yard and B yard, respectively. A farmer, John, made a vertical road and a horizontal road inside the farm from one border to another, as shown below: (The gray part represents the roads.)   What is the area of this yard excluding the roads? Find it.      Note  It can be proved that the positions of the roads do not affect the area.      Constraints   A is an integer between 2 and 100 (inclusive).  B is an integer between 2 and 100 (inclusive).         Input  Input is given from Standard Input in the following format:  A  B       Output  Print the area of this yard excluding the roads (in square yards).        Sample Input 1 2 2      Sample Output 1 1  In this case, the area is 1 square yard.       Sample Input 2 5 7      Sample Output 2 24  In this case, the area is 24 square yards.

Solution (Python):
x,y = map(int,input().split())

print(x*y - x - y +1)

Solution (Python):
A,B = map(int, input().split())
print((A-1)*(B-1))

Solution (Python):
a, b = map(int, input().split())
print((a-1)*(b-1))

Solution (Python):
a,b=map(int,input().split())
ans=(a-1)*(b-1)
print(ans)

Solution (Python):
a, b = map(int, input().split())

print((a-1)*(b-1))

Solution (Python):
a, b = map(int, input().split())
print((a-1)*(b-1))

Solution (Python):
A,B=[int(a) for a in input().split(" ")]
print((A-1)*(B-1))

Solution (Python):
A,B =map(int,input().split())
print((A*B)-(A+B)+1)

Solution (Python):
x,y = map(int,input().split())
print(x * y - x - y + 1)

Solution (Python):
a,b = map(int,input().split())
print((a-1)*(b-1))

Solution (Python):
a,b=map(int,input().split());print(a*b-a-b+1)

Solution (Python):
a, b = map(int, input().split())
print((a-1) * (b-1))

Solution (Python):
a,b = map(int,input().split())
print((a-1)*(b-1))

Solution (Python):
a, b = map(int, input().split())
print(a * b - (a + b - 1))

Solution (Python):
a,b=map(int,input().split())
print((a-1)*(b-1))

Solution (Python):
a,b=map(int,input().split())
print((a-1)*(b-1))

Solution (Python):
a,b=map(int,input().split())
print((a-1)*(b-1))

Solution (Python):
a,b=map(int,input().split())
print((a-1)*(b-1))

Solution (Python):
a,b = map(int,input().split())
print(a*b-a-b+1)

Solution (Python):
a, b = map(int, input().split())
print((a-1)*(b-1))

Solution (Python):
A, B = map(int, input().split())

print(A * B - A * 1 - B * 1 + 1 * 1)

Solution (Python):
a, b = map(int,input().split())
print(a*b - (a+b-1))

Solution (Python):
A,B = list(map(int,input().split()))
print((A-1) * (B-1))

Solution (Python):
a,b = map(int,input().split())
print((a-1)*(b-1))

Solution (Python):
a,b = map(int,input().split())

print((a * b) - ( a + b - 1))

Solution (Python):
a, b = map(int,input().split())
print(a*b - (a+b-1))

Solution (Python):
A, B = map(int, input().split())
print((A - 1) * (B - 1))

Solution (Python):
a, b = [int(i) for i in input().split()]
print(a*b-(a + b -1))

Solution (Python):
a,b=map(int,input().split())
print((a-1)*(b-1))

Solution (Python):
a, b = map(int, input().split())
ans = a*b - (a+b-1)
print(ans)

Solution (Python):
A,B = map(int, input().strip().split(' '))
print((A-1)*(B-1))

Solution (Python):
A,B = map(int,input().split())
print((A-1) * (B-1))

Solution (Python):
A,B=map(int,input().split())
print((A-1)*(B-1))

Solution (Python):
a, b = map(int, input().split())
print(a * b - a - b + 1)

Solution (Python):
a,b=map(int,input().split())

m=a*b-a-b+1

print(int(m))

Solution (Python):
A,B = list(map(int,input().split()))
ans = (A-1)*(B-1)
print(ans)

Solution (Python):
a,b = map(int,input().split())
print((a-1)*(b-1))

Solution (Python):
a, b = (int(_) for _ in input().split())  

print(int((a-1)*(b-1)))

Solution (Python):
nums = [(int(i) - 1) for i in input().split()] 

print(nums[0] * nums[1])

Solution (Python):
a,b=map(int,input().split())
print((a-1)*(b-1))

Solution (Python):
a,b=map(int,input().split())
print(a*b-a-b+1)

Solution (Python):
a,b=map(int,input().split())
print(a*b-a-b+1)

Solution (Python):
A, B = map(int, input().split())
ans = A * B
ans -= A + B - 1
print(ans)

Solution (Python):

import sys
from math import *
from itertools import *
from collections import *
from functools import *
try:
    from math import gcd
except Exception:
    from fractions import gcd


def solve(A: int, B: int):
    return A * B - A - B + 1


def main():
    def iterate_tokens():
        for line in sys.stdin:
            for word in line.split():
                yield word
    tokens = iterate_tokens()
    A = int(next(tokens))  
    B = int(next(tokens))  
    result = solve(A, B)
    print(result)

if __name__ == '__main__':
    main()

Solution (Python):
A,B=map(int,input().split())
print((A-1)*(B-1))

Solution (Python):


A,B = map(int, input().split(' '))

print((A-1)*(B-1))

Solution (Python):
import sys
input = sys.stdin.readline

a, b = map(int, input().split())

print((a-1)* (b-1))

Solution (Python):
a, b = map(int, input().split())
print((a-1)*(b-1))

Solution (Python):

def main():
    a, b = map(int, input().split())
    print((a - 1) * (b - 1))

if __name__ == '__main__':
    main()

Solution (Python):
A, B = map(int, input().rstrip().split())
print(A*B-A-B+1)

Solution (Python):
a,b = map(int,input().split())
print(a*b - a - b + 1)

Solution (Python):
[A,B] = list(map(int,input().split()))
print((A-1)*(B-1))

Solution (Python):
A, B = map(int, input().split())
print((A-1)*(B-1))

Solution (Python):
a,b=list(map(int,input().split()))
print((a-1)*(b-1))

Solution (Python):

import sys


def solve(A: int, B: int):
    ret = A * B - (A + B - 1)
    print(ret)
    return


def main():
    def iterate_tokens():
        for line in sys.stdin:
            for word in line.split():
                yield word
    tokens = iterate_tokens()
    A = int(next(tokens))  
    B = int(next(tokens))  
    solve(A, B)

if __name__ == '__main__':
    main()

Solution (Python):
A,B = map(int,input().split())
print((A-1)*(B-1))

Solution (Python):
A, B = map(int, input().split())

print((A - 1) * (B - 1))

Solution (Python):
a,b=map(int, input().split())
print((a-1)*(b-1))

Solution (Python):
a,b = map(int,input().split())
print(a*b-(a+b-1))

Solution (Python):
ablist=input().split()
a=int(ablist[0])
b=int(ablist[1])
ans=(a-1)*(b-1)
print(ans)

Solution (Python):
a,b=map(int,input().split())
print(a*b-a-b+1)

Solution (Python):
A, B = map(int, input().split())
print((A-1) * (B-1))

Solution (Python):
a,b=map(int,input().split())
print((a-1)*(b-1))

Solution (Python):
a, b = map(int, input().split())
load = a + b - 1
print(a * b - load)

Solution (Python):
A,B = map(int,input().split())
print((A-1) * (B-1))

Solution (Python):
a, b = map(int, input().split())
print((a - 1) * (b - 1))

Solution (Python):
A, B = map(int, input().split())
print((A - 1) * (B - 1))

Solution (Python):
A, B = map(int, input().split())
print(A * B - A - B + 1)

Solution (Python):
A,B = map(int,input().split())
print((A-1)*(B-1))

Solution (Python):
a,b=map(int,input().split())
print((a-1)*(b-1))

Solution (Python):
import functools

import os

INF = float('inf')


def inp():
    return int(input())


def inpf():
    return float(input())


def inps():
    return input()


def inl():
    return list(map(int, input().split()))


def inlf():
    return list(map(float, input().split()))


def inls():
    return input().split()


def debug(fn):
    if not os.getenv('LOCAL'):
        return fn

    @functools.wraps(fn)
    def wrapper(*args, **kwargs):
        print('DEBUG: {}({}) -> '.format(
            fn.__name__,
            ', '.join(
                list(map(str, args)) +
                ['{}={}'.format(k, str(v)) for k, v in kwargs.items()]
            )
        ), end='')
        ret = fn(*args, **kwargs)
        print(ret)
        return ret

    return wrapper

a, b = inl()
print((a-1)*(b-1))

Solution (Python):
a,b = map(int,input().split())
print((a-1)*(b-1))

Solution (Python):
A, B = map(int, input().split())
print((A-1)*(B-1))

Solution (Python):
a,b=map(int, input().split())

print((a-1)*(b-1))

Solution (Python):

a, b = list(map(int, input().rstrip().split()))
print((a - 1) * (b - 1))

Solution (Python):
a, b = map(int, input().split())
print(a*b-a-b+1)

Solution (Python):
n,i=map(int,input().split())
print((n-1)*(i-1))

Solution (Python):
A, B = (int(i) for i in input().split())

print((A-1)*(B-1))

Solution (Python):
A, B = map(int, input().split())
print(A * B - A - B + 1)

Solution (Python):
a,b =map(int, input().split())
print((a-1)*(b-1))

Solution (Python):
a,b=map(int,input().split())
print((a-1)*(b-1))

Solution (Python):
a, b = map(int, input().split())
print((a - 1) * (b - 1))

Solution (Python):
a, b = map(int, input().split())
print(a*b-a-b+1)

Solution (Python):
a,b = map(int, input().split())
c = (a-1) * (b-1)
print(c)

Solution (Python):
A,B=map(int,input().split())
print((A-1)*(B-1))

Solution (Python):
A,B = list(map(int, input().split()))

print ((A -1) * (B-1))

Solution (Python):
A,B=map(int,input().split())
ans=A*B-A-B+1
print(ans)

Solution (Python):
A, B = map(int, input().split())
print((A-1)*(B-1))

Solution (Python):
A,B = map(int, input().split())
print((A-1)*(B-1))

Solution (Python):
a,b=map(int,input().split())
print(a*b-a-b+1)

Solution (Python):


A, B = map(int, input().split())

print(A * B - A - B + 1)

Solution (Python):
A,B = map(int,input().split())
print(A*B - (A+B) + 1)

Solution (Python):
a, b = map(int, input().split())
print((a-1)*(b-1))

Solution (Python):
a,b=map(int,input().split())
print(a*b-a-b+1)

Solution (Python):
A,B = map(int,input().split())
ans  = A*B + 1 - A - B
print(ans)

Solution (Python):
a,b = map(int,input().split())
print(a*b-a-b+1)

Solution (Python):
a,b = map(int,input().split())

print((a-1)*(b-1))

Solution (Python):
A,B = map(int,input().split())
print((A-1)*(B-1))

Solution (Python):


A,B= map(int,input().split())

print(A*B - (A+B-1))

Solution (Python):
A,B = map(int,input().split())

print(A*B -(A+B-1))

Solution (Python):
A,B = map(int,input().split())
print(int(A*B - (A+B-1)))

Solution (Python):
A, B = map(int, input().split())

print(A * B - B - A +1)

Solution (Python):
A,B = map(int,input().split())
ans = (A - 1) * (B - 1)
print(ans)

Solution (Python):
A, B = map(int, input().split())
print((A-1)*(B-1))

Solution (Python):
a,b=map(int,input().split())
print((a-1)*(b-1))

Solution (Python):
a,b=map(int, input().split())
print((a-1)*(b-1))

Solution (Python):
a,b = map(int,input().split())
print(a*b - a -(b-1))

Solution (Python):
a,b=map(int,input().split())
print((a-1)*(b-1))

Solution (Python):
def main():
	A, B = map(int, input().split())

	print((A-1)*(B-1))


if __name__ == '__main__':
    main()

Solution (Python):
def main():
	A, B = map(int, input().split())

	print((A-1)*(B-1))


if __name__ == '__main__':
    main()

Solution (Python):
a, b = map(int, input().split())
print((a - 1) * (b - 1))

Solution (Python):

A, B = map(int, input().split())
print((A - 1) * (B - 1))

Solution (Python):

A, B = map(int, input().split())
print((A - 1) * (B - 1))

Solution (Python):
A, B = map(int, input().split())
print((A - 1) * (B - 1))

Solution (Python):
a,b = map(int,input().split())
print((a-1)*(b-1))

Solution (Python):
a, b=map(int, input().split())
print((a-1)*(b-1))

Solution (Python):
x, y = map(int, input().split(' '))
print((x - 1) * (y - 1))

Solution (Python):
A, B = map(int, input().split())
print((A-1)*(B-1))

Solution (Python):
A,B = map(int, input().split())
print(int((A-1)*(B-1)))

Solution (Python):
import numpy as np

class Calculator:
    def __init__(self, arr):
        self.arr = arr

    def get_result(self):
        return (self.arr[0] - 1) * (self.arr[1] - 1)

def main():
    A, B, = map(int, input().split())
    arr = np.array([A, B], dtype=int)
    calc = Calculator(arr)
    print(calc.get_result())

if __name__ == "__main__":
    main()

Solution (Python):
A, B = map(int, input().split())

print((A-1)*(B-1))

Solution (Python):
a,b = [int(i) for i in input().split()]
c = a + b - 1
print(a * b - c)

Solution (Python):
A, B = map(int, input().split())

road = A + B - 1

print(A * B - road)

Solution (Python):
a,b = map(int,input().split())
print((a-1) * (b-1))

Solution (Python):


def main():
    A, B = [int(x) for x in input().split()]
    print((A-1)*(B-1))


if __name__ == '__main__':
    main()

Solution (Python):
A, B = map(int, input().split())

print(A*B-A-B+1)

Solution (Python):
a,b=map(int,input().split())
print(int((a-1)*(b-1)))

Solution (Python):
a,b=input().split()
A=int(a)
B=int(b)
print((A-1)*(B-1))

Solution (Python):
A,B = map(int,input().split())
print(A * B - A - B + 1)

Solution (Python):
a,b=map(int,input().split())
print((a-1)*(b-1))

Solution (Python):
A,B=map(int,input().split())
print((A-1)*(B-1))

Solution (Python):


A, B = map(int, input().split())

print(A * B - A - B + 1)

Solution (Python):
a, b = map(int, input().split())
print((a - 1) * (b - 1))

Solution (Python):
A, B = map(int, input().split())

print((A-1)*(B-1))

Solution (Python):
a, b = map(int, input().split())
print((a - 1) * (b - 1))

Solution (Python):
A, B = map(int, input().split())
print(A*B - A - B + 1)

Solution (Python):
A, B = map(int, input().split())
print((A-1)*(B-1))

Solution (Python):
a, b = map(int, input().split())

ans = (a - 1) * (b - 1)
print(ans)

Solution (Python):
A,B=map(int,input().split())
print(A*B-A-B+ 1)

Solution (Python):

import sys
import itertools
import collections
import functools
import math
from queue import Queue

INF = float("inf")


def solve(A: int, B: int):
    print((A-1)*(B-1))
    return


def main():

    def iterate_tokens():
        for line in sys.stdin:
            for word in line.split():
                yield word
    tokens = iterate_tokens()
    A = int(next(tokens))  
    B = int(next(tokens))  
    solve(A, B)


if __name__ == '__main__':
    main()

Solution (Python):
a, b = map(int, input().split())

print((a-1)*(b-1))

Solution (Python):
A, B = map(int, input().split())
print((A - 1) * (B - 1))

Solution (Python):
a, b = map(int, input().split())

print((a - 1) * (b - 1))

Solution (Python):
A, B = map(int,input().split())
print((A-1)*(B-1))

Solution (Python):
from collections import Counter
from functools import reduce
import fractions
import math
import statistics
import sys
import time
sys.setrecursionlimit(10**7)
INF = 10 ** 18
MOD = 10 ** 9 + 7
def LI(): return [int(x) for x in sys.stdin.readline().split()]  
def LF(): return [float(x) for x in sys.stdin.readline().split()]  
def LS(): return sys.stdin.readline().split()  
def MI(): return map(int, sys.stdin.readline().split())  
def II(): return int(sys.stdin.readline())  
def IS(): return input()  
def P(x): return print(x)
def C(x): return Counter(x)
def GCD_LIST(numbers):  
    return reduce(fractions.gcd, numbers)
def LCM_LIST(numbers):  
    return reduce(LCM, numbers)
def LCM(m, n):
    return (m * n // fractions.gcd(m, n))


a, b = MI()
P((a-1) * (b-1))

Solution (Python):
a,b = map(int, input().split())
print(a*b-(a+b)+1)

Solution (Python):
def main():
    A, B = map(int, input().split(' '))
    print((A-1) * (B-1))

main()

Solution (Python):
a, b = map(int, input().split())
print((a-1) * (b-1))

Solution (Python):
A,B = map(int, input().split())
print((A-1)*(B-1))

Solution (Python):
a,b = map(int,input().split())
print((a-1)*(b-1))

Solution (Python):
A,B = list(map(int,input().split()))
print((A-1)*(B-1))

Solution (Python):
N,K=map(int,input().split())
print((N-1)*(K-1))

Solution (Python):
a, b = map(int, input().split())
print((a-1)*(b-1))

Solution (Python):
a,b = map(int,input().split())
print((a-1)*(b-1))

Solution (Python):
A, B = map(int, input().split())
print(A * B - B - A + 1)

Solution (Python):
a, b = map(int, input().split())

print((a-1) * (b-1))

Solution (Python):
a,b = map(int,input().split())
print((a-1)*(b-1))

Solution (Python):
A,B = list(map(int,input().split()))
print((A-1)*(B-1))

Solution (Python):
a,b=map(int,input().split())
 
print(a*b-(a+b-1))

Solution (Python):
a,b=map(int,input().split());print(~-a*~-b)

Solution (Python):
a,b=map(int,input().split())
print((a-1)*(b-1))

Solution (Python):



a, b = map(int, input().split())

print((a-1)*(b-1))

Solution (Python):
a,b = map(int,input().split())
print((a-1) * (b-1))

Solution (Python):
A, B = map(int, input().split())
print(A*B-(A + B) + 1)

Solution (Python):
A, B = map(int, input().split())
print(A*B-(A + B) + 1)

Solution (Python):
A,B = list(map(int,input().split()))
print((A-1)*(B-1))

Solution (Python):
a,b=map(int,input().split())
print((a-1)*(b-1))

Solution (Python):
a, b = map(int, input().split())

print((a - 1) * (b - 1))

Solution (Python):
A,B = map(int,input().split())

ans = A*B-(A+B-1)

print(ans)

Solution (Python):


a, b = map(int,input().split())

print(a*b - a - b + 1)

Solution (Python):
A,B = map(int,input().split())
print(A*B - (A+B-1))

Solution (Python):

A, B = map(int, input().split())
print((A - 1) * (B - 1))

Solution (Python):
A, B = map(int, input().split())
print((A-1)*(B-1))

Solution (Python):
A, B = [int(x) for x in input().split()]
print(A*B - (A+B-1))

Solution (Python):
A,B = map(int,input().split())

S = A * B
print(S - A - B + 1)

Solution (Python):
a, b = map(int, input().split())
print((a-1)*(b-1))

Solution (Python):
A, B = map(int,input().split(' '))
print((A-1) * (B-1))

Solution (Python):
A,B = [int(x) for x in input().split()]
print((A-1)*(B-1))

Solution (Python):
a,b = map(int,input().split())
print((a-1)*(b-1))

Solution (Python):
a, b = [int(item) for item in input().split()]

print((a-1) * (b-1))

Solution (Python):
A,B=map(int,input().split())
print((A-1)*(B-1))

Solution (Python):
A, B = map(int, input().split())
print(A*B-A-B+1)

Solution (Python):
a_yard, b_yard = map(int, input().split())

area = (a_yard - 1) * (b_yard - 1)

print(area)

Solution (Python):
a,b=list(map(int,input().split()))
print((a-1)*(b-1))

Solution (Python):
NAB=list(map(int,input().split()))
print(NAB[0]*NAB[1]-(NAB[0]+NAB[1]-1))

Solution (Python):
a, b = map(int, input().split())
print((a-1)*(b-1))

Solution (Python):
a, b = map(int, raw_input().split())
x = a - 1
y = b - 1
print x * y

Solution (Python):
l = [int(i) for i in input().split()]
print((l[0]-1)*(l[1]-1))

Solution (Python):
a,b=map(int,input().split())
print(a*b-a-b+1)

Solution (Python):
a, b = map(int, input().split())
ans = a*b - a - b + 1
print(ans)

Solution (Python):
a,b=map(int,input().split())
print((a-1)*(b-1))

Solution (Python):
a,b=map(int,input().split());print((a-1)*(b-1))

Solution (Python):
i = list(map(int, input().split()))
A = i[0]
B = i[1]

a = A - 1
b = B - 1

print(a * b)

Solution (Python):
a,b=map(int,input().split())
print((a-1)*(b-1))

Solution (Python):
A,B=map(int,input().split())
print((A-1)*(B-1))

Solution (Python):
A,B=map(int,input().split())
print((A-1)*(B-1))

Solution (Python):
a,b=map(int,input().split())
print((a-1)*(b-1))

Solution (Python):
A, B = map(int, input().split())
print((A-1)*(B-1))

Solution (Python):
a, b = map(int, input().split())
print((a-1)*(b-1))

Solution (Python):
a,b=map(int,input().split());print((a-1)*(b-1))

Solution (Python):
a,b = map(int, input().split())
print((a-1)*(b-1))

Solution (Python):
A, B = [int(x) for x in input().split()]
print((A-1)*(B-1))

Solution (Python):
A, B = map(int, input().split())
print((A*B) - (A+B) + 1)

Solution (Python):
A,B=map(int, input().split())
print(A*B-A-B+1)

Solution (Python):
ri = lambda: int(input())
rl = lambda: list(map(int,input().split()))
rr = lambda N: [ri() for _ in range(N)]
YN = lambda b: print('YES') if b else print('NO')
yn = lambda b: print('Yes') if b else print('No')
OE = lambda x: print('Odd') if x%2 else print('Even')
INF = 10**18

A,B=rl()
print((A-1)*(B-1))

Solution (Python):
num = input().split(' ')
a = int(num[0]) - 1
b = int(num[1]) - 1
print(a*b)

Solution (Python):
A,B=map(int,input().split())
print((A-1)*(B-1))

Solution (Python):
A, B = map(int, input().split())
print((A - 1) * (B - 1))

Solution (Python):
A, B = map(int, input().split())
print((A-1)*(B-1))

Solution (Python):
A, B = map(int, input().split())
print((A - 1) * (B - 1))

Solution (Python):
a, b = map(int, input().split())
print((a-1)*(b-1))

Solution (Python):
A,B=map(int,input().split())
print(A*B-A-B+1)

Solution (Python):
A,B = map(int,input().split())
S = A*B - A*1 - (B-1)*1
print(S)

Solution (Python):
a,b = map(int, input().split())
print((a-1)*(b-1))

Solution (Python):
A,B=map(int,input().split())
print(A*B+1-(A+B))

Solution (Python):
a, b = (int(i) for i in input().split())  

print(a*b-(a+b-1))

Solution (Python):
a,b = map(int,input().split())
print((a-1)*(b-1))

Solution (Python):
a,b=map(int,input().split())
print((a-1)*(b-1))

Solution (Python):
a,b = (int(x) for x in input().split())
print((a-1) * (b-1))

Solution (Python):
A, B = map(int, input().split())

print((A-1)*(B-1))

Solution (Python):
a,b=map(int,input().split())
blank=a+b-1
print(a*b-blank)

Solution (Python):
A,B= (int(_) for _ in input().split()) 
print((A-1)*(B-1))

Solution (Python):
A,B = map(int, input().split())
print((A-1)*(B-1))

Solution (Python):

A, B = map(int, input().split())
print((A - 1) * (B - 1))

Solution (Python):
A, B = map(int,input().split())
print((A-1)*(B-1))

Solution (Python):
a,b=map(int,input().split(' '))
print((a-1)*(b-1))

Solution (Python):
A,B=map(int,input().split())
print(A*B-A-B+1)

Solution (Python):
a,b=map(int,input().split())
print(int((a-1)*(b-1)))

Solution (Python):
a,b=map(int,input().split())
print((a-1)*(b-1))

Solution (Python):
h, w = map(int, input().split())
print(h * w - h - w + 1)

Solution (Python):
a,b = map(int,input().split())
print((a*b)-a-b+1)

Solution (Python):
A,B=map(int,input().split())
A=A-1
B=B-1
print(A*B)

Solution (Python):
A, B = map(int, input().split())
print((A - 1) * (B - 1))

Solution (Python):
a,b=[int(i) for i in input().split()]
c=a-1
d=b-1
print(c*d)

Solution (Python):
def garden(A: int, B: int) -> int:
    return (A - 1) * (B - 1)


if __name__ == "__main__":
    A, B = map(int, input().split())
    ans = garden(A, B)
    print(ans)

Solution (Python):
A, B = map(int,input().split())
ans = (A - 1) * (B - 1)
print(ans)

Solution (Python):
A,B=map(int,input().split())
print((A-1)*(B-1))

Solution (Python):


import sys 


a,b = map(int, sys.stdin.readline().rstrip().split())
print((a-1)*(b-1))

Solution (Python):
a,b=map(int,input().split())
print((a-1)*(b-1))

Solution (Python):
A, B = map(int, input().split())
print((A - 1) * (B - 1))

Solution (Python):
A, B = map(int,input().split())
print((A-1)*(B-1))

Solution (Python):
a,b=map(int,input().split())
print(a*b-(a+b-1))

Solution (Python):
A, B = map(int, input().split())
print((A-1) * (B-1))

Solution (Python):
A,B=map(int,input().split())
print(A*B-A-B+1)

Solution (Python):
A,B=map(int,input().split())
print((A-1)*(B-1))

Solution (Python):
a,b=map(int,input().split());print((a-1)*(b-1))

Solution (Python):
A, B = map(int, input().split())
print(A * B - (A + B -1))

Solution (Python):
A, B = map(int, input().split())
print((A - 1) * (B - 1))

Solution (Python):
A,B = map(int,input().split())
answer =(A-1)*(B-1)
print(answer)

Solution (Python):
n ,k = map(int,input().split())

print((n-1)*(k-1))

Solution (Python):
def solve(string):
    a, b = map(int, string.split())
    return str((a - 1) * (b - 1))


if __name__ == '__main__':
    print(solve(input()))

Solution (Python):
A,B=map(int,input().split())
print((A-1)*(B-1))

Solution (Python):
A,B=map(int,input().split())
print(A*B-A-B+1)

Solution (Python):
A,B = map(int,input().split())
print(A*B-A-B+1)

Solution (Python):
A, B = map(int, input().split())
S = (A - 1) * (B - 1)
print(S)

Solution (Python):
A, B = [ int(x) for x in input().split() ]

ans = (A - 1) * (B - 1)

print(ans)
print()

Solution (Python):
A,B = map(int, input().split())
print((A-1)*(B-1))

Solution (Python):

a, b = [int(x) for x in input().split()]
print(a * b - (a + b - 1))

Solution (Python):
a,b=map(int,input().split())
print(a*b-(a+b-1))

Solution (Python):
A,B=map(int,input().split())
print((A-1)*(B-1))

Solution (Python):
a,b=map(int, input().split())
c = a - 1
d = b - 1
print(c*d)

Solution (Python):
a,b=map(int,input().split())
print((a-1)*(b-1))

Solution (Python):
A,B=map(int,input().split())
print((A-1)*(B-1))

Solution (Python):
def main():
    A, B = map(int, input().split())
    print((A-1)*(B-1))


if __name__ == "__main__":
    main()

Solution (Python):
A,B = map(int, input().split())
print((A-1)*(B-1))

Solution (Python):
a,b=map(int,input().split())
print(a*b-a-b+1)

Solution (Python):
A,B=(int(i) for i in input().split())
print((A-1)*(B-1))

Solution (Python):
a,b = map(int, input().split())
print((a - 1) * (b - 1))

Solution (Python):
A,B = map(int,input().split())
print(A*B-A-B+1)

Solution (Python):
nums=input().split(" ")
print((int(nums[0])-1)*(int(nums[1])-1))

Solution (Python):
a,b = map(int,input().split())
print((a-1)*(b-1))

Solution (Python):
a, b = map(int, input().split())
print(a * b - a - b + 1)

Solution (Python):
a, b = list(map(int,input().split(" ")))
print((a-1)*(b-1))

Solution (Python):
A, B = map(int, input().split())
print((A-1)*(B-1))

Solution (Python):
a,b=map(int,input().split())
print((a-1)*(b-1))

Solution (Python):
a, b = map(int, input().split())

print((a * b) - (a + b - 1))

Solution (Python):
a, b = map(int, input().split())
print(a * b - (a + b - 1))

Solution (Python):
from sys import stdin
a, b = [int(x) for x in stdin.readline().rstrip().split()]
print(a*b-(b+(a-1)))

Solution (Python):
def main():
    A, B = map(int, input().split())
    S_all = A * B
    S_road = A + B - 1
    print(S_all - S_road)


if __name__ == "__main__":
    main()

Solution (Python):
a,b = map(int, input().split())
print(a*b-a-b+1)

Solution (Python):
a,b=map(int,input().split());print(a*b-a-b+1)

Solution (Python):
a,b = (int(x) for x in input().split())

a=a-1
b=b-1

print(a*b)

Solution (Python):
A, B = map(int, input().split())
print((A - 1)*(B - 1))

Solution (Python):
a,b = map(int,input().split())
print(a*b-(a+b-1))

Solution (Python):
a, b = map(int, input().split())

print((a-1)*(b-1))

Solution (Python):
A, B = map(int, input().split())
print((A - 1) * (B - 1))

Solution (Python):
a, b = map(int, input().split())
print((a-1)*(b-1))

Solution (Python):
A, B = map(int, input().split())
print((A - 1) * (B - 1))

Solution (Python):
n,k = map(int, input().split())
print((n-1)*(k-1))

Solution (Python):
def main() -> None:
    A, B = map(int, input().split())
    print((A - 1) * (B - 1))


if __name__ == '__main__':
    main()

Solution (Python):
a,b = map(int,input().split())
print((a-1)*(b-1))

Solution (Python):
import math, string, itertools, fractions, heapq, collections, re,  array, bisect, sys, random, time, copy, functools


sys.setrecursionlimit(10**7)
inf = 10 ** 20
eps = 1.0 / 10**10
mod = 10**9+7
dd = [(-1, 0), (0, 1), (1, 0), (0, -1)]
ddn = [(-1, 0), (-1, 1), (0, 1), (1, 1), (1, 0), (1, -1), (0, -1), (-1, -1)]


def LI(): return [int(x) for x in sys.stdin.readline().split()]
def LI_(): return [int(x)-1 for x in sys.stdin.readline().split()]
def LF(): return [float(x) for x in sys.stdin.readline().split()]
def LS(): return sys.stdin.readline().split()
def I(): return int(sys.stdin.readline())
def F(): return float(sys.stdin.readline())
def S(): return input()
def pf(s): return print(s, flush=True)


def main():
    A, B = LI()
    print(A*B - A - B + 1)

main()

Solution (Python):
A,B=map(int, input().split())

result=(A-1)*(B-1)

print(result)

Solution (Python):
a,b=map(int,input().split())
print(a*b-a-b+1)

Solution (Python):
A, B = [int(x) for x in input().split()]

print(A * B - A - B + 1)

Solution (Python):
import numpy as np

def input_numbers():
    temp = list(map(int, input().split()))
    return temp

def GCD(a, b):
    if(a < b):
        temp = a
        a = b
        b = temp
    a = a % b
    if(a == 0):
        return b
    else:
        return GCD(a, b)

x = input_numbers()

ans = (x[0] - 1) * (x[1] - 1)

print(ans)

Solution (Python):
int_a, int_b = map(int, input().split())

print((int_a - 1) * (int_b - 1))

Solution (Python):
A,B = map(int,input().split())
print((A-1)*(B-1))

Solution (Python):
A, B = map(int, input().split())
print((A - 1) * (B - 1))

Solution (Python):
dims = raw_input()
a,b = int(dims.split(" ")[0]),int(dims.split(" ")[1])
a -=1
b-=1
print(a*b)

Solution (Python):
import sys

def main():
  input = sys.stdin.readline
  A, B = map(int, input().split())
  print(A * B - A - B + 1)


if __name__ == '__main__':
  main()

Solution (Python):
A,B = list(map(int,input().split()))
print((A-1) * (B - 1))

Solution (Python):

a, b = map(int, input().split())

print((a-1)*(b-1))

Solution (Python):
A, B = map(int, input().split())
print((A - 1) * (B - 1))

Solution (Python):
a,b = map(int,input().split())
print((a-1)*(b-1))

Solution (Python):
a,b = map(int,input().split())
print((a-1)*(b-1))

Solution (Python):
a,b=[int(i) for i in input().split()]
print((a-1)*(b-1))

Solution (Python):
a, b = map(int, input().split())
print((a-1)*(b-1))

Solution (Python):
a, b = map(int, input().split())
print(a * b - a - b + 1)

Solution (Python):
A,B = map(int,input().split())

sum = A + B -1
land_area = A * B
land_area -= sum
print(land_area)

Solution (Python):
A,B=map(int,input().split())
print((A-1)*(B-1))

Solution (Python):
A, B = map(int,input().split())
print((A-1)*(B-1))

Solution (Python):
a,b=map(int,input().split())
print((a-1)*(b-1))

Solution (Python):
a,b = list(map(int,input().split()))
area = a*b
road1 = (a-1)*1
road2 = b*1
print(area-road1-road2)

Solution (Python):
n,m=map(int,input().split())
print((n-1)*(m-1))

Solution (Python):
a,b = map(int,input().split())
print((a-1)*(b-1))

Solution (Python):
a, b = map(int, input().split())
ans = a*b - (a-1)*1 - b*1
print(ans)

Solution (Python):
a,b=map(int,input().split())
print(~-a*~-b)

Solution (Python):
a, b = map(int, input().split())
print((a-1)*(b-1))

Solution (Python):
A, B =list(map(int, input().split()))
print((A-1) * (B-1))

Solution (Python):
a,b = map(int,input().split())
print(a*b-(a+b-1))

Solution (Python):
a,b = map(int, input().split())
print((a-1)*(b-1))

Solution (Python):
a,b = map(int,input().split())
print((a-1)*(b-1))

Solution (Python):
a,b=map(int,input().split())
print((a-1)*(b-1))

Solution (Python):
a,b= map(int,input().split())
print((a-1)*(b-1))

Solution (Python):
a,b = map(int,input().split())
print(a*b-a-b+1)

Solution (Python):
A, B = map(int,input().split())
print((A-1) * (B-1))

Solution (Python):
A,B = map(int,input().split())
print((A-1)*(B-1))

Solution (Python):
A, B = map(int, input().split())
print( (A-1) * (B-1))

Solution (Python):
A,B=map(int,input().split())
print((A-1)*(B-1))

Solution (Python):
A, B = map(int,input().split())
print((A-1)*(B-1))

Solution (Python):
A, B = map(int, input().split())
print((A - 1) * (B - 1))

Solution (Python):
a,b=map(int,input().split())
print(a*b-a-b+1)

Solution (Python):
a,b=map(int,input().split())
print((a-1)*(b-1))

Solution (Python):

A, B = map( int, input().split(' '))

print( (A - 1) * (B - 1) )

Solution (Python):
a, b = map(int,input().split())
o = a*b
t = a+b
print(o-t+1)

Solution (Python):
A, B = map(int, input().split())

print(A*B-(A+B-1))

Solution (Python):
def main():
    A, B = map(int, input().split())
    print((A - 1) * (B - 1))


main()

Solution (Python):
a, b = map(int, input().split(' '))
print((a-1) * (b-1))

Solution (Python):
"""AtCoder"""

import sys
input = sys.stdin.readline

A, B = map(int, input().split())

print((A - 1) * (B - 1))

Solution (Python):


def main():
    na = list(map(int, input().split()))
    A, B = na[0], na[1]

    print((A - 1) * (B - 1))


if __name__ == '__main__':
    main()

Solution (Python):
a, b = map(int, input().split())
print(a * b - a - b + 1)

Solution (Python):
A, B = map(int,input().split())

print(A*B-A-B+1)