Code Smell 06 — Too Clever Programmer

Code difficult to read. Tricky with names without semantic. Sometimes using language’s accidental complexity.

Maximiliano Contieri
Dev Genius

--

Photo by NeONBRAND on Unsplash

Problems

  • Readability
  • Maintainability
  • Code Quality
  • Premature Optimization

Solutions

Examples

  • Optimized loops

Exceptions

  • Code that must be optimized for low level operations.

Sample Code

Wrong

Right

Detection

Automatic detection is possible in some languages related to complexity, bad names, post increment variables.

Also Known as

  • Obfuscator

Tags

  • Declarative

Relations

Programming can be fun, so can cryptography; however they should not be combined.

Kreitzberg & Shneiderman.

--

--

I’m a senior software engineer specialized in declarative designs. S.O.L.I.D. and agile methodologies fan. Maximilianocontieri.com