53

My programming teacher at university is programming like this. I'd better not learn anything from him

Comments
  • 24
    looks like he teaches algorithms, as i guess. You can spot the difference between the guy who is oriented mostly on algorithms and the guy who targets software debelopment too. the last one has meaningful names for variables.
  • 4
    Okay but what the fuck is that for loop
  • 2
    Looks that he failed as teacher. But what is backstory?! Is this beginners course, intermediate, is this computer science course or software development course?
  • 5
    @RazorSh4rk I think it's merging 2 sorted arrays (a and b) into a sorted array c.
  • 5
    It's computer science, first year, first programming course. Most of the people who attend the class have never programmed (not me fortunately), and the teacher knows it. But...
    BTW, that would be an algorithm that merges 2 sorted arrays into one (sorted)
  • 5
    And to me this code is more like c rather than c++…
  • 6
    Spaces are the least of the problems here
  • 10
    Line 56: i hope c[k] always Equals
    a (good ) B[J]
    :)

    but honestly this is fucking poison to my eyes
  • 5
    University in a nutshell, so glad I quit that shit hole
  • 2
    Probably he has not discovered the refactor code tool of the IDEs and tab key jjajaja
  • 2
    @Pampurio I understood meaning of code. Hell, I'm coding for almost 30 years. ;) Anyway, not particularly good teacher considering introductionary course.
  • 1
    AAARRRGGGHHH ..... my eyes .... must .... not ..... look .... it hurts my eyes please tell him to stop coding
  • 10
    Hey... why so much hate??? He's just pre-obfuscating his code! It's super efficient. #sarcasm
  • 5
    Somebody should make your teacher maintain a +500ksloc code of this quality for 10 years.
  • 3
    @Pampurio don't challenge your lecturer. I used to do that and later learnt that it's better to nod in agreement. Not worth the trouble. You'll surely meet 1 or more great minds on your way.
  • 4
    @Pampurio I once sat in a class were the lecturer would skip over slides that he didn't understand and those were a lot.
  • 1
    @Mayhem93 Crap university, you mean.
  • 1
    @firusvg someone before you asked for the meaning of the code :)

    @stalinkay I know, I won't! I learned that with another teacher, but that's another story. I just hope I'll never see him again... :P
  • 1
    I thought my code was giving out eyesicknesses
  • 2
    @capnsoup most of th courses I took at my uni had some kind of "what the fuck... " in them
  • 1
    This teacher is amazing! He obfuscated his code by design! Brilliant! It takes real talent to obfuscate code while you're writing it! Amazing!
  • 0
    @stalinkay on the contrary! It is the duty of every student to challenge the teacher.
  • 1
    @stuqshwk from my experience that largely depends on the lecturer, some have no problem with being challenged others take offense and that might affect how he/she treats you. Of course you can report said lecturer but I think it's a waste of your valuable time.
  • 0
    @stalinkay well, there is a lot of value in challenging existing knowledge. But that is almost never convenient. I know the kind of insecure and unreflected lecturer, that gives you a hard time. They suck and can kiss my ass.
  • 0
    At least he brackets right
  • 0
    @fireserpent is this "bracketing right"?
  • 0
    @stuqshwk 😂 yeah.
  • 2
    @RazorSh4rk <sarcasm>3 spaces, LGTM</sarcasm>
  • 0
    My programming teacher was super anal about correct indentation and bracketing style. Best teacher I've ever had.
  • 0
    In real life you'd be better off using meaningful variable names unless you add some comments that describe what the algorithm does and what each variable represents but this way of developing algorithms should be an exception and not the rule.

    For some highly mathematical algorithm I find this acceptable. And, if you are into math a bit it shouldn't be that hard to understand.
Add Comment