Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Other Discussions
  3. The Weird and The Wonderful
  4. Cut out for Greenpeace...

Cut out for Greenpeace...

Scheduled Pinned Locked Moved The Weird and The Wonderful
learningcollaborationhelp
8 Posts 4 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • Sander RosselS Offline
    Sander RosselS Offline
    Sander Rossel
    wrote on last edited by
    #1

    So my boss is like a rabbit. He just loves his greens. Unclear naming should stay unclear by commenting it (helper was never used, but that's beside the point).

    ' A helper variable.
    Dim helper As Boolean

    Of course we could make clear comments in favor of properly naming our variables.

    ' s is a SalesOrder
    s.DoSomething()

    p.DoSomethingElse ' PurchaseOrder

    The obvious also needs extra explanation.

    i = nX + nY ' Add nX and nY

    In case we ever want to compile our code into a beginners how-to-program book.

    ' Assign the value to the variable
    i = 10

    We just can't have enough comments!

    ' Refresh the screen
    RefreshScreen

    Keep an active log inside your code, you never know when you need it (SVN alone isn't good enough)... (date, initials, ticket number). The fun thing about this is that when a fix is larger than a few code files it does not have to be commented. If it is only a few code files chances are this piece of commentary is copied to each of them, sometimes in multiple places in the same file.

    ' 2012-09-22 N Ticket # 666.
    ' The client wants this fix because... Bla, bla, bla...
    CallSomeMethod

    Some of this guys methods are commented line by line with these kinds of comments... :wtf: I tried to talk to him about it, but he's convinced code is unreadable and can never be understood easily by just reading it. Comments are absolutely necessary if you, or another programmer, ever want to quickly make changes to the code. This is the same guy who thinks making a seperate class for almost every method (and randomly make it non-shared/non-static or shared/static) makes code more clear and readable (and single responsibility principle is a bonus!) and who just doesn't use access modifiers out of laziness or indifference... Of course he is my boss and has eight years of experience where I have only two (how often I had to hear that) so when I disagree with him I'm rude and inexperienced. I guess someday I'll laugh about it :~

    It's an OO world.

    public class Naerling : Lazy<Person>{
    public void DoWork(){ throw new NotImplementedException(); }
    }

    A C B 3 Replies Last reply
    0
    • Sander RosselS Sander Rossel

      So my boss is like a rabbit. He just loves his greens. Unclear naming should stay unclear by commenting it (helper was never used, but that's beside the point).

      ' A helper variable.
      Dim helper As Boolean

      Of course we could make clear comments in favor of properly naming our variables.

      ' s is a SalesOrder
      s.DoSomething()

      p.DoSomethingElse ' PurchaseOrder

      The obvious also needs extra explanation.

      i = nX + nY ' Add nX and nY

      In case we ever want to compile our code into a beginners how-to-program book.

      ' Assign the value to the variable
      i = 10

      We just can't have enough comments!

      ' Refresh the screen
      RefreshScreen

      Keep an active log inside your code, you never know when you need it (SVN alone isn't good enough)... (date, initials, ticket number). The fun thing about this is that when a fix is larger than a few code files it does not have to be commented. If it is only a few code files chances are this piece of commentary is copied to each of them, sometimes in multiple places in the same file.

      ' 2012-09-22 N Ticket # 666.
      ' The client wants this fix because... Bla, bla, bla...
      CallSomeMethod

      Some of this guys methods are commented line by line with these kinds of comments... :wtf: I tried to talk to him about it, but he's convinced code is unreadable and can never be understood easily by just reading it. Comments are absolutely necessary if you, or another programmer, ever want to quickly make changes to the code. This is the same guy who thinks making a seperate class for almost every method (and randomly make it non-shared/non-static or shared/static) makes code more clear and readable (and single responsibility principle is a bonus!) and who just doesn't use access modifiers out of laziness or indifference... Of course he is my boss and has eight years of experience where I have only two (how often I had to hear that) so when I disagree with him I'm rude and inexperienced. I guess someday I'll laugh about it :~

      It's an OO world.

      public class Naerling : Lazy<Person>{
      public void DoWork(){ throw new NotImplementedException(); }
      }

      A Offline
      A Offline
      AspDotNetDev
      wrote on last edited by
      #2

      Naerling wrote:

      Keep an active log inside your code

      Ugh. I hate that. At my last job, they were all about that. Half a million lines of SQL, and none of it in version control (it was all nearly lost once, except I and another person had a personal backup).

      Naerling wrote:

      I guess someday I'll laugh about it

      When the company collapses and you find a new job with reasonable code practices.

      Thou mewling ill-breeding pignut!

      Sander RosselS B 2 Replies Last reply
      0
      • A AspDotNetDev

        Naerling wrote:

        Keep an active log inside your code

        Ugh. I hate that. At my last job, they were all about that. Half a million lines of SQL, and none of it in version control (it was all nearly lost once, except I and another person had a personal backup).

        Naerling wrote:

        I guess someday I'll laugh about it

        When the company collapses and you find a new job with reasonable code practices.

        Thou mewling ill-breeding pignut!

        Sander RosselS Offline
        Sander RosselS Offline
        Sander Rossel
        wrote on last edited by
        #3

        AspDotNetDev wrote:

        When the company collapses and you find a new job with reasonable code practices.

        Nah, they've been good to me and though I disagree with their code practices (and I disagree on almost everything with the guy who writes these comments) I don't want them to collapse... The funny thing is that the guy who writes these comments taught me to code! Luckily I surpassed my 'master' in every way (after about a year) :) Although he's still the better SQL Server guy.

        It's an OO world.

        public class Naerling : Lazy<Person>{
        public void DoWork(){ throw new NotImplementedException(); }
        }

        1 Reply Last reply
        0
        • Sander RosselS Sander Rossel

          So my boss is like a rabbit. He just loves his greens. Unclear naming should stay unclear by commenting it (helper was never used, but that's beside the point).

          ' A helper variable.
          Dim helper As Boolean

          Of course we could make clear comments in favor of properly naming our variables.

          ' s is a SalesOrder
          s.DoSomething()

          p.DoSomethingElse ' PurchaseOrder

          The obvious also needs extra explanation.

          i = nX + nY ' Add nX and nY

          In case we ever want to compile our code into a beginners how-to-program book.

          ' Assign the value to the variable
          i = 10

          We just can't have enough comments!

          ' Refresh the screen
          RefreshScreen

          Keep an active log inside your code, you never know when you need it (SVN alone isn't good enough)... (date, initials, ticket number). The fun thing about this is that when a fix is larger than a few code files it does not have to be commented. If it is only a few code files chances are this piece of commentary is copied to each of them, sometimes in multiple places in the same file.

          ' 2012-09-22 N Ticket # 666.
          ' The client wants this fix because... Bla, bla, bla...
          CallSomeMethod

          Some of this guys methods are commented line by line with these kinds of comments... :wtf: I tried to talk to him about it, but he's convinced code is unreadable and can never be understood easily by just reading it. Comments are absolutely necessary if you, or another programmer, ever want to quickly make changes to the code. This is the same guy who thinks making a seperate class for almost every method (and randomly make it non-shared/non-static or shared/static) makes code more clear and readable (and single responsibility principle is a bonus!) and who just doesn't use access modifiers out of laziness or indifference... Of course he is my boss and has eight years of experience where I have only two (how often I had to hear that) so when I disagree with him I'm rude and inexperienced. I guess someday I'll laugh about it :~

          It's an OO world.

          public class Naerling : Lazy<Person>{
          public void DoWork(){ throw new NotImplementedException(); }
          }

          C Offline
          C Offline
          Clifford Nelson
          wrote on last edited by
          #4

          (Really) Bad smell, think we should refactor!

          1 Reply Last reply
          0
          • A AspDotNetDev

            Naerling wrote:

            Keep an active log inside your code

            Ugh. I hate that. At my last job, they were all about that. Half a million lines of SQL, and none of it in version control (it was all nearly lost once, except I and another person had a personal backup).

            Naerling wrote:

            I guess someday I'll laugh about it

            When the company collapses and you find a new job with reasonable code practices.

            Thou mewling ill-breeding pignut!

            B Offline
            B Offline
            BillW33
            wrote on last edited by
            #5

            Lack of decent version control is always a bad sign. :(

            Just because the code works, it doesn't mean that it is good code.

            1 Reply Last reply
            0
            • Sander RosselS Sander Rossel

              So my boss is like a rabbit. He just loves his greens. Unclear naming should stay unclear by commenting it (helper was never used, but that's beside the point).

              ' A helper variable.
              Dim helper As Boolean

              Of course we could make clear comments in favor of properly naming our variables.

              ' s is a SalesOrder
              s.DoSomething()

              p.DoSomethingElse ' PurchaseOrder

              The obvious also needs extra explanation.

              i = nX + nY ' Add nX and nY

              In case we ever want to compile our code into a beginners how-to-program book.

              ' Assign the value to the variable
              i = 10

              We just can't have enough comments!

              ' Refresh the screen
              RefreshScreen

              Keep an active log inside your code, you never know when you need it (SVN alone isn't good enough)... (date, initials, ticket number). The fun thing about this is that when a fix is larger than a few code files it does not have to be commented. If it is only a few code files chances are this piece of commentary is copied to each of them, sometimes in multiple places in the same file.

              ' 2012-09-22 N Ticket # 666.
              ' The client wants this fix because... Bla, bla, bla...
              CallSomeMethod

              Some of this guys methods are commented line by line with these kinds of comments... :wtf: I tried to talk to him about it, but he's convinced code is unreadable and can never be understood easily by just reading it. Comments are absolutely necessary if you, or another programmer, ever want to quickly make changes to the code. This is the same guy who thinks making a seperate class for almost every method (and randomly make it non-shared/non-static or shared/static) makes code more clear and readable (and single responsibility principle is a bonus!) and who just doesn't use access modifiers out of laziness or indifference... Of course he is my boss and has eight years of experience where I have only two (how often I had to hear that) so when I disagree with him I'm rude and inexperienced. I guess someday I'll laugh about it :~

              It's an OO world.

              public class Naerling : Lazy<Person>{
              public void DoWork(){ throw new NotImplementedException(); }
              }

              B Offline
              B Offline
              BillW33
              wrote on last edited by
              #6

              I like to comment my code, but only where really necessary. I also use meaningful variable names and method names so that the code is largely self-commenting. It is rare to see someone who wants both pointless comments and meaningless names, fortunately. ;) If those things are wrong there are likely other bad practices and I would think about looking for a better place to work.

              Just because the code works, it doesn't mean that it is good code.

              Sander RosselS 1 Reply Last reply
              0
              • B BillW33

                I like to comment my code, but only where really necessary. I also use meaningful variable names and method names so that the code is largely self-commenting. It is rare to see someone who wants both pointless comments and meaningless names, fortunately. ;) If those things are wrong there are likely other bad practices and I would think about looking for a better place to work.

                Just because the code works, it doesn't mean that it is good code.

                Sander RosselS Offline
                Sander RosselS Offline
                Sander Rossel
                wrote on last edited by
                #7

                CIDev wrote:

                there are likely other bad practices

                I found the same piece of code something like five times (EXACTLY the same). And then other pieces of code five times too. I found slightly different code even more often (don't make a function with input parameters, copy paste the code and change a word or two). I found functions that were called ChangeX(ByVal x As Integer) that also changes Y and Z, ChangeY(ByVal y As Integer) that also changes X and Z etc. Worst part is, this guy coded them and still called ChangeX, ChangeY and ChangeZ one after the other. Worst has still to come... This guy is technical director and pretends to be quality insurer (he is, but doesn't really insure anything). He has told me I should not code MessageBox.Show("Hello"), I should've done: Dim prompt As String = "Hello" MessageBox.Show(prompt) because... I don't know... He really doesn't understand I guess! If he would've coded it he wouldn't even have typed 'As String' because that's only inconvenient. I've even seen him use switch statements for booleans! Somehow this guy doesn't like If statements... And this guy is 'by the book' (really, if he sees something he doesn't like he always has a book that defends his position, it's freaky!)...

                It's an OO world.

                public class Naerling : Lazy<Person>{
                public void DoWork(){ throw new NotImplementedException(); }
                }

                B 1 Reply Last reply
                0
                • Sander RosselS Sander Rossel

                  CIDev wrote:

                  there are likely other bad practices

                  I found the same piece of code something like five times (EXACTLY the same). And then other pieces of code five times too. I found slightly different code even more often (don't make a function with input parameters, copy paste the code and change a word or two). I found functions that were called ChangeX(ByVal x As Integer) that also changes Y and Z, ChangeY(ByVal y As Integer) that also changes X and Z etc. Worst part is, this guy coded them and still called ChangeX, ChangeY and ChangeZ one after the other. Worst has still to come... This guy is technical director and pretends to be quality insurer (he is, but doesn't really insure anything). He has told me I should not code MessageBox.Show("Hello"), I should've done: Dim prompt As String = "Hello" MessageBox.Show(prompt) because... I don't know... He really doesn't understand I guess! If he would've coded it he wouldn't even have typed 'As String' because that's only inconvenient. I've even seen him use switch statements for booleans! Somehow this guy doesn't like If statements... And this guy is 'by the book' (really, if he sees something he doesn't like he always has a book that defends his position, it's freaky!)...

                  It's an OO world.

                  public class Naerling : Lazy<Person>{
                  public void DoWork(){ throw new NotImplementedException(); }
                  }

                  B Offline
                  B Offline
                  BillW33
                  wrote on last edited by
                  #8

                  Yeah, that does sound pretty scary. It is expecially bad that he is a technical director. :sigh:

                  Just because the code works, it doesn't mean that it is good code.

                  1 Reply Last reply
                  0
                  Reply
                  • Reply as topic
                  Log in to reply
                  • Oldest to Newest
                  • Newest to Oldest
                  • Most Votes


                  • Login

                  • Don't have an account? Register

                  • Login or register to search.
                  • First post
                    Last post
                  0
                  • Categories
                  • Recent
                  • Tags
                  • Popular
                  • World
                  • Users
                  • Groups