Problem:
 Score : 100 points    Problem Statement In K-city , there are n streets running east-west, and m streets running north-south. Each street running east-west and each street running north-south cross each other. We will call the smallest area that is surrounded by four streets a block. How many blocks there are in K-city?      Constraints  2 ≤ n, m ≤ 100         Input Input is given from Standard Input in the following format:  n  m       Output Print the number of blocks in K-city.        Sample Input 1 3 4      Sample Output 1 6  There are six blocks, as shown below:          Sample Input 2 2 2      Sample Output 2 1  There are one block, as shown below:

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

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):


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


if __name__ == "__main__":
    main()

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

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

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):
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((a - 1) * (b - 1))

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

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

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

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

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

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

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):
n, m = map(int, input().split())
print((n-1)*(m-1))

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

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

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

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

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

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

print((n+1)*(m+1)-2*(n+1)-(m+1-2)*2)

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):
n,m = map(int,input().split())
print((n - 1)*(m - 1))

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

Solution (Python):
with open(0) as f:
    n, m = map(int, f.read().split())
print((n-1)*(m-1))

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

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

print((n - 1) * (m - 1))

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

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):
N,M=map(int,input().split())
print((N-1)*(M-1))

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

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):
n, m = map(int, input().split())
print((n-1)*(m-1))

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

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

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

print((n - 1) * (m - 1))

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):
m,n = map(int,input().split())
print((m-1)*(n-1))

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

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

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


if __name__ == "__main__":
    main()

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

area = (n - 1) * (m - 1)
print(area)

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

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

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

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

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

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

Solution (Python):



import sys
from io import StringIO
import unittest


class TestClass(unittest.TestCase):
    def assertIO(self, input, output):
        stdout, stdin = sys.stdout, sys.stdin
        sys.stdout, sys.stdin = StringIO(), StringIO(input)
        resolve()
        sys.stdout.seek(0)
        out = sys.stdout.read()[:-1]
        sys.stdout, sys.stdin = stdout, stdin
        self.assertEqual(out, output)

    def test_入力例_1(self):
        input = """3 4"""
        output = """6"""
        self.assertIO(input, output)

    def test_入力例_2(self):
        input = """2 2"""
        output = """1"""
        self.assertIO(input, output)


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


if __name__ == "__main__":
    
    resolve()

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

Solution (Python):
import sys

readline = sys.stdin.readline
MOD = 10 ** 9 + 7
INF = float('INF')
sys.setrecursionlimit(10 ** 5)


def main():
    x, y = map(int, readline().split())

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


if __name__ == '__main__':
    main()

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

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

print(ans)

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

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

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

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):
n, m = map(int, input().split())
print((n-1) * (m-1))

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

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


if __name__ == '__main__':
    main()

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


if __name__ == '__main__':
    main()

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

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())
print((a-1) * (b-1))

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

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

if n == 1 or m == 1:
    print(0)
else:
    print((n - 1) * (m - 1))

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





print((n - 1) * (m - 1))

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):
n,m = map(int,input().split())
print((n-1)*(m-1))

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

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

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

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

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

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

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

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

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

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

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

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

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

print((n-1)*(m-1))

Solution (Python):

n,m = map(int,input().split())


print((m-1)*(n-1))

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

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

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

print((n-1)*(m-1))

Solution (Python):
import sys, re
from math import ceil, floor, sqrt, pi, factorial, gcd
from copy import deepcopy
from collections import Counter, deque
from heapq import heapify, heappop, heappush
from itertools import accumulate, product, combinations, combinations_with_replacement
from bisect import bisect, bisect_left, bisect_right
from functools import reduce
from decimal import Decimal, getcontext

