Snippet · Writing & changing code
Fix the names
Cheapest readability win there is.
Here is my code: <paste> Don't change any logic. Just tell me which names are wrong, and what they should be. For each one, one line on why. Look for: names that lie about what the thing holds, names that need a comment to be understood, single letters outside short loops, and functions whose name says less than they do.
If a function needs a comment to explain what it returns, the name is doing the wrong job. Renaming is the safest change you can make.