Programmers Stack Exchange is a question and answer site for professional programmers interested in conceptual questions about software development. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I've been working hard on trying to develop a general solution to my problem, but I cannot seem to formulate a proper algorithm for it, at least one that doesn't take a ton of inaccurate grunt work building a lookup table.

I have a solution already for the specific requirement, but it requires the software's configuration to be changed every time the software is loaded with a different geographic area's datasets.

So is it better to be finished and move on for now, or to keep attempting to solve the general problem knowing that the specific problems will keep popping up?

share|improve this question
How often is the software going to need to be loaded with different datasets? How involved is the configuration change? Is this a commercial product? If so, have you asked the product owner for some input on whether the limitation of your current algorithm is acceptable, how much better a general purpose approach would be, and whether it makes sense to continue investing time to get to that point? – Justin Cave Jul 2 '12 at 22:23
@JustinCave The program's datasets will be changed per potential customer so hopefully frequently. The required configuration change is minor but does require a web administrator with GIS experience. The product is not yet commercial but is aimed to be later. – Peter Smith Jul 2 '12 at 22:53
How much other setup is required at each customer? If the goal is that each customer can get set up on their own without needing to call the company for assistance, it's a lot more likely that a general algorithm is going to be needed if only because customers never read the installation guide. If your business model is that the software comes with professional services that handle the installation & initial configuration, adding 5 minutes of work for them at each customer site is a lot less concerning. – Justin Cave Jul 2 '12 at 22:56

I've been in this situation before, and it's really just a special case of YAGNI (you ain't gonna need it).

Implement the solution based upon the current requirements (which you say you've solved). When the next round of requirements come in that require a modification, handle it then. You'll either A) discover the general solution that you couldn't find now, B) come up with an elegant / tolerable way of extending for each new case, or C) find that you don't need to make those modifications after all.

From what you've described, it sounds like the modifications can be easily scripted if nothing else. Sometimes, a second app is the solution to the intractable problems in the first app.

Code to meet your contract, and accommodate expected future growth only inasmuch as is obviously necessary. Coding for every what-if (or the full expression of the problem set) isn't what's required at the moment. (caveat: that advice is intended for this particular issue and in other cases more future-proofing could be warranted.)

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.