Programming Like This for 20 Years

Programming Like This for 20 Years
# Programming Principles That Can Last 20 Years  
*2025-10-17 08:45 — Beijing*

---

## Core Philosophy

**The overarching idea:** Tools are secondary — **clear problem definition** is the foundation.

---

## Human-Centric Code

1. **Tools come second, problems are king**  
   - Define the problem *first*.  
   - Choose technology to fit the problem, *not* vice versa.

2. **Code is written for humans to read**  
   - Use clear names and stable structures.  
   - Account for both newcomers and your *future self*.

3. **Collaboration beats heroics**  
   - Communicate openly.  
   - Share reasoning behind decisions.  
   - Lead by example: turn followers into collaborators.

---

## Architecture & Testing

4. **Divide and couple loosely**  
   - Apply both **unit tests** and **integration tests**.  
   - Cover normal cases, boundaries, and extremes.

5. **Don’t tie your identity to code**  
   - Make code transferable and maintainable.  
   - Step back to grow beyond current projects.

6. **Security is layered risk control**  
   - Context matters:  
     - Banks: **Security first**  
     - Games: **Performance first**

7. **Code has a lifespan**  
   - Classify as **core / essential / value-added**.  
   - Learn to archive and move on.

---

## Technical & Cultural Wisdom

8. **Tech debt is like fast food**  
   - Occasional debt is fine.  
   - Chronic accumulation is harmful.

9. **Order of trade-offs** *(context-dependent)*  
   - Security → Usability → Maintainability → Simplicity → Brevity → Performance.

10. **Audit before copy-paste**  
    - Bugs hide behind complexity.

11. **Document exceptions thoroughly**  
    - Explain **why**, **how to detect**, and **how to recover**.  
    - Validate early, fail fast when necessary.

12. **Avoid hype-driven development**  
    - Stay curious.  
    - Embrace multilingual/multicultural inputs.  
    - Keep sharing knowledge.

13. **Don’t design for imaginary problems**  
    - Extend architecture *only* after real needs appear.

14. **Community makes development fun**  
    - Listen, inspire, reuse, and give back.  
    - *Shout-out: Tencent Cloud Developers Community!*

---

## AI-Specific Practices

17. **AI is an accelerator**  
    - Wrong direction = faster crash.  
    - Set requirements, verify, evaluate before adoption.

18. **Evaluation-driven development (E2E/Eval)**  
    - Align offline/online metrics.  
    - Maintain regression sets for models and retrieval chains.

19. **Design controllable uncertainty**  
    - Adjust `temperature`, `retry`, `timeout`, `cache`, tool-call whitelists.  
    - Maintain randomness inside boundaries and certainty outside interfaces.

20. **Prefer deterministic methods**  
    - If a subtask can be solved deterministically, skip "intelligent" guesses.

21. **RAG beats rote memory**  
    - Prioritize retrievability and updatability of knowledge.  
    - Let models cite and annotate.

22. **Cost & latency are part of functionality**  
    - Treat tokens, delays, concurrency as **non-functional requirements**.

23. **Model is a dependency**  
    - Manage versioning, rollout, rollback.  
    - Maintain both prompt and system prompt.

24. **Make AI output auditable**  
    - Require **evidence + steps**.  
    - Apply programmatic checks where feasible.

25. **If a prompt solves the problem, skip creating a new review meeting.**

26. **Keeping a job is hard; self-improvement has higher ROI**  
    - Invest in defensive programming for your career.

---

## Reflection

**Question:**  
If you code by these principles, **can you sustain them for 20 years**?  
Drop your thoughts below — *one comment* will be **randomly selected** for a community gift.

![image](https://blog.aitoearn.ai/content/images/2025/10/img_001-264.jpg)

---

## For AI-Creative Developers

If you aim to go beyond single projects and monetize creativity across multiple platforms, consider **[AiToEarn官网](https://aitoearn.ai/)**:  
- **Open-source global AI content monetization ecosystem**.  
- Integrates AI content generation with cross-platform publishing to: Douyin, Kwai, WeChat, Bilibili, Rednote, Facebook, Instagram, LinkedIn, Threads, YouTube, Pinterest, and X (Twitter).  
- Built-in analytics and AI model ranking.  
- Scale efficiently without losing creative control.

[Open in WeChat](https://wechat2rss.bestblogs.dev/link-proxy/?k=0611d3b8&r=1&u=https%3A%2F%2Fmp.weixin.qq.com%2Fs%3F__biz%3DMzI2NDU4OTExOQ%3D%3D%26mid%3D2247692472%26idx%3D1%26sn%3Dcbf5b36233420bc938b8cb03e3d27dfc)

Read more

Drink Some VC | a16z on the “Data Moat”: The Breakthrough Lies in High-Quality Data That Remains Fragmented, Sensitive, or Hard to Access, with Data Sovereignty and Trust Becoming More Crucial

Drink Some VC | a16z on the “Data Moat”: The Breakthrough Lies in High-Quality Data That Remains Fragmented, Sensitive, or Hard to Access, with Data Sovereignty and Trust Becoming More Crucial

Z Potentials — 2025-11-03 11:58 Beijing > “High-quality data often resides for long periods in fragmented, highly sensitive, or hard-to-access domains. In these areas, data sovereignty and trust often outweigh sheer model compute power or general capabilities.” Image source: unsplash --- 📌 Z Highlights * When infrastructure providers also become competitors, startups

By Honghao Wang