Color Numbers

아직 제출이 없습니다시간 제한1초메모리 제한512 MB

문제

You are given an array of non-negative integers a_1,a_2,,a_na\_1, a\_2, \ldots, a\_n and an integer kk. Two indices i,ji, j are called inconsistent if both of the two conditions hold:

  1. a_i AND a_j=a_ia\_i \text{ }\mathrm{AND}\text{ } a\_j = a\_i,
  2. Binary representation of (a_i XOR a_j)(a\_i \text{ }\mathrm{XOR}\text{ } a\_j) have at least kk bits set to 11.

Here AND\mathrm{AND} stands for bitwise and operation, XOR\mathrm{XOR} stands for bitwise exclusive-OR operation.

A consistent coloring of a_1,,a_na\_1, \ldots, a\_n in mm colors is an array of nn integers c_1,,c_nc\_1, \ldots, c\_n (1c_im1 \leq c\_i \leq m) such that there is no pair of inconsistent indices i,ji, j with c_i=c_jc\_i = c\_j.

Your task is to find the smallest possible number of colors in a consistent coloring of a_1,,a_na\_1, \ldots, a\_n.

입력

In the first line you are given two integers n,kn, k (1n,k51051\leq n, k\leq 5\cdot 10^5).

In the next line you are given nn integers a_ia\_i (0a_i<2220\leq a\_i < 2^{22}).

출력

Print one integer --- the smallest number of colors in a consistent coloring.

힌트

One possible consistent coloring in two colors is 1,1,1,21, 1, 1, 2. Since indices 22 and 44 are inconsistent, one color is not enough.