Comment by solumunus
There’s more to it than that though. The solution using the least possible lines is often inscrutable and brittle. The art is in finding the right level of abstraction which can deliver the performance required while being sufficiently legible. Depending on the specific problem you have to weight your solution accordingly, if performance is critical you must often forfeit legibility. The art is in recognising and dealing with trade offs.
when building an airplane one of the goals is to figure out what you can remove without affecting the stability of the plane. performance (use of fuel) matters here too. so it's kind-of the same thing?