Friday, November 6, 2009

Code

One of the big problems in physics is that we all code. That's not really the problem. The problem is that we all use different languages, and we don't anticipate anyone ever looking at what we write. Because of this, when it turns out someone has to actually use your code, they're screwed. We don't comment, and we give variables names like "x" instead of something more descriptive. It leads to a lot of pain and suffering among graduate students. I can't say that I don't do this either, but I like to think that my minimally descriptive comments are better than most people's nonexistent comments. When I took CS at Pomona, they would grade us on our comments, so it became ingrained. When I stopped having to do so, I stopped doing it at much, but I think I still comment way more than anyone I know.

No comments: