Module Inclusion-exclusion principle

Inclusion-exclusion principle

**Frequency: 5/10** A commonly used technique in solving combinatorics problem.

Resources

- [CP Algorithms: The Inclusion-Exclusion Principle](https://cp-algorithms.com/combinatorics/inclusion-exclusion.html)

Problems

Divisibility 177 / 221 1500
Divisibility 2 127 / 161 1500
Coprime query 120 / 134 1500
GCD pairs counting 106 / 111 1500
Good string pairs 72 / 81 1500
Permutation problem 64 / 68 1600
Restricted equation 54 / 59 1700
Moving through matrix 59 / 63 1700
Restricted equation 2 40 / 41 1800
Binary matrix 2 44 / 52 1900
Permutation Counting 2 22 / 43 2000