Skip to content

Commit

Permalink
Update 01.State-DP.md
Browse files Browse the repository at this point in the history
  • Loading branch information
itcharge committed Jun 28, 2024
1 parent cbcaba0 commit 381b4c8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Contents/10.Dynamic-Programming/07.State-DP/01.State-DP.md
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@
- 在集合 $A$ 中删除第 $i$ 位元素(将二进制数第 $i$ 位赋值为 $0$):`A = A & ~(1 << i)`
- 判断集合 $A$ 是否选取了第 $i$ 位元素(判断二进制数第 $i$ 位是否为 $1$) :`if A & (1 << i):` 或者 `if (A >> i) & 1:`
- 将集合 $A$ 设置为空集:`A = 0`
- 将集合 $A$ 设置为全集:`A = 1 << n`
- 将集合 $A$ 设置为全集:`A = 1 << n - 1`
- 求集合 $A$ 的补集:`A = A ^ ((1 << n) - 1)`
- 求集合 $A$ 与集合 $B$ 的并集:`A | B`
- 求集合 $A$ 与集合 $B$ 的交集:`A & B`
Expand Down

0 comments on commit 381b4c8

Please sign in to comment.