{
  "id": 2352890,
  "title": "LeetCode 3116 (Hard) — binary search + inclusion-exclusion makes it easy",
  "url": "https://urgent.news/2026/08/21/leetcode-3116-hard-binary-search-inclusion-exclusion-makes-it-easy",
  "topic": "tech",
  "section": "Tech",
  "published": "2026-08-21T09:53:53.000Z",
  "source": {
    "name": "Dev.to",
    "slug": "dev-to",
    "url": "https://dev.to/shaanlabs/leetcode-3116-hard-binary-search-inclusion-exclusion-makes-it-easy-19nd"
  },
  "original_language": "en",
  "account": null,
  "summary": "Full walkthrough: https://www.youtube.com/watch?v=vFuFA3ByCs0 LeetCode 3116 — Kth Smallest Amount With Single Denomination Combination. Here’s the trick everyone misses: Brute force (generate all multiples, pick k-th) fails because k can reach 2×10⁹. The real approach: Binary search the answer X Count valid amounts ≤ X using inclusion-exclusion Odd subsets add, even subtract (bitmask over coins)…",
  "key_points": [],
  "editors_take": null,
  "illustration": null,
  "coverage": {
    "outlets": 1,
    "also_reported_by": []
  },
  "ai_generated": true,
  "disclaimer": "Summaries, key points and the editor’s take are written by software from other outlets’ reporting and may contain errors — always check the linked original."
}