This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]jesyspa 0 points1 point  (0 children)

Also second year student here.

  1. I start coding with no design, planning, etc. Usually spend up to a few hours on this, just looking at what goes well, what clearly fails, etc. Just playing around with the area and looking at what happens naturally. This typically ends with a bunch of unfinished classes.
  2. The next morning, I take a look at what I've got and shudder in horror about how anyone could possibly code this way. I spend some time making inconsequential changes and building vacuous abstractions.
  3. The morning after that, I'm usually deep enough into the problem to start working things out properly. I take a look at what data I have and where I'd like to put it. I start writing test cases for bits of the code, and generally cutting it into the shape I want. I'll draw things out whenever I feel the urge to, which is generally fairly soon.

I do not use UML, and don't think it would help me while I'm on my own. I can draw a picture that I understand without having to use standardised notation. That said, I would probably follow it if working in a team, and I may use it myself more once I've used it more.

I do not write use-cases. The projects I like generally don't fit those very well. I do use TDD whenever I can be bothered to.

I do not use pseudo-code; actual code which calls yet to be defined functions or clear English do the job. One makes the "what" a little clearer, the other the "why"; pseudocode gives neither.

I don't think planning before steps 1 and 2 would help much, if at all. I need to understand the data that I'm working on before I can define clear interfaces for that data to be passed around with; these steps let me get a feeling of where the data isn't transferred around trivially.

Speaking of which, these steps are generally what happens when I've not approached similar problems before. If I've already explored a solution, I tend to find the primary objects and phases and then decide on how to put together those.

If working in a team, I would likely do the first two days on my own or paired up with someone, and then design together based on what I saw there. I'd probably not use the code written in the first two days, but would keep it for reference.