of things.
1) Correctly planned schedule for development.
2) A Coding Standard that works.
3) Programmers that have been smart enough to write portable code, or have a good knowledge of the code available to them for re-use.
4) A good team.
on point 1, sales team, and develpment team have to work together to come up with a delivery schedule that the customer can live with, the development team has to be involved in the requirements discussions in some fashion, to be able to give reasonable estimate of development time.
on point 2, the simplest way to set a coding standard: use the international standard for the language ie: ansi c / C++. clearly define what is meant by well documented / commented code. the coding Requirement for the company should be detailed in the documentation / commenting area, in clear, plain english [ or whichever language is used in workplace ] no legalese.
on point 3, every function that they write can be coded where it will only ever work in the software they wrote it for, or it can be coded to be re-used in projects that it will help later on in their career. If a programmer is not familiar with the libraries of code that are available to them in the workplace, then they will often be slower developing new software, as they are constantly writing new code that already exists.
on point 4, the entire company has to be a team, from every department, if there is anyone who doesn't feel that the company is a team then they are not as productive as they can be. This includes Management. the Sales rep that got the contract for the product is a part of the development team, they are the interface between the developers and the customer, their job has not ended until the customer has received exactly what they ordered.