Tag

programming best practices

0 views collected around this technical thread.

php中文网 Courses
php中文网 Courses
Mar 5, 2025 · Fundamentals

What Is Early Return and Why Use It?

Early return is a programming technique that lets functions exit as soon as an invalid condition is found, reducing nested if‑statements, improving readability, maintainability, and performance, as illustrated by comparing a nested‑condition order‑processing function with an early‑return version.

Code readabilitySoftware Maintenanceearly return
0 likes · 4 min read
What Is Early Return and Why Use It?
Tencent Cloud Developer
Tencent Cloud Developer
Jul 17, 2023 · Fundamentals

9 Common Code Quality Issues and Solutions

The article outlines nine frequent code‑quality problems—such as inconsistent naming, overly long functions, missing or outdated comments, poor error handling, lack of reuse or modularity, hard‑coded values, insufficient testing, misguided performance tweaks, security oversights, and weak version‑control practices—and offers practical solutions to address each.

Best PracticesProgramming Tipscode quality
0 likes · 15 min read
9 Common Code Quality Issues and Solutions
Tencent Cloud Developer
Tencent Cloud Developer
Sep 12, 2018 · Fundamentals

10 Tips on How to Be a Great Programmer

To become a great programmer, ask clear, well‑prepared questions, learn to solve problems independently, never compromise on quality, write deterministic code, embrace unexpected failures, avoid idolizing tools, practice daily, specialize while staying curious about other domains, and relentlessly strive for simple, maintainable solutions.

code qualitydeterministic programmingprofessional growth
0 likes · 16 min read
10 Tips on How to Be a Great Programmer
Architecture Digest
Architecture Digest
Jul 26, 2017 · Fundamentals

11 Tips for Writing Clear and Readable Code

This article presents eleven practical tips for writing clear, readable code, covering short methods, single-purpose variables, descriptive naming, proximity of declarations, avoiding magic numbers, respecting language idioms, following conventions, steering clear of premature optimization, refactoring after testing, and using patterns wisely.

Code readabilityclean codeprogramming best practices
0 likes · 9 min read
11 Tips for Writing Clear and Readable Code
Baidu Tech Salon
Baidu Tech Salon
Aug 5, 2014 · Backend Development

A Tale of Bug Fixing: Thinking Beyond the Immediate Solution

After a rushed fix for a division‑by‑zero bug caused incorrect results, the team learns to validate data at its source, adopt proper validation frameworks, and step back to understand underlying requirements, emphasizing that thoughtful design outweighs quick code patches.

Backend DevelopmentPHPbug-fixing
0 likes · 6 min read
A Tale of Bug Fixing: Thinking Beyond the Immediate Solution