(function() {
    'use strict';
 
    var lines = [];
    require('readline').createInterface({
      input: process.stdin,
      output: process.stdout
    }).on('line', function(line) {
      lines.push(line);
    });
    process.stdin.on('end', function() {
      //lines.forEach(function(line) {
        //var tokens = line.split(' ').map(Number);
        //    console.log(tokens[0] + ' ' + tokens[1]);
      //}
      //)
      ;
      
    // ToDo start
      var N = parseInt(lines[0])
      var K = parseInt(lines[1])
      
      var denko = 1;

      for ( var i=1;i<N+1;i++){
//        console.log(i)
        if ( denko > K ){
            denko += K;
        } else {
            denko = denko * 2;
        }
    }
      console.log( denko )
    // ToDo end

    });

    
})();
  
  