The only pseudocode I write is in comment form in place of the lowest-level code. As the real code is written, these comments are deleted.
This isn't even necessary for most functions; usually the best way is to write the function as I'd like it to be, then write the bodies for functions that I had to pretend existed.
Name:
Anonymous2010-09-05 7:29
I write the entire code at once then debug it.
It works 20% of the time.
>>6
I tend to write a few functions then I test them, if I'm using Lisp, since testing is easy there. If I'm using C, I tend to write the entire module at once, or just test some of the functions. There have been enough cases where I've been pleasantly surprised to have a bug-free program on my first try, on other cases, there are sometimes some obvious bugs which are easily fixed, and in very rare cases, there are bugs which can be hard to find.
I always scribble something on my whiteboard, be it pseudocode, flowcharts, or particular formulas for my program.
Name:
Anonymous2010-09-05 9:50
Sometimes I doodle things like arrays and pointers if im doing some particular ugly multi-derefencing array hacking or something, but not normally. mostly its all visualized in my head
I usually write out the whole program as broad descriptions of what it should do, and then progressively replace each part with a more specific and detailed description. I keep doing this until the description are basically equivalent to what the code would be, and then I just translate them.
Works a lot better than what most people understand when you say ``pseudocode''.
>>1
It really depends on the situation. If I'm adding a new feature to an existing product, by the time I get through the design phase, I have enough artifacts (class diagrams, sequence diagrams, etc.) to go straight to code. I start by stubbing out all of my classes, so that's a bit like pseudocode.
If I'm starting a new product, however, I like to code up a quick "proof of concept" in python. It's a quick and easy way to get a prototype in front of the customer to make sure we're all on the same page. I can then work from the python instead of just from pseudocode.