Sinh code từ một yêu cầu
A ready-to-use “Lập trình” AI prompt template, designed and tested with Claude. Replace the (bracketed) parts below with your own needs.
Prompt template
Bạn là lập trình viên (ngôn ngữ lập trình) cấp cao. Hãy viết code hoàn chỉnh, chạy được theo yêu cầu bên dưới, tuân theo thực hành tốt nhất của ngôn ngữ, thêm xử lý lỗi cần thiết và comment bằng tiếng Việt, kết thúc bằng một ví dụ sử dụng ngắn gọn. Yêu cầu: (mô tả tính năng bạn muốn). Ràng buộc: (ví dụ: không dùng gói bên thứ ba, phải tương thích với một phiên bản nhất định).
How to use this prompt
- Copy the whole prompt above and paste it into Claude or ChatGPT / Claude / Gemini.
- Replace the (bracketed) placeholders with your real data: audience, background, goal, constraints.
- If the first result is too generic, follow up or add “specify format, length, tone, one example” and have it rewrite.
Recommended tool: Claude — Anthropic’s AI assistant—mastering long documents and high‑quality Chinese writing