What could I do? What could I read? Who could I ask?

Earlier today I was listening to an audio book by Jim Rohn. He is a business author but he has one bit of advice that I find is extremely useful in software development. In the section on “Building Self-Enterprise” he has this to say:

“So what is the problem? State the problem. Write it down…. And I’ve got three questions to ask [yourself] in order to solve the problem.

“The first question you need to write down is this: What can I do? Because, you don’t want to go any further than that if you can solve it yourself. Then what you do is develop working papers and start jotting down [that] I could do number one, and I could do number two, and I could do number three. There are some alternatives. Then you start analysing them.

“Now if that doesn’t work then here is number two: What could I read? Maybe there is a book on my problem. Somebody spent a lifetime trying to figure out this problem. Maybe it is written out in concise language somewhere to give you the instant benefit of someone’s advice. You don’t need to reinvent the wheel. Do your homework and find the solution. And then you start to develop some working papers on what you are reading. Don’t miss the book that could help.

“So, don’t sell yourself short here. You can find some answers. Now, first try and find them yourself from your own experiences. Then second, if you can’t find them yourself then ask ‘what could I read?’ Go to the library. Go to the bookstore. Search your own library. Go back through your own journals to find the stuff that has been helpful and valuable and see if maybe you have made some notes that could be helpful in your situation.

“Now, if that doesn’t work then ask question number three. And question number three is: Who could I ask? Now, guess what you are prepared with when you ask somebody to help you. You’ve got your working papers to show them. You say I’ve tried my best to figure it out myself, and that finally left me short. Here are some of the books I’ve read. I’ve researched this material and I’m still short.  Now, could I possibly ask you? And could you possibly help me? You can’t believe how willing somebody will be to help you if first of all they’ve got the idea that you were willing to help yourself.

That is fantastic advice, even although he applies it to building a business, it also works for solving problems in software development. So many times I see in software development forums people ask questions that they obviously can’t be bothered to try to help themselves first. So many times I see people post their homework questions verbatim to the forum and just ask: How do I do this? Write some code for me. Give me the code for this.

NOTE: This was rescued from the Wayback Machine. The original date was Wednesday, 24th November, 2004.

Confucius Say….

Man who stand on hill with mouth open will wait long time for roast duck to drop in.”
— Confucius

If you want something you are going to have to put in some effort to get it, it will not arrive to you exactly as you want it. This is especially true in on-line forums. Many times I see questions from people that just want the answer to their homework. There is no intention to actually understand the problem, they just want something they can hand to their tutor the next morning. This is really frustrating because I spend some of my lunch hour or free time on these forums trying to help people. Most people are genuinely stuck and cannot make sense of the documentation (you will have noticed from other blog entries where I’ve written up a clarification of some documentation because it wasn’t written as I’d have liked) or they’ve been trying various things to get it to work and they’ve got their code in a “richt fankle”* and as a result they’ve lost the thread somewhat. Getting back to the analogy that confucius made, these people have actually attempted to obtain a duck, pluck it and roast it, but somewhere along the way it isn’t working out. These people deserve to get help because they have shown a willingness to learn by themselves.

What about the students that need to get their homework assignments in on time? Well, as it is obvious they’ve not done a jot of work themselves (unless you count copy and pasting their assignment to an online forum) their needs will most likely go unmet.

People get help because they deserve it, not because they need it. Does this sound unfair? Is it fair for me to waste my time helping someone who cannot even help themselves. To use another famous quote “Give a man a fish and you feed him for a day, teach a man to fish and you feed him for a life time“. If I just answer their question I use my time to just give them a fish even although I am trying to teach – I give them my fish that I caught to demonstrate during the lesson. If I can see that they are willing to learn then I know that if I teach them to fish, they will learn and they can then help themselves to as many as are in the sea.

A “richt fankle” is a Scots expression that means to get something in a complete mess. Code that is in a “richt fankle” would be most likely also be described as spaghetti code.

NOTE: This was resuced from the Google Cache. The original date was Wednesday 6th October, 2005.

Tags:


Original Comments:

I couldn’t have said it better Colin!

10/5/2005 4:00 AM | Rob Manderson

I continually experience co-worker brain death. When they realize that they can ask me for help, their brain stops working and they ask me the stupidest questions, that they could figure out themselves if they didn’t go into “I’ll ask Marc” mode. Sigh.

It is a balance though, to decide how much time to spend figuring out the answer oneself vs. asking someone for help.

Marc

10/5/2005 1:57 PM | Marc

A bad workman blames his tools

I wish that some people, when asking questions on a forum, would look inwards for a moment and reflect whether they really understand what they are talking about before making unfounded bold statments such as:

.NET is only one problem after another problem smiley_mad smiley_mad smiley_mad

One such poster on Code Project made a statement like that, then provided his code that was talking 2 minutes to run and that was unacceptable. He was blaming Microsoft and the .NET Framework but from one look at his code it was obvious where the problem was – and it wasn’t with Microsoft or the .NET Framework.

He wanted to update a column on a table. In fact he wanted to update that column on every row in the table. So, he pulled across 100,000 rows in to his .NET application then proceeds to loop over each returned row performing an UPDATE statement. So, in total he sent 100,001 commands to SQL Server. His complaint was magnified because he was expecting to have situations where 1,000,000 rows would need to be updated and that would take much longer. (20 minutes by the method he was employing)

Was the .NET application doing anything fancy as part of the update? No, it was simply copying the value from one column to another.

All his .NET code could be reduced to sending just one single piece of SQL to the database to do all the work. A simple UPDATE statement would do everything and take less than a second to execute – most likely even for a million rows.