def i_input(): return int(input())
def i_map(): return map(int, input().split())
def i_list(): return list(i_map())
def i_row(N): return [i_input() for _ in range(N)]
def i_row_list(N): return [i_list() for _ in range(N)]
def s_input(): return input()
def s_map(): return input().split()
def s_list(): return list(s_map())
def s_row(N): return [s_input for _ in range(N)]
def s_row_str(N): return [s_list() for _ in range(N)]
def s_row_list(N): return [list(s_input()) for _ in range(N)]
def lcm(a, b): return a * b // gcd(a, b)
sys.setrecursionlimit(10 ** 6)
INF = float('inf')
MOD = 10 ** 9 + 7
num_list = []
str_list = []

def main():
    n, m = i_map()

    print((n-1)*(m-1))

if __name__ == '__main__':
    main()

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

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):
N,M = map(int,input().split())
print((N-1)*(M-1))

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())
print((a-1)*(b-1))

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):
n, m = map(int, input().split())

ans = (n-1) * (m-1)
print(ans)

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

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):
from sys import stdin, stdout


def main():
    line = stdin.readline()
    parts = line.split()
    a = int(parts[0])
    b = int(parts[1])

    rta = (a-1)*(b-1)
    stdout.write(str(rta))


main()

Solution (Python):
from sys import stdin, stdout


def main():
    line = stdin.readline()
    parts = line.split()
    n = int(parts[0])
    m = int(parts[1])
    stdout.write(str((n-1)*(m-1)))


main()

Solution (Python):
from sys import stdin, stdout

def main():
    line = stdin.readline()
    parts = line.split()
    m= int(parts[0])
    n = int(parts[1])
    stdout.write(str((n-1)*(m-1)))

main()

Solution (Python):
from sys import stdin,stdout

def main():
    line=stdin.readline()
    parts=line.split()
    a=int(parts[0])
    b=int(parts[1])

    stdout.write(str((a-1)*(b-1)))
main()

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

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

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

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):
n,m = map(int,input().split())
print((n-1)*(m-1))

Solution (Python):
import sys

read = sys.stdin.read
readline = sys.stdin.buffer.readline
sys.setrecursionlimit(10 ** 8)
INF = float('inf')
MOD = 10 ** 9 + 7


def main():
    N, M = map(int, readline().split())
    print((N-1)*(M-1))

if __name__ == '__main__':
    main()

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):
n,m=map(int,input().split())
print((n-1)*(m-1))

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

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

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):
n, m = map(lambda x : int(x) - 1, input().split())
print(n * m)

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

Solution (Python):
n,m = [int(i) for i in input().split()]

print((n-1)*(m-1))

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

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

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

print((n - 1) * (m - 1))

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

print((n-1)*(m-1))

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

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

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

print((n-1)*(m-1))

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


if __name__ == "__main__":
    solve()

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

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

print((n-1)*(m-1))

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

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

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

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

print((n-1)*(m-1))

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

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

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

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

Solution (Python):
from sys import stdin
nii=lambda:map(int,stdin.readline().split())
lnii=lambda:list(map(int,stdin.readline().split()))

n,m=nii()
print((n-1)*(m-1))

Solution (Python):
import sys
def input(): return sys.stdin.readline().strip()

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

if __name__ == "__main__":
    main()

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

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

print( (n-1)*(m-1) )

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

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

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

Solution (Python):



from fractions import gcd
from itertools import combinations,permutations,accumulate 

from collections import deque,defaultdict,Counter
import decimal
import re












import sys
sys.setrecursionlimit(10000000)
mod = 10**9 + 7

def readInts():
  return list(map(int,input().split()))
def I():
  return int(input())
n,m = readInts()
print((n-1) * (m-1))

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

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

Solution (Python):
import sys

sys.setrecursionlimit(10 ** 8)
ini = lambda: int(sys.stdin.readline())
inm = lambda: map(int, sys.stdin.readline().split())
inl = lambda: list(inm())
ins = lambda: sys.stdin.readline().rstrip()
debug = lambda *a, **kw: print("\033[33m", *a, "\033[0m", **dict(file=sys.stderr, **kw))

