Backtracking:Search With Undo When the Next Choice Depends on the Last
Choose, recurse, undo: search a decision tree with pruning when the next pick depends on the path — not a second knapsack table.
Read MoreBrowse the full archive. Use topics in the sidebar to explore by tag.
Choose, recurse, undo: search a decision tree with pruning when the next pick depends on the path — not a second knapsack table.
Read MoreReplace nested loops over Outdoor / Hiking / SKUs with a CatalogNode tree so a category and a single product both answer subtotal(), and OrderProcessor still charges one payable.
Read MorePut a PaymentGateway proxy in front of a slow SDK so OrderProcessor still calls charge, while lazy init, an auth check, and a last-result cache decide whether the real gateway runs.
Read MoreHands-on strace recipes — attach to a PID, follow children, filter syscalls, and read the wait that logs never mentioned.
Read MorePick a maximum subset of non-overlapping intervals by earliest finish time — greedy that throws ranges away, not merge-intervals.
Read MoreTurn charge, refund, and capture into Java objects you can queue, retry, undo, or audit — without wrapping a one-shot process() in ceremony.
Read MoreHands-on tar and gzip recipes — create an archive, inspect it before extract, compress with gzip, and restore without clobbering the wrong tree.
Read MoreHide checkout’s discount, payment, fraud, and tax conversation behind one CheckoutFacade.place(Order) so controllers stop assembling the subsystem.
Read MoreTry JEP 532 in JDK 27: use primitive patterns with instanceof, switch directly on long, float, double, and boolean, and reject lossy conversions without hand-written casts.
Read MoreHands-on text-prep recipes — slice columns, sort keys, count uniques, and translate characters before you reach for awk or sed.
Read More