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 102 / 138 1500
Divisibility 2 72 / 97 1500
Coprime query 69 / 77 1500
GCD pairs counting 61 / 67 1500
Good string pairs 33 / 39 1500
Permutation problem 32 / 35 1600
Restricted equation 26 / 30 1700
Moving through matrix 27 / 29 1700
Restricted equation 2 13 / 13 1800
Binary matrix 2 23 / 27 1900
Permutation Counting 2 12 / 24 2000