By using this site, you agree to our Privacy Policy and our Terms of Use. Close

Forums - General - A Question for Programmers

Does anyone else have an issue where they struggle to read other people's code?

A friend recently just asked me to help them with an issue they had with a bit of code, so I asked them to send it over, however, once they sent it over, I could not make hide nor hair of what they were trying to do.

The code was well commented, and it was pretty clearly laid out with plenty of whitespace and indentation, but I just couldn't read it.

So, instead, I just asked them what the issue was, and I wrote out my own solution and sent it to 'em to stick in their own code.

It's something that I'll improve on over time, as we're all relatively new to programming, but even when it comes to the mock exam, where I have nothing else extracting me, and I have to work out what a piece of code is doing, it takes me an age, and I generally need to write it all down on a scrap piece of paper, with truth tables, my own version of the code all over the gaff.

Hopefully, it'll come to me naturally eventually. I mean, I have no problems writing my own code, and my code tends to be the most efficient in the class, and I'm often the first to finish an assignment, but it's just reading other people's code I have issues with.

This issue better go, as I forsee my working career with me combing over thousands and thousands of lines of other peoples code with a fine toothpick, and I don't think that entirely rewriting everything would be the most productive way to go about things.

Anyone else suffer with this?



Around the Network

Actually I don't have this issue at all. I have about 6 GB of source of all kinds of programs (mostly small os'es) that I check from time to time when I need to build something. I'm an Opensource enthousiast so I enjoy it more than I struggle with it.

Finding things back in someone elses code can be annoying though, so if you're working with C/C++ or java I suggest you checkout ctags and cscope two awesome utilities that make code surfing alot easier



How can you possibly misspell QWERTY? It's spelled correctly on the damn keyboard.

Sylvarantinc said:

Actually I don't have this issue at all. I have about 6 GB of source of all kinds of programs (mostly small os'es) that I check from time to time when I need to build something. I'm an Opensource enthousiast so I enjoy it more than I struggle with it.

Finding things back in someone elses code can be annoying though, so if you're working with C/C++ or java I suggest you checkout ctags and cscope two awesome utilities that make code surfing alot easier

 

 Well, as I said, we're relatively new to programming. Started the college (UK college - college has a different meaning in some countries) course last September. They're teaching us the "principles of programming" - so they're teaching us how to program, not a programming language per se.

What we code in is c# and vb. (Also touched on HTML in a theory lesson, but that's not the same, obv). Next year we play with c++, java, etc... although I'll probably do it during the summer break, anyways.



Having only done minimal coding (mostly web based stuff), I can say that was definitely a problem I had. Thankfully I don't programme anymore.



FaRmLaNd said:
Having only done minimal coding (mostly web based stuff), I can say that was definitely a problem I had. Thankfully I don't programme anymore.

 

 How well did you know the languages before hand? If you've only done minimal programming, the problem could've been attributed to plumb just not knowing what certain functions did.



Around the Network

That was certainly an element of it, I was never that good at coding, but it was always easier to understand stuff I'd done, which I think is quite logical and something you'd get better at the more you do it.



I hate it when people use Action Script 2.0 while I use Action Script 3.0 in FLASH... I hate you all!!!!!



 

Face the future.. Gamecenter ID: nikkom_nl (oh no he didn't!!) 

NiKKoM said:
I hate it when people use Action Script 2.0 while I use Action Script 3.0 in FLASH... I hate you all!!!!!

 

 And that's the very reason why I hate ActionScript, the different versions mean that it's really hard for me to find tutorials on the web, well, it did, when I was looking for 'em.

My desire to make flash games died with my desire to play them.



I hate it when they bring out actionscript 3.0 while I was just about used to 2.0!



Nintendo Network ID: Cheebee   3DS Code: 2320 - 6113 - 9046