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. The Lounge
  3. Empirical proof that underscores are good

Empirical proof that underscores are good

Scheduled Pinned Locked Moved The Lounge
csharpc++
40 Posts 28 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.
  • N Nemanja Trifunovic

    i_have_always_preferred_this_style ToCamelOrPascalOne and now there is a study that confirms my point of view[^] :cool:

    utf8-cpp

    L Offline
    L Offline
    loctrice
    wrote on last edited by
    #3

    If_You_Have_A_Name_That_Complicated_Then_You_Should_Consider_That_A_Warning_Sign_And_Change_Something

    If it moves, compile it

    L 1 Reply Last reply
    0
    • N Nemanja Trifunovic

      i_have_always_preferred_this_style ToCamelOrPascalOne and now there is a study that confirms my point of view[^] :cool:

      utf8-cpp

      R Offline
      R Offline
      Ron Beyer
      wrote on last edited by
      #4

      Quote:

      One main difference is that subjects were trained mainly in the underscore style and were all programmers. While results indicate no difference in accuracy between the two styles, subjects recognize identifiers in the underscore style more quickly.

      [sarcasm] So its a non-biased study then? [/end sarcasm]

      S N 2 Replies Last reply
      0
      • L loctrice

        If_You_Have_A_Name_That_Complicated_Then_You_Should_Consider_That_A_Warning_Sign_And_Change_Something

        If it moves, compile it

        L Offline
        L Offline
        Lost User
        wrote on last edited by
        #5

        loctrice wrote:

        If_You_Have_A_Name_That_Complicated_Then_You_Should_Consider_That_A_Warning_Sign_And_Change_Something

        Translation: IfYouHaveANameThatComplicatedThenYouShouldConsiderThatAWarningSignAndChangeSomething

        G 1 Reply Last reply
        0
        • N Nemanja Trifunovic

          i_have_always_preferred_this_style ToCamelOrPascalOne and now there is a study that confirms my point of view[^] :cool:

          utf8-cpp

          N Offline
          N Offline
          Nish Nishant
          wrote on last edited by
          #6

          How about camel with underscores? Example: Top_Message_List :-D

          Regards, Nish


          Blog: voidnish.wordpress.com Latest article: C++ 11 features in Visual C++ 2013 Preview

          L K 2 Replies Last reply
          0
          • L Lost User

            loctrice wrote:

            If_You_Have_A_Name_That_Complicated_Then_You_Should_Consider_That_A_Warning_Sign_And_Change_Something

            Translation: IfYouHaveANameThatComplicatedThenYouShouldConsiderThatAWarningSignAndChangeSomething

            G Offline
            G Offline
            GrumbleDuke
            wrote on last edited by
            #7

            Those both look like COBOL names

            1 Reply Last reply
            0
            • N Nish Nishant

              How about camel with underscores? Example: Top_Message_List :-D

              Regards, Nish


              Blog: voidnish.wordpress.com Latest article: C++ 11 features in Visual C++ 2013 Preview

              L Offline
              L Offline
              loctrice
              wrote on last edited by
              #8

              Isn't that title case ? :suss:

              If it moves, compile it

              N 1 Reply Last reply
              0
              • L loctrice

                Isn't that title case ? :suss:

                If it moves, compile it

                N Offline
                N Offline
                Nish Nishant
                wrote on last edited by
                #9

                loctrice wrote:

                Isn't that title case ?

                It's camel uppercase (or pascal / title case).

                Regards, Nish


                Blog: voidnish.wordpress.com Latest article: C++ 11 features in Visual C++ 2013 Preview

                T 1 Reply Last reply
                0
                • N Nish Nishant

                  How about camel with underscores? Example: Top_Message_List :-D

                  Regards, Nish


                  Blog: voidnish.wordpress.com Latest article: C++ 11 features in Visual C++ 2013 Preview

                  K Offline
                  K Offline
                  kmoorevs
                  wrote on last edited by
                  #10

                  This gets my vote for readability! :) The only downside is keyboard efficiency, but most of us only type a variable name once...the rest is auto-complete or copy/paste, so hardly a factor.

                  "Go forth into the source" - Neal Morse

                  N M 2 Replies Last reply
                  0
                  • K kmoorevs

                    This gets my vote for readability! :) The only downside is keyboard efficiency, but most of us only type a variable name once...the rest is auto-complete or copy/paste, so hardly a factor.

                    "Go forth into the source" - Neal Morse

                    N Offline
                    N Offline
                    Nish Nishant
                    wrote on last edited by
                    #11

                    Yeah, it's quite readable, isn't it? :-) And I agree, auto-complete means not having to type and re-type this all over the place!

                    Regards, Nish


                    Blog: voidnish.wordpress.com Latest article: C++ 11 features in Visual C++ 2013 Preview

                    1 Reply Last reply
                    0
                    • R Ron Beyer

                      Quote:

                      One main difference is that subjects were trained mainly in the underscore style and were all programmers. While results indicate no difference in accuracy between the two styles, subjects recognize identifiers in the underscore style more quickly.

                      [sarcasm] So its a non-biased study then? [/end sarcasm]

                      S Offline
                      S Offline
                      SoMad
                      wrote on last edited by
                      #12

                      :thumbsup: It's nice they put that right there in the intro. No need to read through the study then. :-\ Soren Madsen

                      "When you don't know what you're doing it's best to do it quickly" - Jase #DuckDynasty

                      R W 2 Replies Last reply
                      0
                      • S SoMad

                        :thumbsup: It's nice they put that right there in the intro. No need to read through the study then. :-\ Soren Madsen

                        "When you don't know what you're doing it's best to do it quickly" - Jase #DuckDynasty

                        R Offline
                        R Offline
                        Ron Beyer
                        wrote on last edited by
                        #13

                        "And in other breaking news studies, the University of Obvious found that people who's native language is English can pick out English phrases in German sentences better than German phrases".

                        L 1 Reply Last reply
                        0
                        • R Ron Beyer

                          "And in other breaking news studies, the University of Obvious found that people who's native language is English can pick out English phrases in German sentences better than German phrases".

                          L Offline
                          L Offline
                          lewax00
                          wrote on last edited by
                          #14

                          It's proof that English is better! :-D

                          1 Reply Last reply
                          0
                          • K kmoorevs

                            This gets my vote for readability! :) The only downside is keyboard efficiency, but most of us only type a variable name once...the rest is auto-complete or copy/paste, so hardly a factor.

                            "Go forth into the source" - Neal Morse

                            M Offline
                            M Offline
                            Mycroft Holmes
                            wrote on last edited by
                            #15

                            Will you sod off with your dammed logic that just killed my main argument (keyboard and intellisense) against underscores, I hate the bloody things and growl at any of the devs that employ them.

                            Never underestimate the power of human stupidity RAH

                            K 1 Reply Last reply
                            0
                            • M Mycroft Holmes

                              Will you sod off with your dammed logic that just killed my main argument (keyboard and intellisense) against underscores, I hate the bloody things and growl at any of the devs that employ them.

                              Never underestimate the power of human stupidity RAH

                              K Offline
                              K Offline
                              kmoorevs
                              wrote on last edited by
                              #16

                              Sorry about that! :) In the interest of keyboard efficiency, the most logical candidates would be: 0: space 1: period 2: semicolon 3: brackets[] Have fun using those! :laugh:

                              "Go forth into the source" - Neal Morse

                              1 Reply Last reply
                              0
                              • N Nemanja Trifunovic

                                i_have_always_preferred_this_style ToCamelOrPascalOne and now there is a study that confirms my point of view[^] :cool:

                                utf8-cpp

                                S Offline
                                S Offline
                                Super Lloyd
                                wrote on last edited by
                                #17

                                Stop wanking and start doing real work! :zzz: Next you'll bother us about {} instead of { } I wonder if there ever was something more pointless? Maybe it's what you argue about when your work doesn't matter, I suppose?!

                                My programming get away... The Blog... DirectX for WinRT/C# since 2013! Taking over the world since 1371!

                                S L 2 Replies Last reply
                                0
                                • S SoMad

                                  :thumbsup: It's nice they put that right there in the intro. No need to read through the study then. :-\ Soren Madsen

                                  "When you don't know what you're doing it's best to do it quickly" - Jase #DuckDynasty

                                  W Offline
                                  W Offline
                                  walterhevedeich
                                  wrote on last edited by
                                  #18

                                  And even better that Ron had put it here, so I would no longer need to open the link.

                                  Signature construction in progress. Sorry for the inconvenience.

                                  1 Reply Last reply
                                  0
                                  • N Nemanja Trifunovic

                                    i_have_always_preferred_this_style ToCamelOrPascalOne and now there is a study that confirms my point of view[^] :cool:

                                    utf8-cpp

                                    S Offline
                                    S Offline
                                    Septimus Hedgehog
                                    wrote on last edited by
                                    #19

                                    And somebody actually got paid for writing that?

                                    If there is one thing more dangerous than getting between a bear and her cubs it's getting between my wife and her chocolate.

                                    1 Reply Last reply
                                    0
                                    • S Super Lloyd

                                      Stop wanking and start doing real work! :zzz: Next you'll bother us about {} instead of { } I wonder if there ever was something more pointless? Maybe it's what you argue about when your work doesn't matter, I suppose?!

                                      My programming get away... The Blog... DirectX for WinRT/C# since 2013! Taking over the world since 1371!

                                      S Offline
                                      S Offline
                                      Simon ORiordan from UK
                                      wrote on last edited by
                                      #20

                                      Surely that's { } ?

                                      D 1 Reply Last reply
                                      0
                                      • N Nemanja Trifunovic

                                        i_have_always_preferred_this_style ToCamelOrPascalOne and now there is a study that confirms my point of view[^] :cool:

                                        utf8-cpp

                                        S Offline
                                        S Offline
                                        Stefan_Lang
                                        wrote on last edited by
                                        #21

                                        I wonder just how much this is influenced by the fact that the english language is all lowercase by default, with very few exceptions. In german, Nouns are always uppercase, that means for a german speaker, a symbol based on german words would be more natural to read if each noun would start with an uppercase letter (e. g. FeldIndex), whereas an english speaker basing his symbol on english nouns would consider it more natural to read it all lowercase (e. g. array_index).

                                        1 Reply Last reply
                                        0
                                        • N Nemanja Trifunovic

                                          i_have_always_preferred_this_style ToCamelOrPascalOne and now there is a study that confirms my point of view[^] :cool:

                                          utf8-cpp

                                          J Offline
                                          J Offline
                                          jsc42
                                          wrote on last edited by
                                          #22

                                          Just in case (sic) you had wondered, the_underscore_style_of_naming_variables_etc is known as Snake Case.

                                          G B 2 Replies 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