https://www.acmicpc.net/problem/2163
import java.util.*;
public class Main {
public static void main(String args[]) {
Scanner s=new Scanner(System.in);
int n=s.nextInt();
int m=s.nextInt();
System.out.print(n*m-1);
}
}