.net - C#, Writing longer method or shorter method? -
I get two contradictory views on this. Some sources say that at least methods should be done to reduce method calls, but some other sources are good for optimizing the jet while writing less.
Then, which side is correct
In most cases it is impossible to be smaller. You do not have to worry about it unless you can clearly identify a problem under that road, so that the problem is reviewed. (Maintaining, and modifying methods should do the same thing, only one thing and sub-things should be given to other routines. This means that your methods should be as small as they possibly may be, but No small. Trying to outsource compiler or runtime, you will see a lot of performance gains by getting the code that is less than error code and errors.
Say what methods should be long means false , on many levels.
Comments
Post a Comment