CF238A.Not Wool Sequences

普及/提高-

通过率:0%

AC君温馨提醒

该题目为【codeforces】题库的题目,您提交的代码将被提交至codeforces进行远程评测,并由ACGO抓取测评结果后进行展示。由于远程测评的测评机由其他平台提供,我们无法保证该服务的稳定性,若提交后无反应,请等待一段时间后再进行重试。

题目描述

A sequence of non-negative integers a1,a2,...,ana_{1},a_{2},...,a_{n} of length nn is called a wool sequence if and only if there exists two integers ll and rr (1<=l<=r<=n)(1<=l<=r<=n) such that . In other words each wool sequence contains a subsequence of consecutive elements with xor equal to 0.

The expression means applying the operation of a bitwise xor to numbers xx and yy . The given operation exists in all modern programming languages, for example, in languages C++ and Java it is marked as "^", in Pascal — as "xor".

In this problem you are asked to compute the number of sequences made of nn integers from 0 to 2m12^{m}-1 that are not a wool sequence. You should print this number modulo 10000000091000000009 (109+9)(10^{9}+9) .

输入格式

The only line of input contains two space-separated integers nn and mm (1<=n,m<=105)(1<=n,m<=10^{5}) .

输出格式

Print the required number of sequences modulo 10000000091000000009 (109+9)(10^{9}+9) on the only line of output.

输入输出样例

  • 输入#1

    3 2
    

    输出#1

    6
    

说明/提示

Sequences of length 33 made of integers 0, 1, 2 and 3 that are not a wool sequence are (1, 3, 1), (1, 2, 1), (2, 1, 2), (2, 3, 2), (3, 1, 3) and (3, 2, 3).

首页