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 want to better write code with pen and paper. Whether it'll be in pseudocode or real code, doesn't matter.

Could you kindly advise me sources for this?

share|improve this question

closed as not constructive by gnat, Jalayn, ChrisF Feb 1 '13 at 11:53

As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.If this question can be reworded to fit the rules in the help center, please edit the question.

Could you clarify why you want to better write code on paper? Most computers these days don't need their programs on punch cards any more. – Gustav Bertram Feb 1 '13 at 7:26
In case someone will ask me to write a code without PC. – dhblah Feb 1 '13 at 7:27
Q. How do I get better at X? A. Practice X. – jk. Feb 1 '13 at 7:41
@jk there is a saying "practice makes perfect". That is as wrong as can be, only perfect practice makes perfect. If you practice a lot, but badly, you're just going to become very good at doing it badly. To become good you need to practice a lot but you need to practice in a good way, and for that you need guidance to show how to do it good. – Pieter B Feb 1 '13 at 12:24
Same way you get to Carnegie Hall: PRACTICE, PRACTICE, PRACTICE! – John R. Strohm Feb 1 '13 at 14:09

Do it more often!

Coding, whether with a computer or pen and paper, is one of those skills which is learned best by doing it more often. I'd start with working through problems on sites like Project Euler or Code Chef.

share|improve this answer
+1 Didn't know about Code Chef. A nice find! – Gustav Bertram Feb 1 '13 at 8:17
+1 Practice makes perfect – Spoike Feb 1 '13 at 8:49
Thank you, but that Project Euler you've mentioned. I'm a bit afraid, that problems there are too hard for an ordinary programmer. At least, from that website look it seems so. – dhblah Feb 1 '13 at 10:42
dhblah: It's very heavy on math and algorithms. I'd recommend by starting with the easy problems and working your way up. Applying algorithms through programming is a fantastic way to learn to write cleaner and more efficient code. – Zach Latta Feb 1 '13 at 11:23
-1 Just doing it more often will reinforce bad habits. Yes you need to do it more often but with some guidance from a book or a person or an internet forum that can point out to you your bad habits and weak spots. – Pieter B Feb 1 '13 at 12:53

People usually do this in an interview when they want to see how you think.

Always make sure you have plenty of paper available, since you can't correct mistakes the way you usually would. Be prepared to rewrite your program after making a rough draft.

I've also found that using diagrams like structure charts, or Warnier-Orr diagrams, helps me clarify my though processes.

If you want to try this with some simple programs to get some practice, I suggest Project Euler as a source of such program exercises. They are usually mathematically interesting!

Oh, and add lots of comments. More than you usually would. Remember, the potential employer is trying to see how you think - try to give them insight into your thought processes.

share|improve this answer

turn off the computer, grab pencils, paper, and an eraser, and get writing code.
Then, review it rigorously using references and try to prove its correctness.
Only when that's all done, sit down, type it in, compile and run to verify you got it right.
There is no other way.

share|improve this answer

While I applaud you for your ambitious(odd) dedication, I'm not so sure that pen and paper are the best solution for programming mastery. I would suggest learning to code in MS Notepad though. This is just my opinion, obviously, but I learned HTML/CSS/JavaScript in notepad and everything became muscle memory very fast. I actually got a contract job simply for putting ht/cs/js (using notepad) on my resume. I have also done 'some' C#.Net in notepad using the command-line compiler, and it's not so bad. Don't recommend it though.

My two cents.

share|improve this answer

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