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-----
3 4

-----Sample Output-----
6

There are six blocks, as shown below:

Source: atcoder | Difficulty: EASY


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


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


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


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

def __starting_point():
	resolve()
__starting_point()


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


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


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


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


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

def __starting_point():
	iroha()
__starting_point()


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


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

def __starting_point():
	main()
__starting_point()


(n, m) = map(int, input().split())
if n == 1 or m == 1:
	print(0)
else:
	print((n - 1) * (m - 1))


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


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


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