ADAMOLD - Ada and Mold
题意翻译
## 题目描述
您可能已经知道,Ada是一个农民。她有很长的犁沟,可以在上面种菜(每种菜都用开花值确定)。犁沟中的蔬菜越多,发霉的风险就越大。更具体地,霉菌值可以作为所有成对的蔬菜开花值的异或之和而获得。
Ada购买了一些木制隔板,这可能会降低模具价值。它的工作方式如下:她可以将分隔符放在某些植物之间,将犁沟分成多个部分。然后,模具值将成为所有段的模具值的总和(独立地)。您能找到最小的霉菌价值吗?
## 输入格式
输入的第一行包含两个整数N,K: 1,犁沟的长度和分隔符的数量。
接下来的行将包含N个数字0,即蔬菜的开花值。
## 输出格式
输出最小可能的模数值。
## 输入输出样例
无
题目描述
As you might already know, Ada the Ladybug is a farmer. She has a long furrow in which she grows vegetable (while each vegetable is indentified by a bloom-value). The more vegetable is in the furrow the bigger risk of mold there is. More specificaly the mold-value can be obtained as sum of **xor** of all pairs of vegetable's bloom-values.
Ada has bought a few wooden separators which could possibly reduce the mold-value. It works in following manner: she can put the separators between some plants, dividing the furrow into multiple segments. The mold-value will then becomes the sum of mold-values of all the segments (independently). Can you find the minimal possible mold-value?
输入输出格式
输入格式
The first line of input containts two integers **N, K**: **1 , the length of furrows and the number of separators.**
The next lines will contain **N** numbers **0 , the bloom-values of vegetable.**
输出格式
Output the minimal possible mold-value.