HACKER Q&A
📣 airbreather

Do you have to be able to write great code to recognize good code


I see on Twitter various comments about the print your code out thing, and some are saying Elon can't code, so what would the point be for him to look at it etc etc.

Internet evidence seems to suggest Elon can write some code, maybe not great code, but not nothing.

My question is, is it possible to recognize good or even great code, if you can't write great code yourself?

Edit : I can't even spell, I got Elon's name wrong second time, I'll blame the phone keyboard...


  👤 necovek Accepted Answer ✓
Can you recognize a good construction worker if you are only an amateur? Can you say someone is beautiful even if you are not? Can you say someone is a good runner even if you are not?

This is a common complaint against someone's judgement, but yes, I am pretty convinced you can evaluate qualities even though you might not posess them yourself.

Sure, experience helps increase the quality and finesse of your judgement (eg. non-coder can't evaluate some things even if they can notice if the software is fast and non-buggy and pretty and...).


👤 Zigurd
Depends: Is the code readable and understandable? Some familiarity with the platform, toolchain, and language is enough.

Is this a good use of DI, annotations. etc, you need enough direct experience for an informed opinion.

Lastly, a steaming pile is easier to identify than brilliant code, which might look odd at first.


👤 aristofun
You definitely don’t. Otherwise learning by example would be impossible, which is mot the case.

Sometimes good code design has some beauty to it. You feel it even if can’t explain.

But more often you see the evolution of a codebase, you watch the devX etc. to realize this is a truly high quality design.


👤 yuppie_scum
I can’t write “great” code but I can probably recognize bad code

👤 eimrine
Depends on definition of great code.

Is it fast and memory-efficient? You can recognize such code even if you can not read code. Is it valuable code like Bitcoin? Same