n, m = inl()


def solve():
    return (n - 1) * (m - 1)


print(solve())

Solution (Python):

















import sys, re
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, radians
from itertools import accumulate, permutations, combinations, product
from operator import itemgetter, mul
from copy import deepcopy
from string import ascii_lowercase, ascii_uppercase, digits
from bisect import bisect, bisect_left
from fractions import gcd
from heapq import heappush, heappop
from functools import reduce
import numpy as np
def input(): return sys.stdin.readline().strip()
def INT(): return int(input())
def MAP(): return map(int, input().split())
def LIST(): return list(map(int, input().split()))
def ZIP(n): return zip(*(MAP() for _ in range(n)))
sys.setrecursionlimit(10 ** 9)
INF = float('inf')
mod = 10 ** 9 + 7

n, m = MAP()
print((n - 1) * (m - 1))

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

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

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

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

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

Solution (Python):
N,M = (int(T) for T in input().split())
print((N-1)*(M-1))

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

Solution (Python):
import sys

read = sys.stdin.read
readline = sys.stdin.readline
readlines = sys.stdin.readlines
sys.setrecursionlimit(10 ** 9)
INF = 1 << 60
MOD = 1000000007


def main():
    n, m = map(int, readline().split())

    print((n - 1) * (m - 1))

    return


if __name__ == '__main__':
    main()

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

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

ans = (n - 1) * (m - 1)

print(ans)

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):
n, m = map(int, input().split())
print((n - 1) * (m - 1))

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

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

print((n-1)*(m-1))

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

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):
n, m = map(int, input().split())
print((n-1)*(m-1))

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

print((n - 1) * (m - 1))

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

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

print((n-1)*(m-1))

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

if __name__ == '__main__':
    main()

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

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

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

print((n-1)*(m-1))

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

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

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

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

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

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

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

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

print((n - 1)*(m - 1))

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

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

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

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

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

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

Solution (Python):
import sys
def LI(): 
    return list(map(int,sys.stdin.readline().rstrip().split()))  

n,m = LI()

print((n-1)*(m-1))

Solution (Python):
import sys

sys.setrecursionlimit(10**7)
def I(): return int(sys.stdin.readline().rstrip())
def LI(): return list(map(int,sys.stdin.readline().rstrip().split()))  
def LI2(): return list(map(int,sys.stdin.readline().rstrip()))  
def S(): return sys.stdin.readline().rstrip()
def LS(): return list(sys.stdin.readline().rstrip().split())  
def LS2(): return list(sys.stdin.readline().rstrip())  

n,m = LI()

print((n-1)*(m-1))

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

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

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

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

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

print((n-1)*(m-1))

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

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

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

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

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

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

print((n - 1) * (m - 1))

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

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

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

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):
n, m = map(int, input().split())
print((n-1)*(m-1))

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))-(a*2)-(b*2))

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

n,m=list(map(int,input().split()))
print((n-1)*(m-1))

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

print((n-1)*(m-1))

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

Solution (Python):
import sys
import math
import itertools
import collections
import heapq
import re
import numpy as np

rr = lambda: sys.stdin.readline().rstrip()
rs = lambda: sys.stdin.readline().split()
ri = lambda: int(sys.stdin.readline())
rm = lambda: map(int, sys.stdin.readline().split())
rl = lambda: list(map(int, sys.stdin.readline().split()))
inf = float('inf')
mod = 10**9 + 7

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

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

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

print((n-1) * (m-1))

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):
n, m = map(int,input().split())
print( (n-1)*(m-1) )

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):
n,m = map(int, input().split())

ans = (n-1)*(m-1)
print(ans)

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

