Ask HN: What trick of the trade took you too long to learn?

Long-term effectiveness over short-term grind

  • “Do less” and choose work carefully: manual methods and limited automation can force better prioritization than chasing maximal efficiency.
  • Optimize on the scale of months/years, not days: 12‑hour days work briefly, then backfire; sleep, nutrition, and happiness are compounding levers.
  • Think of careers as marathons, not sprints; small, sustainable effort (e.g. 15 extra minutes a day into a flex-time bank) beats aggressive pushes.

Testing, design, and code pragmatism

  • Strong support for tests as specifications, especially tests-first or “outside-in” (API‑level) tests that encode intended behavior, not implementation.
  • Several note retrofitting good tests is extremely hard; others push back that “test-first” isn’t universally embraced or easy in domains like games.
  • Preference for testing only public APIs and avoiding tests tied to internals.
  • Repeated theme: duplication isn’t always bad; premature abstractions and over-DRY code often produce brittle, hard-to-understand systems.
  • Macros in C/C++ are seen as powerful but dangerous; many eventually removed most of them in favor of enums, inlining, and clearer architecture.
  • Data structures and domain modeling often matter more than clever algorithms.

Tools and low-level tricks

  • Terminal multiplexers (screen, tmux) are life-changing for remote/CLI work.
  • git bisect, interactive rebase, and git reflog are highlighted as underused but powerful for tracking regressions and “fearless” history editing.
  • Shell tricks: Ctrl‑R history search, word-recall, awk '{print $1}', cut, and awareness of rm/cp/mv dangers (rm -i, backups and restore tests).
  • Screenshot tooling and quick sharing (including Airdrop) save huge friction.

Money, investing, and housing

  • Strong consensus: start investing early in low-fee index funds; basic tax-advantaged accounts (401k/IRA/HSA/529) and understanding taxes often matter more than stock-picking.
  • HSAs discussed in depth: “triple tax” benefits, but with caveats (medical-receipt tracking, post‑65 taxation on non-medical use).
  • Large, contentious thread on renting vs buying:
    • One side: home ownership is a poor or overrated investment once you fully cost interest, fees, maintenance, and opportunity cost; renting + investing often wins, especially in high-cost areas.
    • Other side: ownership’s tax advantages, inflation shielding, rent volatility, and long-term stability (especially with kids) make it financially and psychologically compelling.
    • Multiple links to rent-vs-buy calculators; emphasis that outcomes are highly location‑ and timing‑dependent.

Soft skills and work culture

  • Technical skill caps out; persuasion, communication, and being liked/friendly often determine advancement.
  • Some argue “playing politics” is central to corporate survival; others strongly reject this and advise leaving toxic environments rather than adapting.
  • Networking reframed as “business friendships” and seen as disproportionately effective.

Habits, health, and life strategy

  • Habits beat motivation: small daily actions (exercise, reading, journaling) compound; thinking “what if I do this 1,000 days in a row?” is a useful lens.
  • Many emphasize strength training, breaking up sedentary time, and realizing “you have a body” before something breaks.
  • Life won’t follow the plan: expect mess, accept broken streaks, and restart rather than chase perfection.
  • Recurrent advice: measure things (personally and professionally) and use Monte Carlo simulations / probability thinking to reason under uncertainty.