import java.util.*; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); long l = sc.nextInt(); int n = sc.nextInt(); long ans = (long)(Math.pow(2, l - 3)) * n; System.out.println(ans); } }