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. Language + ? = BFF

Language + ? = BFF

Scheduled Pinned Locked Moved The Lounge
csharpc++javagraphicstutorial
44 Posts 13 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.
  • S Single Step Debugger

    What single structure or specific operator better defines a given language? As an example, I was thinking of: C * C++ - vector C# - List Java - arrays Any other languages or thoughts?

    There is only one Vera Farmiga and Salma Hayek is her prophet! Advertise here – minimum three posts per day are guaranteed.

    OriginalGriffO Offline
    OriginalGriffO Offline
    OriginalGriff
    wrote on last edited by
    #3

    I'd suggest that rather than the List<T> class, C# should be the string class or possibly the whole Generics system itself.

    "I have no idea what I did, but I'm taking full credit for it." - ThisOldTony "Common sense is so rare these days, it should be classified as a super power" - Random T-shirt AntiTwitter: @DalekDave is now a follower!

    "I have no idea what I did, but I'm taking full credit for it." - ThisOldTony
    "Common sense is so rare these days, it should be classified as a super power" - Random T-shirt

    P S 2 Replies Last reply
    0
    • P PIEBALDconsult

      C *
      C++ *
      C# .
      Java a large mug and lots of sugar

      Edit

      BASIC LET

      OriginalGriffO Offline
      OriginalGriffO Offline
      OriginalGriff
      wrote on last edited by
      #4

      Python: a tab and three spaces just to annoy people.

      "I have no idea what I did, but I'm taking full credit for it." - ThisOldTony "Common sense is so rare these days, it should be classified as a super power" - Random T-shirt AntiTwitter: @DalekDave is now a follower!

      "I have no idea what I did, but I'm taking full credit for it." - ThisOldTony
      "Common sense is so rare these days, it should be classified as a super power" - Random T-shirt

      P V 2 Replies Last reply
      0
      • OriginalGriffO OriginalGriff

        I'd suggest that rather than the List<T> class, C# should be the string class or possibly the whole Generics system itself.

        "I have no idea what I did, but I'm taking full credit for it." - ThisOldTony "Common sense is so rare these days, it should be classified as a super power" - Random T-shirt AntiTwitter: @DalekDave is now a follower!

        P Offline
        P Offline
        PIEBALDconsult
        wrote on last edited by
        #5

        No generics in v1. System.String is dreadful, the unavoidability of immutability is a very short-sighted (ivory tower) idea. They had to include StringBuilder just to make things work. It would be better for strings to be mutable by default and then be able to set them as immutable later as needed -- mystring.AsReadOnly() or mystring.ReadOnly = true Bleah, ptui. :mad:

        OriginalGriffO J 2 Replies Last reply
        0
        • OriginalGriffO OriginalGriff

          I'd suggest that rather than the List<T> class, C# should be the string class or possibly the whole Generics system itself.

          "I have no idea what I did, but I'm taking full credit for it." - ThisOldTony "Common sense is so rare these days, it should be classified as a super power" - Random T-shirt AntiTwitter: @DalekDave is now a follower!

          S Offline
          S Offline
          Single Step Debugger
          wrote on last edited by
          #6

          In the desktop/Win32 development I would agree. But in the web development List is making laps around any other generics type, or any other object.

          There is only one Vera Farmiga and Salma Hayek is her prophet! Advertise here – minimum three posts per day are guaranteed.

          P 1 Reply Last reply
          0
          • S Single Step Debugger

            In the desktop/Win32 development I would agree. But in the web development List is making laps around any other generics type, or any other object.

            There is only one Vera Farmiga and Salma Hayek is her prophet! Advertise here – minimum three posts per day are guaranteed.

            P Offline
            P Offline
            PIEBALDconsult
            wrote on last edited by
            #7

            That's due to poor developer skills, not because lists are superior.

            S 1 Reply Last reply
            0
            • P PIEBALDconsult

              C *
              C++ *
              C# .
              Java a large mug and lots of sugar

              Edit

              BASIC LET

              S Offline
              S Offline
              Single Step Debugger
              wrote on last edited by
              #8

              These days "." has mutated to "=>". And not in a good way. Like it's been infected with Prolog, or F# or something.

              There is only one Vera Farmiga and Salma Hayek is her prophet! Advertise here – minimum three posts per day are guaranteed.

              1 Reply Last reply
              0
              • P PIEBALDconsult

                That's due to poor developer skills, not because lists are superior.

                S Offline
                S Offline
                Single Step Debugger
                wrote on last edited by
                #9

                There is that too but is not always the case. Some Microsoft technologies/concepts are giving you no choice. EF and MVC come to mind.

                There is only one Vera Farmiga and Salma Hayek is her prophet! Advertise here – minimum three posts per day are guaranteed.

                P 1 Reply Last reply
                0
                • S Single Step Debugger

                  What single structure or specific operator better defines a given language? As an example, I was thinking of: C * C++ - vector C# - List Java - arrays Any other languages or thoughts?

                  There is only one Vera Farmiga and Salma Hayek is her prophet! Advertise here – minimum three posts per day are guaranteed.

                  D Offline
                  D Offline
                  David ONeil
                  wrote on last edited by
                  #10

                  vector for C++ just isn't the right choice, and indicates you are using C++ like C. virtual and template are both far better choices. Depending upon how you use the language, both of them can be supported with valid arguments, so I don't think either of them can be realistically picked over the other. If you don't understand virtual, see the C++ tutorial in my sig. If you don't understand template, just see any of honey the codewitch's work. C++ becomes magic.

                  Our Forgotten Astronomy | Object Oriented Programming with C++ | Wordle solver

                  S 1 Reply Last reply
                  0
                  • S Single Step Debugger

                    There is that too but is not always the case. Some Microsoft technologies/concepts are giving you no choice. EF and MVC come to mind.

                    There is only one Vera Farmiga and Salma Hayek is her prophet! Advertise here – minimum three posts per day are guaranteed.

                    P Offline
                    P Offline
                    PIEBALDconsult
                    wrote on last edited by
                    #11

                    Which just adds strength to my statement.

                    1 Reply Last reply
                    0
                    • S Single Step Debugger

                      What single structure or specific operator better defines a given language? As an example, I was thinking of: C * C++ - vector C# - List Java - arrays Any other languages or thoughts?

                      There is only one Vera Farmiga and Salma Hayek is her prophet! Advertise here – minimum three posts per day are guaranteed.

                      G Offline
                      G Offline
                      Gary R Wheeler
                      wrote on last edited by
                      #12

                      My favorite .NET data structure is Dictionary<_T_> hands down. I always found the C++ equivalents (STL's map and MFC's CMap) somewhat klunkier, mostly because of the template usage and resultant inscrutable compiler diagnostics.

                      Software Zen: delete this;

                      S P 2 Replies Last reply
                      0
                      • D David ONeil

                        vector for C++ just isn't the right choice, and indicates you are using C++ like C. virtual and template are both far better choices. Depending upon how you use the language, both of them can be supported with valid arguments, so I don't think either of them can be realistically picked over the other. If you don't understand virtual, see the C++ tutorial in my sig. If you don't understand template, just see any of honey the codewitch's work. C++ becomes magic.

                        Our Forgotten Astronomy | Object Oriented Programming with C++ | Wordle solver

                        S Offline
                        S Offline
                        Single Step Debugger
                        wrote on last edited by
                        #13

                        I wouldn't associate C++ with "virtual". Sure, it's a big part of the language concept, but not defines it. "Virtual" better fits with Java where everything is "virtual" by default. As for the templates, even C++ doesn't fully understand templates - at least until runtime. :) If you don't understand what I mean, think of separate template implementation and declaration. I know it's doable, but it doesn't feel natural.

                        There is only one Vera Farmiga and Salma Hayek is her prophet! Advertise here – minimum three posts per day are guaranteed.

                        D 1 Reply Last reply
                        0
                        • P PIEBALDconsult

                          C *
                          C++ *
                          C# .
                          Java a large mug and lots of sugar

                          Edit

                          BASIC LET

                          J Offline
                          J Offline
                          jmaida
                          wrote on last edited by
                          #14

                          My first take on programming language identifiers (not exhaustive by any means) C * C++ * COBOL ADD COBOL PIC FORTRAN do ALGOL begin PL/I BEGIN GO func

                          "A little time, a little trouble, your better day" Badfinger

                          1 Reply Last reply
                          0
                          • G Gary R Wheeler

                            My favorite .NET data structure is Dictionary<_T_> hands down. I always found the C++ equivalents (STL's map and MFC's CMap) somewhat klunkier, mostly because of the template usage and resultant inscrutable compiler diagnostics.

                            Software Zen: delete this;

                            S Offline
                            S Offline
                            Single Step Debugger
                            wrote on last edited by
                            #15

                            Yes, Dictionary is verry powerful when you search by key as it gives you O (log N) search, no duplications, ets. But if we go this path then DataTable is even more interesting. I also don't like how you can shoot yourself in the leg with the STL map. One assignment with missing reference operator and you are working with old data/copy.

                            There is only one Vera Farmiga and Salma Hayek is her prophet! Advertise here – minimum three posts per day are guaranteed.

                            0 1 Reply Last reply
                            0
                            • S Single Step Debugger

                              I wouldn't associate C++ with "virtual". Sure, it's a big part of the language concept, but not defines it. "Virtual" better fits with Java where everything is "virtual" by default. As for the templates, even C++ doesn't fully understand templates - at least until runtime. :) If you don't understand what I mean, think of separate template implementation and declaration. I know it's doable, but it doesn't feel natural.

                              There is only one Vera Farmiga and Salma Hayek is her prophet! Advertise here – minimum three posts per day are guaranteed.

                              D Offline
                              D Offline
                              David ONeil
                              wrote on last edited by
                              #16

                              So the word you are looking for is class. Not vector. :doh:

                              Our Forgotten Astronomy | Object Oriented Programming with C++ | Wordle solver

                              S 1 Reply Last reply
                              0
                              • P PIEBALDconsult

                                No generics in v1. System.String is dreadful, the unavoidability of immutability is a very short-sighted (ivory tower) idea. They had to include StringBuilder just to make things work. It would be better for strings to be mutable by default and then be able to set them as immutable later as needed -- mystring.AsReadOnly() or mystring.ReadOnly = true Bleah, ptui. :mad:

                                OriginalGriffO Offline
                                OriginalGriffO Offline
                                OriginalGriff
                                wrote on last edited by
                                #17

                                And no vector in C++ V1 either ... languages improve! :laugh: But string isn't too bad - it's not perfect, but it is way, way better than the char* / const char * mess that preceded it.

                                "I have no idea what I did, but I'm taking full credit for it." - ThisOldTony "Common sense is so rare these days, it should be classified as a super power" - Random T-shirt AntiTwitter: @DalekDave is now a follower!

                                "I have no idea what I did, but I'm taking full credit for it." - ThisOldTony
                                "Common sense is so rare these days, it should be classified as a super power" - Random T-shirt

                                P 1 Reply Last reply
                                0
                                • D David ONeil

                                  So the word you are looking for is class. Not vector. :doh:

                                  Our Forgotten Astronomy | Object Oriented Programming with C++ | Wordle solver

                                  S Offline
                                  S Offline
                                  Single Step Debugger
                                  wrote on last edited by
                                  #18

                                  Again, not verry C++ specific. Same for structures.

                                  There is only one Vera Farmiga and Salma Hayek is her prophet! Advertise here – minimum three posts per day are guaranteed.

                                  D 1 Reply Last reply
                                  0
                                  • S Single Step Debugger

                                    Again, not verry C++ specific. Same for structures.

                                    There is only one Vera Farmiga and Salma Hayek is her prophet! Advertise here – minimum three posts per day are guaranteed.

                                    D Offline
                                    D Offline
                                    David ONeil
                                    wrote on last edited by
                                    #19

                                    Quote:

                                    What single structure or specific operator better defines a given language?

                                    That was your question. template, virtual, and class are all better answers than vector. In fact, vector is an idiotic answer to that specific question. Especially since vector isn't a structure or operator. :doh: :doh: :doh: Of course, neither are the items I've given, but they do define the language.

                                    Our Forgotten Astronomy | Object Oriented Programming with C++ | Wordle solver

                                    S 1 Reply Last reply
                                    0
                                    • S Single Step Debugger

                                      What single structure or specific operator better defines a given language? As an example, I was thinking of: C * C++ - vector C# - List Java - arrays Any other languages or thoughts?

                                      There is only one Vera Farmiga and Salma Hayek is her prophet! Advertise here – minimum three posts per day are guaranteed.

                                      M Offline
                                      M Offline
                                      megaadam
                                      wrote on last edited by
                                      #20

                                      I would've said Java class Object But on the other hand I must admit that, when it comes to Java for me personally, a ten-foot-pole aint long enough :cool:

                                      "If we don't change direction, we'll end up where we're going"

                                      1 Reply Last reply
                                      0
                                      • OriginalGriffO OriginalGriff

                                        And no vector in C++ V1 either ... languages improve! :laugh: But string isn't too bad - it's not perfect, but it is way, way better than the char* / const char * mess that preceded it.

                                        "I have no idea what I did, but I'm taking full credit for it." - ThisOldTony "Common sense is so rare these days, it should be classified as a super power" - Random T-shirt AntiTwitter: @DalekDave is now a follower!

                                        P Offline
                                        P Offline
                                        PIEBALDconsult
                                        wrote on last edited by
                                        #21

                                        OriginalGriff wrote:

                                        languages improve

                                        Then it's not the same language.

                                        1 Reply Last reply
                                        0
                                        • S Single Step Debugger

                                          Yes, Dictionary is verry powerful when you search by key as it gives you O (log N) search, no duplications, ets. But if we go this path then DataTable is even more interesting. I also don't like how you can shoot yourself in the leg with the STL map. One assignment with missing reference operator and you are working with old data/copy.

                                          There is only one Vera Farmiga and Salma Hayek is her prophet! Advertise here – minimum three posts per day are guaranteed.

                                          0 Offline
                                          0 Offline
                                          0x01AA
                                          wrote on last edited by
                                          #22

                                          STL map is pretty ok, but you need to know how to use it....

                                          S 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