100 atcoder#ABC121A. [ABC121A] White Cells
[ABC121A] White Cells
Score : points
Problem Statement
There are rows and columns of white square cells.
You will choose of the rows and of the columns, and paint all of the cells contained in those rows or columns.
How many white cells will remain?
It can be proved that this count does not depend on what rows and columns are chosen.
Constraints
- All values in input are integers.
Input
Input is given from Standard Input in the following format:
Output
Print the number of white cells that will remain.
3 2
2 1
1
There are rows and columns of cells. When two rows and one column are chosen and painted in black, there is always one white cell that remains.
5 5
2 3
6
2 4
2 4
0