#include<iostream>
#include<cstdio>
#include<ctime>
#include<cmath>

using namespace std;

int main(){
    float c, I;
    scanf("%f %f", &c, &I);
    float sol=c*(I-1)+1;
    printf("%.0f\n", sol);

//system("pause");
return 0;
}
