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 140 / 180 1500
Divisibility 2 105 / 134 1500
Coprime query 97 / 109 1500
GCD pairs counting 89 / 94 1500
Good string pairs 55 / 63 1500
Permutation problem 52 / 56 1600
Restricted equation 45 / 50 1700
Moving through matrix 49 / 53 1700
Restricted equation 2 32 / 33 1800
Binary matrix 2 38 / 45 1900
Permutation Counting 2 19 / 36 2000