News > 4 common C programming mistakes - and 5 tips to avoid them

4 common C programming mistakes - and 5 tips to avoid them

Channel Asia | 19/10/2020 02:34 PM | Click to read full article

Few programming languages can match C for sheer speed and machine-level power. This statement was true 50 years ago, and it’s still true today. However, there’s a reason, programmers coined the term “footgun” to describe C’s kind of power. If you’re not careful, C can blow off your toes—or someone else’s.

Common C mistakes: Not freeing malloc-ed memory (or freeing it more than once) or reading or writing an array beyond its boundaries.

-