13

I'm a new programmer and want to ask senior programmers (programmers who have some experience in the real world).

I do my work and after coding, my project gets completed but honestly speaking I don't remember the code, classes and frameworks name and their properties.

Sometimes even I doubt myself that did I made this?

Is this normal with all programmers or am I the silliest programmer who couldn't remember the code and classes/properties names?

Edit:

I think many of programmers are getting me wrong here. I said I forget frameworks names, classes' names, property names but I start remembering my own code once I start working on it again. My question is do you remember syntax and classes/property etc. names?

necixy
  • 337

7 Answers7

24

In all honesty, I don't know how one could be a long term developer without the ability to "forget" code you've worked on. The amount of projects and resulting code would eventually lead to pure information overload.

However, I see this situation as a supporting argument for clean, logical design. There will come a time when you have to support your own code. If you've chosen strong and logical coding conventions, your familiarization time will be significantly reduced. Additionally, this would theoretically reduce the time required to perform the actual maintenance.

9

Remembering all of your syntax and apis for a project are not as important as remembering the concepts that went into building it. Once you have experience you can read over the code and figure out the meaning just like reading these posts.

What you'll find over time, if you are actively improving, is that you'll see the flaws in what you have written in the past just by reading over old code (which I recommend that you do). Through that practice it becomes easier to do; just like any other skill.

I have probably written over a million lines of code by now in my career and there is no way I could remember it all. I remember the projects though and what they were attempting to solve (and the techniques that went into solving them).

jmq
  • 6,108
5

I forget many things after I've done using them, but forget them differently.

I have watched myself over the years and I've come to the conclusion our brain (okay, my brain) employs a certain caching strategy:

  • New pieces of information are learned, used and then put in some expiration queue. In a few weeks it is gone.

  • Repeated access to those pieces of information once learned no later than a few months back promotes them somehow so that they can be remembered for months, only then do they expire.

  • Repeated access to the blocks of knowledge over the course of several years, with the usage gaps for several months promotes them to some priority memory where they kept for years.

P.S. I suspect the first idea of cache with application to computers have come from somebody observing how humans learn and remember things. So we haven't invented anything, just took what was already built into us.

2

Often. Comments have become passe', but I find I can usually recognize my code by my comments.

EDIT: I'm not saying I agree with the trend. I'm just saying that's the trend today. As Dave points out, there's certainly a breaking point. There's a perfectly wonderful discussion here: "Comments are a code smell". I fall in the "comments are for providing information on the world OUTSIDE the codebase (requirements, business changes, etc)" camp.

1

Syntax I generally remember after a couple of uses. For example, when I first started using generics or linq, I had some difficulty getting the syntax right.

IntelliSense definitely makes my job much much easier in remembering property and method names.

1

When I was a tester the lead dev of the company once told me that code was written 6 months ago none of my people can be held accountable for it. At the time it shocked me. Now that I have moved on to being a developer I understand. I don't remember the details of the code I do know I worked on it but the details aren't there.

Erin
  • 2,368
0

Almost always. My most recent (very small) project was a test of my own (rusting) skills. I had myself write a bunch of procedural code in a very simple C style, then refactor it into Java code using some design patterns and keeping every method to no more than eight lines, if I could.

I put the code down for about a month. When I came back to it, it took what seemed like an hour before I recognized that I had written it. Frankly, even if I had put my name in a comment field, I'm not sure it would have convinced me.

mfe
  • 156
  • 2