洛谷 P4310 题解

洛谷 P4310 题解

$\text{Description}$

给定一个序列 $\{a\}_{i=1}^{n}$,求出其满足任意非首元素与之前驱元素的按位与非零的子序列的最大长度。

$n\le 10^5,a_i\le 10^9$.

CF1327F 题解

CF1327F 题解

$\text{Description}$

给定 $n,k,m$ 及 $m$ 个限制三元组形如 $(l_i,r_i,x_i)$。

计算满足下列条件且长度为 $n$ 的序列 $a$ 数量:

  • $\forall i\in [1,n],a_i\in[0,2^k-1]$。
  • $\forall i\in[1,m],\bigoplus\limits_{j=l_i}^{r_i}a_j=x_i$,其中 $\bigoplus$ 表示将这些数按位与。

$n,m\le 5\times 10^5,k\le 30$。

Your browser is out-of-date!

Update your browser to view this website correctly. Update my browser now

×