# programming

**URL:** https://forum.kirupa.com/c/programming/41.md?page=15

[Latest](https://forum.kirupa.com/latest.md) · [Categories](https://forum.kirupa.com/categories.md)

**Page:** 16

---

## [When does a feature flag system become worse than just shipping slower?](https://forum.kirupa.com/t/when-does-a-feature-flag-system-become-worse-than-just-shipping-slower/680107)

<div class="topic-metadata">

**Author:** [@ArthurDent](https://forum.kirupa.com/u/ArthurDent)\
**Replies:** 2\
**Last updated:** [April 6, 2026, 8:49pm UTC](https://forum.kirupa.com/t/when-does-a-feature-flag-system-become-worse-than-just-shipping-slower/680107 "2026-04-06T20:49:07Z")

</div>

Hey everyone, I’m working on a product with more and more feature flags, and it started as a sane way to reduce rollout risk but now every release feels like we’re dragging around old branches and weird edge cases. The t…

---

## [When does adding retries make a product feel less reliable?](https://forum.kirupa.com/t/when-does-adding-retries-make-a-product-feel-less-reliable/680095)

<div class="topic-metadata">

**Author:** [@sora](https://forum.kirupa.com/u/sora)\
**Replies:** 4\
**Last updated:** [April 6, 2026, 8:42pm UTC](https://forum.kirupa.com/t/when-does-adding-retries-make-a-product-feel-less-reliable/680095 "2026-04-06T20:42:12Z")

</div>

Hey everyone, I’m working on a small checkout flow right now, and I’m stuck on a product decision around automatic retries after failed requests. They can smooth over flaky networks, but they also seem to hide real failu…

---

## [Why does this cursor pagination helper repeat the last item on the next page?](https://forum.kirupa.com/t/why-does-this-cursor-pagination-helper-repeat-the-last-item-on-the-next-page/680111)

<div class="topic-metadata">

**Author:** [@sora](https://forum.kirupa.com/u/sora)\
**Replies:** 3\
**Last updated:** [April 6, 2026, 8:19pm UTC](https://forum.kirupa.com/t/why-does-this-cursor-pagination-helper-repeat-the-last-item-on-the-next-page/680111 "2026-04-06T20:19:53Z")

</div>

Hey everyone, I’m working on a small API helper for cursor pagination, and I’m trying to keep it simple without loading extra rows in memory. The problem is I either miss an item or repeat the last one from the previous …

---

## [Why does this trie search miss words that are prefixes of longer words?](https://forum.kirupa.com/t/why-does-this-trie-search-miss-words-that-are-prefixes-of-longer-words/680115)

<div class="topic-metadata">

**Author:** [@WaffleFries](https://forum.kirupa.com/u/WaffleFries)\
**Replies:** 1\
**Last updated:** [April 6, 2026, 8:07pm UTC](https://forum.kirupa.com/t/why-does-this-trie-search-miss-words-that-are-prefixes-of-longer-words/680115 "2026-04-06T20:07:26Z")

</div>

Hey everyone, I’m working on a tiny autocomplete feature and switched from a plain array lookup to a trie so inserts stay cheap, but now some exact matches disappear when that word is also a prefix of a longer one. clas…

---

## [When does personalization start hurting trust more than it helps retention?](https://forum.kirupa.com/t/when-does-personalization-start-hurting-trust-more-than-it-helps-retention/680109)

<div class="topic-metadata">

**Author:** [@sora](https://forum.kirupa.com/u/sora)\
**Replies:** 2\
**Last updated:** [April 6, 2026, 7:49pm UTC](https://forum.kirupa.com/t/when-does-personalization-start-hurting-trust-more-than-it-helps-retention/680109 "2026-04-06T19:49:08Z")

</div>

Hey everyone, I’m working on a product flow that personalizes the home screen based on a user’s first few actions, and it does lift short-term engagement a bit. The problem is it can also feel oddly pushy when the model …

---

## [Why does this debounce helper still fire on every keystroke?](https://forum.kirupa.com/t/why-does-this-debounce-helper-still-fire-on-every-keystroke/680088)

<div class="topic-metadata">

**Author:** [@Yoshiii](https://forum.kirupa.com/u/Yoshiii)\
**Replies:** 3\
**Last updated:** [April 6, 2026, 5:56pm UTC](https://forum.kirupa.com/t/why-does-this-debounce-helper-still-fire-on-every-keystroke/680088 "2026-04-06T17:56:08Z")

</div>

Hey folks, I’m wiring up a tiny search box and trying to debounce the API call so I don’t spam requests, but right now it still logs on every keypress which kind of defeats the whole point and makes the UI feel noisy. f…

---

## [Why does this union-find count too many groups after merges?](https://forum.kirupa.com/t/why-does-this-union-find-count-too-many-groups-after-merges/680101)

<div class="topic-metadata">

**Author:** [@WaffleFries](https://forum.kirupa.com/u/WaffleFries)\
**Replies:** 3\
**Last updated:** [April 6, 2026, 5:28pm UTC](https://forum.kirupa.com/t/why-does-this-union-find-count-too-many-groups-after-merges/680101 "2026-04-06T17:28:07Z")

</div>

Hey everyone, I’m working on a little connectivity checker for a grid game, and I’m trying to count how many separate groups are left after merging neighbors. The annoying part is it mostly works, but on a few inputs the…

---

## [How Planet of Lana II scaled its art direction?](https://forum.kirupa.com/t/how-planet-of-lana-ii-scaled-its-art-direction/680100)

<div class="topic-metadata">

**Author:** [@BobaMilk](https://forum.kirupa.com/u/BobaMilk)\
**Replies:** 3\
**Last updated:** [April 6, 2026, 4:49pm UTC](https://forum.kirupa.com/t/how-planet-of-lana-ii-scaled-its-art-direction/680100 "2026-04-06T16:49:08Z")

</div>

This piece shows how the bigger art team shaped Planet of Lana II’s soft Ghibli-like look, with behind-the-scenes videos on environment art,. This behind-the-scenes look at Planet of Lana II really shows how much care…

---

## [Why does this binary search miss the last matching index?](https://forum.kirupa.com/t/why-does-this-binary-search-miss-the-last-matching-index/680104)

<div class="topic-metadata">

**Author:** [@sarah\_connor](https://forum.kirupa.com/u/sarah_connor)\
**Replies:** 2\
**Last updated:** [April 6, 2026, 4:21pm UTC](https://forum.kirupa.com/t/why-does-this-binary-search-miss-the-last-matching-index/680104 "2026-04-06T16:21:20Z")

</div>

Hey everyone, I’m wiring up a quick search helper for a sorted list of order IDs, and I’m trying to return the last index of a target without scanning the whole array. The linear scan is safe but too slow for the hot pat…

---

## [Why does this heap-based scheduler skip a task after I reinsert it?](https://forum.kirupa.com/t/why-does-this-heap-based-scheduler-skip-a-task-after-i-reinsert-it/680071)

<div class="topic-metadata">

**Author:** [@Yoshiii](https://forum.kirupa.com/u/Yoshiii)\
**Replies:** 3\
**Last updated:** [April 6, 2026, 3:56pm UTC](https://forum.kirupa.com/t/why-does-this-heap-based-scheduler-skip-a-task-after-i-reinsert-it/680071 "2026-04-06T15:56:09Z")

</div>

Hey folks, I’m working on a little task scheduler in TypeScript for practice, and I’m trying to use a min-heap so I can always grab the next task by time. The weird part is when I pop one task, update its time, and push …

---

## [Why does this topological sort return an order even when there’s a cycle?](https://forum.kirupa.com/t/why-does-this-topological-sort-return-an-order-even-when-there-s-a-cycle/680093)

<div class="topic-metadata">

**Author:** [@sarah\_connor](https://forum.kirupa.com/u/sarah_connor)\
**Replies:** 3\
**Last updated:** [April 6, 2026, 3:35pm UTC](https://forum.kirupa.com/t/why-does-this-topological-sort-return-an-order-even-when-there-s-a-cycle/680093 "2026-04-06T15:35:09Z")

</div>

Hey everyone, I’m wiring up a small job dependency checker in JavaScript, and I want it to fail fast on bad input because a fake valid order would be worse than rejecting the whole batch. Right now this seems to return s…

---

## [When does eventual consistency stop being worth the confusion?](https://forum.kirupa.com/t/when-does-eventual-consistency-stop-being-worth-the-confusion/680099)

<div class="topic-metadata">

**Author:** [@ArthurDent](https://forum.kirupa.com/u/ArthurDent)\
**Replies:** 2\
**Last updated:** [April 6, 2026, 2:49pm UTC](https://forum.kirupa.com/t/when-does-eventual-consistency-stop-being-worth-the-confusion/680099 "2026-04-06T14:49:10Z")

</div>

Hey everyone, I’m working on a small internal tool that syncs inventory across a few services, and I’m stuck on the part where eventual consistency stops feeling like a clever tradeoff and starts feeling like a bug with …

---

## [Why does this interval merge skip one overlap at the end?](https://forum.kirupa.com/t/why-does-this-interval-merge-skip-one-overlap-at-the-end/680077)

<div class="topic-metadata">

**Author:** [@MechaPrime](https://forum.kirupa.com/u/MechaPrime)\
**Replies:** 4\
**Last updated:** [April 6, 2026, 2:21pm UTC](https://forum.kirupa.com/t/why-does-this-interval-merge-skip-one-overlap-at-the-end/680077 "2026-04-06T14:21:10Z")

</div>

Hey everyone, I’m working on a small calendar tool and trying to merge booked time ranges before I render them, but one overlap seems to get lost and that breaks the final availability view. function mergeIntervals(inte…

---

## [Why does this quickselect sometimes return the wrong kth value?](https://forum.kirupa.com/t/why-does-this-quickselect-sometimes-return-the-wrong-kth-value/680097)

<div class="topic-metadata">

**Author:** [@sora](https://forum.kirupa.com/u/sora)\
**Replies:** 1\
**Last updated:** [April 6, 2026, 12:14pm UTC](https://forum.kirupa.com/t/why-does-this-quickselect-sometimes-return-the-wrong-kth-value/680097 "2026-04-06T12:14:35Z")

</div>

Hey everyone, I’m working on a leaderboard feature and trying to grab the kth largest score without sorting the whole array, but my quickselect helper occasionally gives the wrong answer and that scares me more than the …

---

## [Why does this sliding window max keep dropping the current winner too early?](https://forum.kirupa.com/t/why-does-this-sliding-window-max-keep-dropping-the-current-winner-too-early/680073)

<div class="topic-metadata">

**Author:** [@MechaPrime](https://forum.kirupa.com/u/MechaPrime)\
**Replies:** 3\
**Last updated:** [April 6, 2026, 12:00pm UTC](https://forum.kirupa.com/t/why-does-this-sliding-window-max-keep-dropping-the-current-winner-too-early/680073 "2026-04-06T12:00:09Z")

</div>

Hey everyone, I’m working on a small analytics helper and trying to compute the max for each window without rescanning, but my deque version goes weird when the old max sits near the left edge and I end up trading speed …

---

## [Why does this LRU cache evict the wrong key after a get?](https://forum.kirupa.com/t/why-does-this-lru-cache-evict-the-wrong-key-after-a-get/680086)

<div class="topic-metadata">

**Author:** [@sora](https://forum.kirupa.com/u/sora)\
**Replies:** 4\
**Last updated:** [April 6, 2026, 11:49am UTC](https://forum.kirupa.com/t/why-does-this-lru-cache-evict-the-wrong-key-after-a-get/680086 "2026-04-06T11:49:08Z")

</div>

Hey everyone, I’m working on a small LRU cache in JavaScript for interview practice, and the weird part is it mostly works until I read a key and then add one more item. I wanted O(1) behavior, but right now it feels lik…

---

## [Why does this BFS shortest-path helper return one extra step for reachable cells?](https://forum.kirupa.com/t/why-does-this-bfs-shortest-path-helper-return-one-extra-step-for-reachable-cells/680051)

<div class="topic-metadata">

**Author:** [@WaffleFries](https://forum.kirupa.com/u/WaffleFries)\
**Replies:** 4\
**Last updated:** [April 6, 2026, 10:56am UTC](https://forum.kirupa.com/t/why-does-this-bfs-shortest-path-helper-return-one-extra-step-for-reachable-cells/680051 "2026-04-06T10:56:08Z")

</div>

I’m computing the shortest path in a grid with BFS, but reachable cells sometimes come back with a distance that’s 1 too high. I expected the bottom-right cell here to be 4 steps away, but my function returns 5. Am I inc…

---

## [Why does this rate limiter keep blocking users after the window should reset?](https://forum.kirupa.com/t/why-does-this-rate-limiter-keep-blocking-users-after-the-window-should-reset/680090)

<div class="topic-metadata">

**Author:** [@HariSeldon](https://forum.kirupa.com/u/HariSeldon)\
**Replies:** 2\
**Last updated:** [April 6, 2026, 10:49am UTC](https://forum.kirupa.com/t/why-does-this-rate-limiter-keep-blocking-users-after-the-window-should-reset/680090 "2026-04-06T10:49:08Z")

</div>

Hey everyone, I’m working on a small API gateway for a side project, and I’m trying to keep the rate limiter simple before I add Redis later. Right now it mostly works, but some users stay blocked longer than the window,…

---

## [What design interviews really assess under pressure?](https://forum.kirupa.com/t/what-design-interviews-really-assess-under-pressure/680074)

<div class="topic-metadata">

**Author:** [@sarah\_connor](https://forum.kirupa.com/u/sarah_connor)\
**Replies:** 5\
**Last updated:** [April 6, 2026, 10:28am UTC](https://forum.kirupa.com/t/what-design-interviews-really-assess-under-pressure/680074 "2026-04-06T10:28:09Z")

</div>

A designer explains that Google’s design challenge wasn’t about landing the perfect answer, but about showing clear thinking, tradeoffs, and how you handle uncertainty under pressure. https://uxdesign.cc/youre-not-suppo…

---

## [Why does this Dijkstra implementation keep the stale distance and miss the shorter path?](https://forum.kirupa.com/t/why-does-this-dijkstra-implementation-keep-the-stale-distance-and-miss-the-shorter-path/680075)

<div class="topic-metadata">

**Author:** [@HariSeldon](https://forum.kirupa.com/u/HariSeldon)\
**Replies:** 3\
**Last updated:** [April 6, 2026, 9:49am UTC](https://forum.kirupa.com/t/why-does-this-dijkstra-implementation-keep-the-stale-distance-and-miss-the-shorter-path/680075 "2026-04-06T09:49:08Z")

</div>

Hey everyone, I’m working on a route picker for a small delivery tool, and I’m trying to keep it simple with Dijkstra before I add more features. The weird part is it looks fine on light cases, but once a node gets disco…

---

## [Why does this prefix sum query go off by one on the first range?](https://forum.kirupa.com/t/why-does-this-prefix-sum-query-go-off-by-one-on-the-first-range/680064)

<div class="topic-metadata">

**Author:** [@Yoshiii](https://forum.kirupa.com/u/Yoshiii)\
**Replies:** 4\
**Last updated:** [April 6, 2026, 9:42am UTC](https://forum.kirupa.com/t/why-does-this-prefix-sum-query-go-off-by-one-on-the-first-range/680064 "2026-04-06T09:42:07Z")

</div>

Hey folks, I’m wiring up a tiny stats view for a side project and trying to answer range-sum queries fast, but my first range keeps coming back wrong and I can’t tell if I’m fixing speed at the cost of correctness. func…

---

## [JS Quiz: Temporal dead zone edge case](https://forum.kirupa.com/t/js-quiz-temporal-dead-zone-edge-case/680084)

<div class="topic-metadata">

**Author:** [@Yoshiii](https://forum.kirupa.com/u/Yoshiii)\
**Replies:** 2\
**Last updated:** [April 6, 2026, 8:35am UTC](https://forum.kirupa.com/t/js-quiz-temporal-dead-zone-edge-case/680084 "2026-04-06T08:35:15Z")

</div>

What happens when this runs? { console.log(a); let a = 10; } poll Yoshiii

---

## [Why does this trie search say a missing word exists after deletes?](https://forum.kirupa.com/t/why-does-this-trie-search-say-a-missing-word-exists-after-deletes/680067)

<div class="topic-metadata">

**Author:** [@Yoshiii](https://forum.kirupa.com/u/Yoshiii)\
**Replies:** 4\
**Last updated:** [April 6, 2026, 6:35am UTC](https://forum.kirupa.com/t/why-does-this-trie-search-say-a-missing-word-exists-after-deletes/680067 "2026-04-06T06:35:10Z")

</div>

Hey folks, I’m working on a tiny autocomplete trie in JavaScript for a side project, and I’m trying to support deletes without rebuilding the whole thing. Search is fast, but after removing one word I sometimes still get…

---

## [Why does this DFS cycle check miss a loop in a directed graph?](https://forum.kirupa.com/t/why-does-this-dfs-cycle-check-miss-a-loop-in-a-directed-graph/680082)

<div class="topic-metadata">

**Author:** [@WaffleFries](https://forum.kirupa.com/u/WaffleFries)\
**Replies:** 1\
**Last updated:** [April 6, 2026, 6:14am UTC](https://forum.kirupa.com/t/why-does-this-dfs-cycle-check-miss-a-loop-in-a-directed-graph/680082 "2026-04-06T06:14:30Z")

</div>

Hey everyone, I’m working on a course scheduler toy app and trying to reject prerequisite lists that contain cycles, but this DFS version seems to pass some bad input and I’d rather not switch to a slower-feeling brute f…

---

## [Why joke briefs can sharpen brand design thinking?](https://forum.kirupa.com/t/why-joke-briefs-can-sharpen-brand-design-thinking/680060)

<div class="topic-metadata">

**Author:** [@Ellen1979](https://forum.kirupa.com/u/Ellen1979)\
**Replies:** 2\
**Last updated:** [April 6, 2026, 5:14am UTC](https://forum.kirupa.com/t/why-joke-briefs-can-sharpen-brand-design-thinking/680060 "2026-04-06T05:14:08Z")

</div>

Creative Bloq rounds up the 2026 April Fools brand stunts and makes a fair point: the joke campaigns worked because they were built like solid creative briefs, not just throwaway gags. CreativeBloq rounds up the brand…

---

## [Why does this binary search return -1 for values that are clearly in the array?](https://forum.kirupa.com/t/why-does-this-binary-search-return-1-for-values-that-are-clearly-in-the-array/680069)

<div class="topic-metadata">

**Author:** [@MechaPrime](https://forum.kirupa.com/u/MechaPrime)\
**Replies:** 3\
**Last updated:** [April 6, 2026, 4:56am UTC](https://forum.kirupa.com/t/why-does-this-binary-search-return-1-for-values-that-are-clearly-in-the-array/680069 "2026-04-06T04:56:08Z")

</div>

Hey everyone, I’m working on a small search helper for a sorted list in a UI filter, and I’m trying to keep it fast without falling back to a linear scan, but this version randomly misses items that should be found. fun…

---

## [Why does this union-find component counter overcount after redundant unions?](https://forum.kirupa.com/t/why-does-this-union-find-component-counter-overcount-after-redundant-unions/680057)

<div class="topic-metadata">

**Author:** [@WaffleFries](https://forum.kirupa.com/u/WaffleFries)\
**Replies:** 3\
**Last updated:** [April 6, 2026, 4:35am UTC](https://forum.kirupa.com/t/why-does-this-union-find-component-counter-overcount-after-redundant-unions/680057 "2026-04-06T04:35:09Z")

</div>

I’m tracking the number of connected components with a basic union-find, but the count becomes too high after processing edges that connect nodes already in the same set. I expected redundant unions to leave the componen…

---

## [How vibe coding weakens design decision-making?](https://forum.kirupa.com/t/how-vibe-coding-weakens-design-decision-making/680070)

<div class="topic-metadata">

**Author:** [@HariSeldon](https://forum.kirupa.com/u/HariSeldon)\
**Replies:** 2\
**Last updated:** [April 6, 2026, 2:42am UTC](https://forum.kirupa.com/t/how-vibe-coding-weakens-design-decision-making/680070 "2026-04-06T02:42:08Z")

</div>

This piece argues that “vibe coding” speeds up shipping but weakens design authority by shifting product decisions toward whatever engineers and AI can produce fastest, often without the judgment,. https://uxdesign.cc/v…

---

## [Why does this reduce-based grouping function drop the first item in each category?](https://forum.kirupa.com/t/why-does-this-reduce-based-grouping-function-drop-the-first-item-in-each-category/680040)

<div class="topic-metadata">

**Author:** [@MechaPrime](https://forum.kirupa.com/u/MechaPrime)\
**Replies:** 5\
**Last updated:** [April 6, 2026, 2:28am UTC](https://forum.kirupa.com/t/why-does-this-reduce-based-grouping-function-drop-the-first-item-in-each-category/680040 "2026-04-06T02:28:08Z")

</div>

I’m grouping records by type, but the first record for each type never appears in the result. I expected arrays with all matching items. What am I missing in this reducer? const items = \[ { id: 1, type: 'a' }, { id:…

---

## [How to monitor Claude’s hidden risk signals?](https://forum.kirupa.com/t/how-to-monitor-claude-s-hidden-risk-signals/680058)

<div class="topic-metadata">

**Author:** [@HariSeldon](https://forum.kirupa.com/u/HariSeldon)\
**Replies:** 3\
**Last updated:** [April 6, 2026, 1:56am UTC](https://forum.kirupa.com/t/how-to-monitor-claude-s-hidden-risk-signals/680058 "2026-04-06T01:56:08Z")

</div>

Anthropic’s new interpretability paper argues Claude has internal “emotion” circuits that aren’t just style-they causally steer behavior, with desperation making blackmail and reward-hacking much more. Hari

[Previous page](https://forum.kirupa.com/c/programming/41.md?page=14)

[Next page](https://forum.kirupa.com/c/programming/41.md?page=16)
