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 know this is kind of time-management question. I do well in short assignments, but fail miserably, when it comes to projects that require hours and hours of work to be done day after day.

I cannot code more than 10 minutes, unless there is a deadline. I kinda wander and come back and code. It takes me ridiculously large amount of time even for simple project. I kinda lack persistence. I have my thesis coming up in December. The more time I spend, the better my publication will be.

I was wondering, may be I could get some help on how to code persistently?

I just get out of my chair and start doing other things, when I see a bug or when I have a module that requires thinking and it takes me long time to come back sit and put my thought back to the code.

Any advice on how to improve my persistent coding skills?

share|improve this question

closed as not a real question by gnat, Walter, GrandmasterB, maple_shaft Apr 24 '12 at 19:58

It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center.If this question can be reworded to fit the rules in the help center, please edit the question.

Sounds like you might be burnt out. Have you been working too hard for too long? Sometimes it is simply discipline. – gahooa Apr 24 '12 at 2:29
Nope not really, I have been lazy for too long as opposed to how busy I used to be. Discipline is the straight answer, but its easier said than done, I need to work on those, any advise on this will help. Thanks. – howtechstuffworks Apr 24 '12 at 2:51
For guidance on discipline (independently from programming), might be better-suited. – Frank Apr 24 '12 at 5:15
INTP personality type? – Coder Apr 24 '12 at 7:37
@Frank, Yeah I posted there too.. – howtechstuffworks Apr 24 '12 at 13:41

I don't know what your field of study is but if it's anything related to Computer Science or Engineering I would question your future happiness in that field. I think I speak for many other programmers when I say that a programming problem that isn't solved in a couple of minutes is far more interesting and even enjoyable than routine coding. This is the reason many people want to develop, because they can use their brain and 'crack the code'.

Of course if your field of study only requires you to write some code now then I can understand your problem more clearly. Everyone has had to do things they really didn't want to do, when I'm faced with something like that I try to isolate the crappy part of that thing and really mentally challenge myself to do it as well as I possibly can. This sounds like very obvious advice, but if you're a competitive person you can really motivate yourself to put more effort into something than you would otherwise.

share|improve this answer
Yeah I am from computer science, I too like competative programming, in general in a project, before getting to the exciting part there is always a part of code that tests your patience usually the boring one. I cannot concentrate on more than few minutes if I sit on this, I like the thinking part, where I need to design, but after that it becomes boring, unless the deadline is approaching – howtechstuffworks Apr 24 '12 at 2:49
And regarding the programming problem time duration, I am talking about different level. For example, short duration - 1 week, long duration - 3 to 6 months. – howtechstuffworks Apr 24 '12 at 2:53
Why would you question happiness? Some people hate coding outright, but they are amazing architects, because they like to think about the big picture, not the implementation details. Personality type has to do a lot with this. And good structure in code is worth more than thousands of lines of unmaintainable/duplicated code. It's very good when you have both types of people in a team. – Coder Apr 24 '12 at 7:42
I may have worded it incorrectly with regard to the happiness and I certainly agree with you that people can be amazing architects and hate coding. But I do believe that to be an exceptional architect you need to have put in the hours as a coder, perhaps you disagree with me there. If becoming an architect is a genuine goal for Caleb then he can try to use this knowledge (being a good coder will certainly not make you a worse architect) to motivate himself. – Mekswoll Apr 24 '12 at 17:04

Your school surely has a counseling center -- take advantage of it. Whether it's time management, procrastination, or something else, it's still a real problem for you, and the folks at the counseling center will help you deal with it. They're there to help you, and you're certainly not the first student they've seen with a problem like this. Don't put it off (no joke), stop in as soon as you can and arrange to talk to someone.

share|improve this answer
Yeah, I have attended some lectures from my school counselling centers, I also know what to do, but for me,'its easier said than done'. I know what to do, but I fail to do :( – howtechstuffworks Apr 24 '12 at 13:48
Right, that's why you need to go talk to someone. Plenty of people know that they ought to quit smoking or lose some weight, and the necessary actions seem obvious: don't smoke, eat less, exercise regularly. But they just can't seem to do the obvious, or they start and then give up. It's easy to beat yourself up and say "I'm just too lazy," and that ends up being a convenient excuse for doing a lousy job. Asking for help can seem a lot harder -- you might have to figure out why you're having trouble instead of just avoiding it. Fixing it yourself obviously hasn't worked, so get some help. – Caleb Apr 24 '12 at 15:07

How is your project planning? In the past, I've had significant personal projects fall apart because I would get lost in the complexity of a project as its implementation details began to unwind beyond my initial expectations. As things would get messier, I would get frustrated and then sloppy as a result, eventually resulting in a horrible mess of code that would subconsciously encourage me to procrastinate (for fear of untangling the mess) until a fresh new idea piqued my interest.

Better planning really helps. Some prefer formal specifications like UML diagrams while others prefer to create an informal model of their application. Either way, with a project specification it becomes easy to remain productive when you hit roadblocks as you're able to quickly transition to an easier or exciting part of the project (while being assured that it is necessary work). When it comes time to return to your old problem, you know exactly which portion of the project you should return to and if your roadblock eventually leads you to rebuild a section of your application, your specification will guide you through a more efficient refactoring process.

share|improve this answer
Thats exactly, where I am at. I like informal coding. I am better working alone, rather than in a project. But if everyone in the project knows about, what they are speaking about, then I dont have a problem. I need to have a better structure. I write down a formal structure or things I need to do, but never see it again. When time comes to see what I am supposed to do, I write a new one, instead of following old one. Sticking to plan, is not really with me. – howtechstuffworks Apr 24 '12 at 13:46

I'm going to be blunt. You need to fix this problem before you get into the workplace. Work only in five minute increments and only on stuff you are interested in and prefering to work alone and not with a team are all reg flags of someone who would be a bad hire.

The first thing you need to do is disconnect from all the distractions. When you are working, no Facebook (or other Internet time-wasters), no phone, no IM/email, no games. Period. Never under any circumstances during work hours(well you can reintroduce work phone calls and work only IMs/emails later). SInce you aer in schoolll you will have to screate teh work scheduel, But I think you need to actually schedule the time every day to do this.

Next you need need to learn to concentrate for longer than five minutes. Set a timer for ten minutes (If you can't handle that then start at 6 minutes) and no matter what do not stop until it goes off. Gradually increase the time until you can concentrate for an hour.

Learn to do the boring bits first where possible and reward yourself for doing the stuff you don't like with the stuff you do like.

When you have a group project, do not work alone. Get the group together and work a scheduled set of hours. Set aside some time at either the beginning or end of the scheduled work period to discuss progress.

As far as you are OK if you like respect everyone on the project, well get rid of that attitude right now. You don't have to like co-workers to work with them. You need to be polite to everyone and offer the same professional competence whether the person is a jerk or not. If someone is going to cause disruptions because they can't get along, it is best to make sure it is someone else. This is totally about attitude, you can change your attitude.

share|improve this answer

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