But, did the poster seem to accept that perhaps it was his code or his misunderstanding of how the database could be leveraged that was at fault. No! He was insistant, with lots of angry faces, that it was Microsoft‘s fault for not getting the .NET framework right.

NOTE: This was rescued from the Google Cache. The original date was Wednesday, 5th April, 2006.

Tags:


Original comments:

Good Lord!
Did you reply to him with the obvious?
Maybe his next step will be to use a cursor within a single SQL statement and then blame the database!

ACK!

4/5/2006 9:23 PM | LJ

I told him how to get better performance, and I did point out that it wasn’t Microsoft‘s fault. It was his poor code.

4/5/2006 9:27 PM | Colin Angus Mackay

Don’t worry as his 386 workstation, with 4Mb of RAM and a dial-up modem will always ensure he is slow!

I’d have politely pointed out that his code “sucks”, what was wrong, what could be done to fix it then told him to get another career.

You should have linked to the CodeProject thread that shows this plonker in action!!!

4/5/2006 9:52 PM | John A Thomson

I find this a lot with rookies. Although, development these days requires you know a number of disciplines. SQL, ASP.NET, VB.NET/C#, HTML, T-SQL. Fast machines normally hide an inefficient programmer. That is why you need a jack-of-all-trades. Great blog.

4/19/2006 2:13 PM | Calvin

Oh yeah I know a few of them.

5/7/2006 3:37 PM | Derek Smyth

Help me to help you! Help me to help you! Help me to help you!

I’m a fan of the comedy-drama show Scrubs and Dr. Cox repeatedly tells young Dr. Dorian “Help me to help you! Help me to help you! Help me to help you!” And I think that is excellent advice for people who want help in forums. (And after my stressed out day yesterday you can probably see a rant coming).

Now, I guess I can understand why some people might want to hide what they are actually doing. They have code that is being written under an NDA or is somehow comercially sensitive. However, if they need to ask for help on forums then they have already implicitely admitted that it it isn’t that sensitive because they think someone else may already have solved that particular problem. Unfortunately, they haven’t admitted that to themselves yet and it makes it much harder for someone who really really wants to help to… well… help.

People wrap up their problems into abstractions and post that. Or they type up code that should have the same problem, but doesn’t. Or they do some other strange thing which hides what their actual goal is and scuppers many chances of getting the help they need.

For example. One poster said they wanted to manipulate some data from one table into another table. He showed some sample data in the first table. But the columns were called “az” and “azz”. What does that mean? The values in the columns didn’t mean anything as there wasn’t an explanation. Perhaps one was a primary key… perhaps it was something else… In the sample set of data some values were a dot. Was it really a dot or was that being used as a stand in for null. Only the original poster knows. When it came to putting the data in the new table there wasn’t an obvious relationship. How can anyone figure out what the rules are to manipulate from one to the other with such scant information?

So, in the words of Dr. Cox: Help me to help you!

NOTE: This was rescued from the Google Cache. The original date was Thursday, 4th May, 2006.

Tags:

Wading through someone else's source code

A copy of one of my posts in Code Project:

Tintin92 wrote: Add upload ability for users who dont want post article, but add a small sample project at their question.

If I see a question on a forum with a “small sample project” attached I’d ignore it. It is difficult enough to help people as it is without wading through tonnes of source code to try and find their problem. It is much better training for them that they can detect where the problem lies in the first place and present it well than be told to change line 1437 of xyz.vb in order to get their program to work.

In order to help people I already wade through poor descriptions of problems that frequetly lack the error message, what the code is supposed to do, what happens, where the problem is, and so on; poor language skills (and I do try and make allowances for people whose first language is not English); the entire file posted (despite the Code Project forum warning the poster that the post is excessive in size); and many other things that make it more difficult for the person trying to help actually help.

See also:


“On two occasions, I have been asked [by members of Parliament], ‘Pray, Mr. Babbage, if you put into the machine wrong figures, will the right answers come out?’ I am not able to rightly apprehend the kind of confusion of ideas that could provoke such a question.” –Charles Babbage (1791-1871)
My: Website | Blog

This was rescued form the Google Cache. The original post was dated Wednesday 17th May 2006.

I have never been so frustrated in all my life

A short while ago a guy I was helping out on Code Project commented that “I have never been so frustrated in all my life!!!!!”. He’s just starting out programming, probably lesson 2 or 3 by the looks of the questions he was asking, and was naturally having some initial difficulty understanding the concepts being taught to him. Although I’m trying to be as helpful as possible it did take a lot of effort not to say something along the lines of “Welcome to the club” or “That’s normal, I’ve been writing programs for over 20 years and I still get frustrated by things on a weekly basis”. I said, hopefully encouragingly, “Yeah! But is is such a wonderful feeling when it all works out!”

NOTE: This was rescued from the Google Cache. The original date was Sunday 28th May, 2006.


Some of the original comments:

Yeah, I well remember that sense of bewilderment when I was starting out. It just didn’t seem to make sense that one had to move the contents of memory into the accumulator to perform an operation on it and then move the result back to memory. *shrug*

The move to message based programming was similarly bewildering. Getting used (in the Windows context) to the idea that not only did my program call into the O/S but that the O/S could and would call back into my program took a while.

5/28/2006 1:51 AM | Rob

Looks like he never had a stubborn girlfriend 🙂

5/28/2006 5:34 AM | leppie

Mmmmm… looks like someone else might need to learn about time out with a camera to repair the frustrated, overworked brain 🙂

5/29/2006 3:57 AM | Meg Forbes