[quote=“tariqbroadnax,post:4,topic:58470”]
Sais who - you?
“Clear” is, that the main purpouse of the code should be the construction of a vector with x, y and z property. This is happening in line 5. The other lines are clutter, so there’s nothing more clear, but more unimportant code that distracts you from the main purpose.
But I agree with your other statement: It’s a matter of taste. But that’s why the creator of this thread asked: Because he searches for advantages and disadvantages of the two options.
In this case, I tend to say, that the logic is placed in a helper method “createVector” either way, so the code itself is rarely or even never used/placed somewhere outside of such a method…that means bloating the code up with local variables happens exactly once - which seems to be okay for me, because it might be easier readable for someone who has never touched the code at all.