백준 18270 Livestock Lineup (USACO December 2019 Bronze 3번)
문제 링크: https://www.acmicpc.net/problem/18270 18270번: Livestock Lineup Every day, Farmer John milks his 8 dairy cows, named Bessie, Buttercup, Belinda, Beatrice, Bella, Blue, Betsy, and Sue. The cows are rather picky, unfortunately, and require that Farmer John milks them in an order that respects $N$ constraints ($1 \leq N \ www.acmicpc.net 소들을 알파벳 순서데로 정렬하고나서 모든 순열을 next_permutation을 이용하여 돌려보다가..