Solution (Python):
import sys
import math
import itertools
import bisect
from copy import copy
from collections import deque,Counter
from decimal import Decimal
def s(): return input()
def i(): return int(input())
def S(): return input().split()
def I(): return map(int,input().split())
def L(): return list(input().split())
def l(): return list(map(int,input().split()))
def lcm(a,b): return a*b//math.gcd(a,b)
sys.setrecursionlimit(10 ** 9)
INF = 10**9
mod = 10**9+7

n,m = I()
print((n-1)*(m-1))

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

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):
n,m = map(int,input().split())
print((n-1)*(m-1))

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

print((n-1)*(m-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):
N, M = map(int, input().split())
print((N-1)*(M-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):
n,m=map(int, input().split())
print((n-1)*(m-1))

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):
n,m=map(int,input().split())
print((n-1)*(m-1))

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

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):
n,m = map(int,input().split())
print((n-1)*(m-1))

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

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

Solution (Python):
import sys
n,m = map(int,input().split())
if n < 2 or m < 2 or n > 100 or m > 100:
    sys.exit()

print((n-1)*(m-1))

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

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

answer= (n-1)*(m-1)

print(answer)

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

nm = (n - 1) * (m - 1)

print(nm)

Solution (Python):
from fractions import gcd
from collections import Counter, deque, defaultdict
from heapq import heappush, heappop, heappushpop, heapify, heapreplace, merge
from bisect import bisect_left, bisect_right, bisect, insort_left, insort_right, insort
from itertools import accumulate, product, permutations, combinations

def main():
    n, m = map(int, input().split())

    print((n-1)*(m-1))

if __name__ == '__main__':
    main()

Solution (Python):
import bisect,collections,copy,heapq,itertools,math,string
import sys
def S(): return sys.stdin.readline().rstrip()
def M(): return map(int,sys.stdin.readline().rstrip().split())
def I(): return int(sys.stdin.readline().rstrip())
def LI(): return list(map(int,sys.stdin.readline().rstrip().split()))
def LS(): return list(sys.stdin.readline().rstrip().split())
n, m = M()
print((n-1)*(m-1))

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

print((n-1)*(m-1))

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

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

answer = (n - 1 ) * ( m - 1)
print(answer)

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

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

Solution (Python):


n, m = map(int, input().split())

print((n -1) * (m - 1))

Solution (Python):
def actual(n, m):
    return (n - 1) * (m - 1)

n, m = map(int, input().split())
print(actual(n, m))

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

Solution (Python):
def resolve():
    n, m = map(int, input().split())

    ans = (n-1) * (m-1)
    print(ans)
resolve()

Solution (Python):
def main():
    n, m = map(int, input().split())
    all_place = ((n+1)*(m+1))
    outside = (2*(n+1))+(2*(m+1))-4
    print(all_place-outside)
main()

Solution (Python):
def main():
    n, m = map(int, input().split())
    outside = ((n+1)*(m+1))
    inside = (2*(n+1))+(2*(m+1))-4
    print(outside-inside)
main()

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

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

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

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

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

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):
n,m = list(map(int,input().strip().split()))

print((n-1)*(m-1))

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

print((n-1)*(m-1))

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

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

Solution (Python):
n,m=map(int,input().split())
count = 0
result=[[[i,j] for i in range(m)] for j in range(n)]
result.pop(0)
for i in result:
  i.pop()
  count += len(i)
print(count)

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

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

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

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

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

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

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

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

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):
n,m = map(int,input().split())
print((n-1) * (m-1))

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

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

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

s = (n - 1)*(m - 1)
print(s)

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

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

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

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

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

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

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

print((n-1)*(m-1))

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

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

count = (n - 1) * (m - 1)

print(count)

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

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

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

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

print((n-1)*(m-1))

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

print((n-1)*(m-1))

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

print((n-1)*(m-1))

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

Solution (Python):
n,m=map(int,input().split())
print(int((n-1)*(m-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):
n, m = map(int, input().split())
print(int((n - 1) * (m - 1)))

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):
n, m = map(int, input().split())
print((n-1)*(m-1))

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))