#include<math.h> #include<iostream> using namespace std; int main(){ long long a,b; cin>>a>>b; cout<<pow(a+1,b); return 0; }