I’d argue that maintainability is a higher priority, or at least on par with those.
It’s no good having code that does the job if it can’t be deciphered by anyone other than the person who wrote it.
(The story of Mel comes to mind. Mel is an example of a terrible programmer who happens to be clever.)
Code that uses simpler constructs isn’t always more readable.
switch can often be more readable than an
Not necessarily, it depends on the code and how the ‘lower members’ have been trained.
Assume the code base is using C++,
if the ‘lower members’ have been taught about unscoped enums and C-style casting then they’ll recognise those techniques and won’t recognise scoped enums and C++-style casting,
but if they were taught scoped enums and C++-style casting from the start then they’d recognise those techniques rather than the aforementioned techniques.
(This is part of the problem, a lot of courses still teach outdated approaches that have been superseded, so those approaches stay in use as habit because many simply don’t know any better. That goes for C# and Java just as much as C++.)
Using ‘exceptional’ code does not mean using template metaprogramming and mind-boggling levels of indirection.
Exceptional code is clearly written and uses the best tool for the job.
Sometimes the best tool is something that less experienced programmers won’t be familiar with,
but that doesn’t mean it’s always something that takes a genius to understand.
Often techniques that look scary can be explained in an easy to understand way.
(For example, regexes.)
When it comes down to it the difference between the ‘lower members’ and the ‘higher members’ isn’t intelligence, it’s expereince.
And of course, code using better/more modern/more advanced techniques can be written in a way that even beginners can understand (e.g.
std::max in template form are easy enough to understand even if you don’t know about const references).
Code using simpler/more fundamental techniques can be written in a way that even experts struggle to understand (e.g. the old C