Ask HN: How do you solve hard problems if you can't make incremental progress?
ravimohan.blogspot.com
ravimohan.blogspot.com
No facebook, television, hacker news, video games, twitter, dating, drinking.
I would not say this is a particularly healthy lifestyle in the long run. When possible incremental progress will make it easier to live a happy fulfilling life. But if you really need to solve something...
But yeah, "Avoid stress and distractions. Do not multitask. Take breaks to eat (healthy foods), exercise, and sleep. Feel free to discuss the problem with friends and colleagues but minimize emotional investment with other people."
I'll add:
Make progress, even if it's not progress. I teach english. If my students are stuck, I tell them to answer the question in their native language. Or just guess. Or say something that isn't even relevant. There are 3 reasons why I say this: 1) you look busy, so your boss will be happy, 2) you feel better and might subconsciously clear the block just by not stressing over it, and 3) you start filling in the jigsaw pieces around the block, which might make the solution easier to reach.
The closest thing to an exception I know of is listening to music. I will listen to music while working on hard problems, but then I tend to choose music I know well and I use it to block out more distracting sounds rather than pay much attention to it.
Someone once told me that there was a study showing that most music tends to decrease work effectiveness, but classic music actually increases it (I do not have a link). Sadly, I'm an uncultured boor and while classical music sounds pleasant it's not my favorite by a long shot. I compromised by including some techno remixes of classical compositions in my essay-writing playlist.
http://simplynoise.com - I prefer the brown noise, myself.
For me this wasn't a problem when configuring routers, but I found that if I listened to music, I could spend an hour programming a solution to a problem that could have been sidestepped entirely.
I read some articles about that, but don't have a reference handy. In any case, once I noticed the effects it has on me, I am being extra careful.
Also, leaving one task lie while you mull over it can be good.
But I think making yourself feel snowed-under is bad, as is needless context-switching.
And there's a difference between simply being able to work effectively and being able to solve a single difficult problem. For typical programming challenges that can be broken up into smaller chunks a bit of context-switching may not slow you down that much and you can be sure to give attention to important things like paying your rent and having dinner with your girlfriend.
Also, as a quick comment on your post above-- to the extent that "progress, even if it's not progress" isn't basically rephrasing my recommendations to study tools and similar problems, doing the 'work-on-context-instead' approach can be risky. If you spend too much time avoiding the big problem you may never solve it.
He deals specifically with mathematical problems, but the same ideas apply to computer science.
For an outline of the method see this Wikipedia article:
http://www.amazon.com/Solve-Computer-Prentice-Hall-Internati...
The example in the article is a good one: there's absolutely no need to attempt to design a Sudoku-solving-algorithm from scratch (except as an exercise), and it is pitiful to see Ron Jeffries flailing around aimlessly in TDD-land when a simple trip to Google would have done the trick.
The difficult part, the part that comes with experience, is recognizing which class of problems the specific problem you are grappling with resembles. In the case of Sudoku, it's an "exact cover problem", and once you realize this, all kinds of solutions present themselves.
In this way, the "incremental progress" is not made on attempting to solve the problem incrementally, but by incrementally sifting through probably solution-spaces for known algorithms.
Generations of Soviet engineers were educated on that methodology. Many western companies use it as well.
It seems a bit of an outlandish claim to make without a reference point, what's complex to you may be simple to others and vice versa. So a bit of extra data as to the kind of complex systems and problems you visualize would help.
Usually that 'clicks' at some point and I realize what I'd been missing all along. The less the person knows about computers/programming (my usual subject matter) the better it seems to work.
One person plays the rubber duck and sits there and says (at most) "uhuh, uhuh" while the programmer with the bug explains the problem. Nine times out of 10, the bugged programmer will do a facepalm and fix the bug immediately while explaining the problem.
You actually don't need a person at all for this, or a rubber duck... just the willingness to explain your bug aloud to yourself when you have one.
I know this is a very meta question but this is not the only case. I'll solve it eventually but I'd like to ask for common strategies.
Edit: Some of my strategies are: to absorb more information about similar stuff while I put solving it on back burner, to try to describe the problem clearly, to bounce the problem off other people.
-------------------------
Okay, here is the specific question: I have a map of categories of things (a few words) and descriptions what these categories mean (longer text). I also have another list of category names that sometimes uses different words or abbreviations, and I need to match the second list to the first one precisely.
I know all about tf-idf, vector space similarity between a document and a term, wordnet as a source of semantic relations between words, and it's ok to have a human map some of these. The problem is I don't know when a matching score is good enough and when I need to fall back to a human.
def abbr(short, full):
return re.match(''.join(c+'.*' for c in short), full)
Actually what I'm doing now seems to be working, so far I can't see any pattern in the things my algo can't match by itself.Also thanks to ramanujan, who deleted his comment for some reason, but besides pointing out orgmode which I want to check, his proposition reminded me that I'm trying to deal with my dataset incrementally while a batch mode might work better.
So maybe in some cases it just helps to read the literature a little bit...
For example at the Google Code Competition (forgot the proper name), I am not very good, but I learned some things from reading solutions of older competitions. I think there even is a book dedicated to solving that kind of problem. It would probably help a lot with writing a Sudoku solver, too.
Edit: not to take away from the Norvig solution, it is probably beautifully crafted. But come on - it IS the straightforward solution? Or what am I missing?
I remember reading up on it awhile ago, and it seems like the Wikipedia entry already had the dancing links algorithm by then.
I've been doing more things with mturk, elance, RAC, and so on lately. For a recent tradeshow we did I had someone on elance doing a short video production for me for $150. The money was a no-brainer and allowed to concentrate on other stuff. I also hired someone on elance (for $500) to write an xcode framework for me for an iPhone app idea. I could probably figure it out myself, but (I'm hoping) it will be easier and more efficient to get started in iPhone app programming by having someone more knowledgeable than I put together the basics so I can see how it's done. (Yes, I know there are a ton of xcode examples on line, I just wanted something specific that I could build off of).
Depending on the price/problem, outsourcing a solution might be an excellent use of time/resources, and may also teach you something new seeing how another person tackled the issue.
Because some people do not think about everything in monetary terms.
that doesn't mean he's not a smart guy, but it's wrong to infer, from comparing those articles, that he doesn't make mistakes.
it is often a very strange approach and cannot be replicated by humans, but i like the ideology.