Search code examples
theory

Is there really a "Best" way of solving a problem?


I have been looking at a lot of these questions asking for the "best" way to do this or the "best" way to do that.

  • Does one person's best way make it every person's best way?
  • Can there really be a "best" way to do a particular algorithm or to solve a problem?

  • What are the dangers of looking for a best way over just getting the problem solved in any way?


Solution

  • Jeff - this is something that my coworkers and I go back and fourth on. They continually are looking at the best way in terms of technology implementation and best practice, while as a business analyst I focus more on the delivery and getting the problems at hand resolved.

    This is certainly a question of value proposition and I think that it comes down to maintainability and performance. If the change being made or the code is not maintainable or easily changed, then it becomes an issue and should be re-evaluated for best practices. If the code in question is sluggish and performance is a concern, then it probably should be modified.

    While there are more than 10 ways to skin a cat or code an algorithm, there may not necessarily be a best, but there is almost always a better and worse. Check out the topics of code smells, may be a good place to start.