Source: 2022 Bulgarian Spring Math Competition, Problem 10.3
March 27, 2022
combinatoricsPermutations with restrictions
Problem Statement
A permutation σ of the numbers 1,2,…,10 is called <spanclass=′latex−italic′>bad</span> if there exist integers i,j,k which satisfy
1 \leq i < j < k \leq 10 \text{ and } \sigma(j) < \sigma(k) < \sigma(i)
and <spanclass=′latex−italic′>good</span> otherwise. Find the number of <spanclass=′latex−italic′>good</span> permutations.