package
0.0.0-20241220224003-b7cf03a90b2b
Repository: https://github.com/szhou12/leetcode-go.git
Documentation: pkg.go.dev
# README
1774. Closest Dessert Cost
Solution idea
Brute force
Key point: 用三进制表示每一种 topping 选的量:0, 1, 2
Time complexity = $O(n\times 3^m)$