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. Never found a programming language I couldn't love

Never found a programming language I couldn't love

Scheduled Pinned Locked Moved The Lounge
tutorialdata-structuresjsonoop
45 Posts 25 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.
  • P PIEBALDconsult

    xperroni wrote:

    you don't know enough about C++

    I've only ever dabbled in C++, because C was paying the bills*. So, yes I don't know much about C++. But last week I was dabbling again and really didn't see the point of references. I've been using raw unadulterated pointers for decades and I don't miss what I aim at. * More recently, C# was paying the bills. Now it's VB. X|

    X Offline
    X Offline
    xperroni
    wrote on last edited by
    #30

    PIEBALDconsult wrote:

    But last week I was dabbling again and really didn't see the point of references.

    Think of them as pointers that are guaranteed (well, sorta) to point to a valid instance. This is checked at compile time, so in principle they would ensure that no "dangling pointer" errors happen, ever. Of course the reality is a little more complicated, and there are still ways you can overflow your leg off. Also they take some practice to use effectively, but in my experience they largely deliver - I've been on and off C++ programming for 10-odd years and only once I managed to screw a reference, whereas I pierce my feet on C wild pointers (mine and other people's) every other week.

    P 1 Reply Last reply
    0
    • J J Dunlap

      A language that's bad for me to use is one that gets in my way or frequently annoys me even when I make repeated efforts to adopt its "style". Good code can be written even in "bad" languages (with a few exceptions), given enough careful attention, but for some languages, it's typically just not worth the effort. (Granted, different people have different opinions on which languages those are.) That being said, I've been known to willingly write code even in the languages I dislike, because there was money to be had from it.

      X Offline
      X Offline
      xperroni
      wrote on last edited by
      #31

      Wot u sed.

      1 Reply Last reply
      0
      • X xperroni

        PIEBALDconsult wrote:

        But last week I was dabbling again and really didn't see the point of references.

        Think of them as pointers that are guaranteed (well, sorta) to point to a valid instance. This is checked at compile time, so in principle they would ensure that no "dangling pointer" errors happen, ever. Of course the reality is a little more complicated, and there are still ways you can overflow your leg off. Also they take some practice to use effectively, but in my experience they largely deliver - I've been on and off C++ programming for 10-odd years and only once I managed to screw a reference, whereas I pierce my feet on C wild pointers (mine and other people's) every other week.

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

        xperroni wrote:

        to point to a valid instance

        I don't see that as a big deal.

        X 1 Reply Last reply
        0
        • D Dalek Dave

          You are way too young then. Try COBOL, structured? they never heard of the word. MSX BASIC, you just hated it, that was all there was. Pascal, Let's just say that if you knew ALGOL, you stuck with ALGOL.

          ------------------------------------ I will never again mention that I was the poster of the One Millionth Lounge Post, nor that it was complete drivel. Dalek Dave CCC League Table Link CCC Link[^]

          M Offline
          M Offline
          Mike Winiberg
          wrote on last edited by
          #33

          Dalek Dave wrote:

          Pascal, Let's just say that if you knew ALGOL, you stuck with ALGOL.

          Oh yes! I wrote a payroll system in Algol 60, followed some years later by a vector based plotting system in Pascal - Algol 60 was definitely a nicer beast to work with (but not available on the equipment I was using for the plotting software...) I've only ever written one COBOL program in my entire programming career (coming on for 40 years now FFS!), and that was only a mod to an existing research suite at Uni - never felt the need to touch it again (although I do have to process data produced by a bank's COBOL mainframe software, so knowing how the ISAM files are put together is useful...) :omg:

          1 Reply Last reply
          0
          • X xperroni

            Some say that "when the lady can't dance, she complains the band can't play". Generally that's my feeling towards complaints that such-and-such language is "bad", or that it produces "bad" code. I do agree that some languages lend themselves more than others to certain good (or bad) practices, and that some languages are better/worse suited than others for some problems. However, in my experience the most crippling problems are the result of poor programming style: the respective programmer community either doesn't know, or seems to forget how to write clear code once they join in. As way of example, this is my list of good practices for several widely-belittled languages. It's mostly about how you can use each language's specific features to uphold the principles of structured / OO programming: Visual Basic

            • Always use Option Explicit for enforcing variable declaration;
            • Shun Variant variables – always use definite types;
            • Horribly misnamed as they are, embrace "Classes" as the way to go for behavior encapsulation;
            • Use the Object type sparingly, but learn to recognize where it can be leveraged for generalizing algorithms;
            • Well employed, the On Error machinery can make do as an effective Exception system;
            • Prefer Collections over Arrays, and learn to explore their associative features.

            C

            • Just because the language doesn't enforce a type-oriented form of programming doesn't mean you shouldn't. Always think about problems in terms of data types and accompanying operation (function) sets;
            • Structure your code as a collection of header / source pairs, where the header defines (ideally) one data type and its API, and the source contains the implementations;
            • Create more complex types by composing simpler ones, and likewise implement their API's in terms of the lower types' interfaces;
            • When designing a type's API, remember to provide functions for dynamic instantiation, initialization of stack-defined instances, and deletion. Consider providing macros for access to struct fields, instead of conceding to direct dereference;
            • Preserve the global namespace by defining symbols as static whenever they don't have to be seen outside their compilation units;
            • Use function pointers for generalizing complex algorithms;
            • Though dreadful when used carelessly, macros have great potential for simplifying progr
            C Offline
            C Offline
            Christian Vigh
            wrote on last edited by
            #34

            Hi friends, It's clear that using a specific programming language may sometimes influence the way you develop, unless you have a solid programming experience. If you only worked with the C language, then when you will turn yourself to C++, you will be inclined to develop in C++ like you used to develop in C. But once you have worked with several programming languages, and designed several software architectures and algorithms, using a new language becomes a matter of performing analogies with your past experiences and, magically, this is no more the new language you just learned that guides your way of developing things, but your own experience. I just have one counter-example about that : it's IBM's RPG language (I don't know what it has become today, but I've used RPG II and RPG III). I worked with that during one year in 1992 and this was the worst programming experience I have had. I'm sometimes inclined to think that programming in Brainfuck would be more effective. If you are curious, have a look at the following site which offers an exotic programming language, Goto++ : http://www.gotopp.org/index.html.en This is a real programming language, with lots of funny features, most of them being absolutely useless but it has been made by a guy who has a really great sense of humor ! Christian.

            1 Reply Last reply
            0
            • P PIEBALDconsult

              xperroni wrote:

              to point to a valid instance

              I don't see that as a big deal.

              X Offline
              X Offline
              xperroni
              wrote on last edited by
              #35

              PIEBALDconsult wrote:

              I don't see that as a big deal.

              Then surely you're "smarter than the average programmer" (me included), for memory management errors –specially "dangling pointers" – are pretty much the single largest cause of software defects. It's no wonder most modern languages strive to at least guarantee object references to be either valid or null.

              1 Reply Last reply
              0
              • X xperroni

                Some say that "when the lady can't dance, she complains the band can't play". Generally that's my feeling towards complaints that such-and-such language is "bad", or that it produces "bad" code. I do agree that some languages lend themselves more than others to certain good (or bad) practices, and that some languages are better/worse suited than others for some problems. However, in my experience the most crippling problems are the result of poor programming style: the respective programmer community either doesn't know, or seems to forget how to write clear code once they join in. As way of example, this is my list of good practices for several widely-belittled languages. It's mostly about how you can use each language's specific features to uphold the principles of structured / OO programming: Visual Basic

                • Always use Option Explicit for enforcing variable declaration;
                • Shun Variant variables – always use definite types;
                • Horribly misnamed as they are, embrace "Classes" as the way to go for behavior encapsulation;
                • Use the Object type sparingly, but learn to recognize where it can be leveraged for generalizing algorithms;
                • Well employed, the On Error machinery can make do as an effective Exception system;
                • Prefer Collections over Arrays, and learn to explore their associative features.

                C

                • Just because the language doesn't enforce a type-oriented form of programming doesn't mean you shouldn't. Always think about problems in terms of data types and accompanying operation (function) sets;
                • Structure your code as a collection of header / source pairs, where the header defines (ideally) one data type and its API, and the source contains the implementations;
                • Create more complex types by composing simpler ones, and likewise implement their API's in terms of the lower types' interfaces;
                • When designing a type's API, remember to provide functions for dynamic instantiation, initialization of stack-defined instances, and deletion. Consider providing macros for access to struct fields, instead of conceding to direct dereference;
                • Preserve the global namespace by defining symbols as static whenever they don't have to be seen outside their compilation units;
                • Use function pointers for generalizing complex algorithms;
                • Though dreadful when used carelessly, macros have great potential for simplifying progr
                X Offline
                X Offline
                xperroni
                wrote on last edited by
                #36

                By the way, "Cue epic battle over programming languages" indeed. Funny thing is, what I was aiming at was the exact opposite of that. The point I was trying to make is that, while different languages do have their relative pros and cons, with a little discipline it's possible to write clean code in pretty much anything. Unfortunately it seems you can't swing a dead cat around a programmers' forum without starting a spat over which language is "best" (and I count myself as part of the problem).

                M 1 Reply Last reply
                0
                • D Dan Neely

                  No they aren't. Pascal uses the obscene basic style begin end pairs X| X| X| X| X| X| to define statement blocks; not the divine { } pairs :cool::cool::cool::cool::cool::cool: of a C style language. They're nothing alike.

                  3x12=36 2x12=24 1x12=12 0x12=18

                  O Offline
                  O Offline
                  Oakman
                  wrote on last edited by
                  #37

                  Dan Neely wrote:

                  No they aren't. Pascal uses the obscene basic style begin end pairs to define statement blocks; not the divine { } pairs of a C style language. They're nothing alike.

                  ROFL!!! +5

                  Remember in November: But when a long Train of Abuses and Usurpations, pursuing invariably the same Object, evinces a Design to reduce them under absolute Despotism, it is their Right, it is their Duty, to throw off such Government, and to provide new Guards for their future Security.

                  1 Reply Last reply
                  0
                  • X xperroni

                    Some say that "when the lady can't dance, she complains the band can't play". Generally that's my feeling towards complaints that such-and-such language is "bad", or that it produces "bad" code. I do agree that some languages lend themselves more than others to certain good (or bad) practices, and that some languages are better/worse suited than others for some problems. However, in my experience the most crippling problems are the result of poor programming style: the respective programmer community either doesn't know, or seems to forget how to write clear code once they join in. As way of example, this is my list of good practices for several widely-belittled languages. It's mostly about how you can use each language's specific features to uphold the principles of structured / OO programming: Visual Basic

                    • Always use Option Explicit for enforcing variable declaration;
                    • Shun Variant variables – always use definite types;
                    • Horribly misnamed as they are, embrace "Classes" as the way to go for behavior encapsulation;
                    • Use the Object type sparingly, but learn to recognize where it can be leveraged for generalizing algorithms;
                    • Well employed, the On Error machinery can make do as an effective Exception system;
                    • Prefer Collections over Arrays, and learn to explore their associative features.

                    C

                    • Just because the language doesn't enforce a type-oriented form of programming doesn't mean you shouldn't. Always think about problems in terms of data types and accompanying operation (function) sets;
                    • Structure your code as a collection of header / source pairs, where the header defines (ideally) one data type and its API, and the source contains the implementations;
                    • Create more complex types by composing simpler ones, and likewise implement their API's in terms of the lower types' interfaces;
                    • When designing a type's API, remember to provide functions for dynamic instantiation, initialization of stack-defined instances, and deletion. Consider providing macros for access to struct fields, instead of conceding to direct dereference;
                    • Preserve the global namespace by defining symbols as static whenever they don't have to be seen outside their compilation units;
                    • Use function pointers for generalizing complex algorithms;
                    • Though dreadful when used carelessly, macros have great potential for simplifying progr
                    E Offline
                    E Offline
                    Euhemerus
                    wrote on last edited by
                    #38

                    Try pure assembly language, in the processor of your choice. Now, that's a real hard mans language; head down, arse up and with no safety net - scary stuff ;P

                    Nobody can get the truth out of me because even I don't know what it is. I keep myself in a constant state of utter confusion. - Col. Flagg

                    1 Reply Last reply
                    0
                    • X xperroni

                      By the way, "Cue epic battle over programming languages" indeed. Funny thing is, what I was aiming at was the exact opposite of that. The point I was trying to make is that, while different languages do have their relative pros and cons, with a little discipline it's possible to write clean code in pretty much anything. Unfortunately it seems you can't swing a dead cat around a programmers' forum without starting a spat over which language is "best" (and I count myself as part of the problem).

                      M Offline
                      M Offline
                      Member 3852024
                      wrote on last edited by
                      #39

                      I am from the old school - so I am quite happy with pointers. If you ever had to work with any kind of assembly language where you regularly used instructions like (390 assembler - LA) then using pointers; especially in a language like C/C++ seems very natural. After all most computing really just involves loading/accessing stuff/data in one location - doing something to it and then putting it in another location. Pointers rock. Additionally - once you understand the concept and are comfortable using them - you can develop programs/applications on a platform where you might not have the sophisticated library support you might otherwise currently rely on. Know the basics!

                      1 Reply Last reply
                      0
                      • X xperroni

                        Some say that "when the lady can't dance, she complains the band can't play". Generally that's my feeling towards complaints that such-and-such language is "bad", or that it produces "bad" code. I do agree that some languages lend themselves more than others to certain good (or bad) practices, and that some languages are better/worse suited than others for some problems. However, in my experience the most crippling problems are the result of poor programming style: the respective programmer community either doesn't know, or seems to forget how to write clear code once they join in. As way of example, this is my list of good practices for several widely-belittled languages. It's mostly about how you can use each language's specific features to uphold the principles of structured / OO programming: Visual Basic

                        • Always use Option Explicit for enforcing variable declaration;
                        • Shun Variant variables – always use definite types;
                        • Horribly misnamed as they are, embrace "Classes" as the way to go for behavior encapsulation;
                        • Use the Object type sparingly, but learn to recognize where it can be leveraged for generalizing algorithms;
                        • Well employed, the On Error machinery can make do as an effective Exception system;
                        • Prefer Collections over Arrays, and learn to explore their associative features.

                        C

                        • Just because the language doesn't enforce a type-oriented form of programming doesn't mean you shouldn't. Always think about problems in terms of data types and accompanying operation (function) sets;
                        • Structure your code as a collection of header / source pairs, where the header defines (ideally) one data type and its API, and the source contains the implementations;
                        • Create more complex types by composing simpler ones, and likewise implement their API's in terms of the lower types' interfaces;
                        • When designing a type's API, remember to provide functions for dynamic instantiation, initialization of stack-defined instances, and deletion. Consider providing macros for access to struct fields, instead of conceding to direct dereference;
                        • Preserve the global namespace by defining symbols as static whenever they don't have to be seen outside their compilation units;
                        • Use function pointers for generalizing complex algorithms;
                        • Though dreadful when used carelessly, macros have great potential for simplifying progr
                        B Offline
                        B Offline
                        BrainiacV
                        wrote on last edited by
                        #40

                        FORTH is the only one and true language. You dynamically bend the language to the application, not the other way around. FORTH programs can read its own source code while compiling, allowing you to create new syntax as required. I've got this great chunk of code that "looks" like documentation of Quad-OPTO modules for hardware control, but in actual fact, the code reads itself to dynamically create the needed addresses and bit positions that are assigned to a symbol. Even the guys from Forth, Inc when looking at a program I had developed for conveyor controls after pronouncing the majority of the code vanilla (as I had intended) they flipped to the I/O definition section and said, "But this was neat!" It had the rudiments of object orientation long before the concepts were around (being old school, I prefer BUILDS> DOES> to CREATE DOES>). FORTH also lets you write "bridging verbs" so that you can write code that will bridge the gap between syntaxes of different versions. So from whatever version of FORTH you are using, you add a few bridging verbs, and then you can compile FORTH from a different vendor with slightly different syntax. You don't have to crawl over the code to convert a working program into a non-working version as most conversions seem to do as a first pass. AND you can intermix high level FORTH with low level Assembly. Keyhole optimizations can be made by replacing high level FORTH with Assembly code. As long as they both eat and excrete the same stack contents, you are good to go. But I'll admit if I need to parse strings, BASIC (any variation) is my first choice.

                        Psychosis at 10 Film at 11

                        1 Reply Last reply
                        0
                        • X xperroni

                          Some say that "when the lady can't dance, she complains the band can't play". Generally that's my feeling towards complaints that such-and-such language is "bad", or that it produces "bad" code. I do agree that some languages lend themselves more than others to certain good (or bad) practices, and that some languages are better/worse suited than others for some problems. However, in my experience the most crippling problems are the result of poor programming style: the respective programmer community either doesn't know, or seems to forget how to write clear code once they join in. As way of example, this is my list of good practices for several widely-belittled languages. It's mostly about how you can use each language's specific features to uphold the principles of structured / OO programming: Visual Basic

                          • Always use Option Explicit for enforcing variable declaration;
                          • Shun Variant variables – always use definite types;
                          • Horribly misnamed as they are, embrace "Classes" as the way to go for behavior encapsulation;
                          • Use the Object type sparingly, but learn to recognize where it can be leveraged for generalizing algorithms;
                          • Well employed, the On Error machinery can make do as an effective Exception system;
                          • Prefer Collections over Arrays, and learn to explore their associative features.

                          C

                          • Just because the language doesn't enforce a type-oriented form of programming doesn't mean you shouldn't. Always think about problems in terms of data types and accompanying operation (function) sets;
                          • Structure your code as a collection of header / source pairs, where the header defines (ideally) one data type and its API, and the source contains the implementations;
                          • Create more complex types by composing simpler ones, and likewise implement their API's in terms of the lower types' interfaces;
                          • When designing a type's API, remember to provide functions for dynamic instantiation, initialization of stack-defined instances, and deletion. Consider providing macros for access to struct fields, instead of conceding to direct dereference;
                          • Preserve the global namespace by defining symbols as static whenever they don't have to be seen outside their compilation units;
                          • Use function pointers for generalizing complex algorithms;
                          • Though dreadful when used carelessly, macros have great potential for simplifying progr
                          S Offline
                          S Offline
                          StCroixSkipper
                          wrote on last edited by
                          #41

                          Folks must be forgetting the good old days. Remember when Basic Interpreters only allowed two character variable names? I don't care how creative you are, try to build a relatively simple system of today with two character names. That lady couldn't dance and that band couldn't keep time. StCroixSkipper

                          scooter_jsm

                          B 1 Reply Last reply
                          0
                          • S StCroixSkipper

                            Folks must be forgetting the good old days. Remember when Basic Interpreters only allowed two character variable names? I don't care how creative you are, try to build a relatively simple system of today with two character names. That lady couldn't dance and that band couldn't keep time. StCroixSkipper

                            scooter_jsm

                            B Offline
                            B Offline
                            BrainiacV
                            wrote on last edited by
                            #42

                            Wotsa Matter U? :wtf: Can't deal with A-Z, A0-A9...Z0-Z9, AA...AZ...ZA...ZZ? Not enough variables????? Why just add comments to explain them all :laugh:

                            Psychosis at 10 Film at 11

                            S 1 Reply Last reply
                            0
                            • B BrainiacV

                              Wotsa Matter U? :wtf: Can't deal with A-Z, A0-A9...Z0-Z9, AA...AZ...ZA...ZZ? Not enough variables????? Why just add comments to explain them all :laugh:

                              Psychosis at 10 Film at 11

                              S Offline
                              S Offline
                              StCroixSkipper
                              wrote on last edited by
                              #43

                              As I recall a very familiar name's claim to fame was his development of a Basic Interpreter with 2 character variable names. His accomplishment was so profound it was mentioned in a recent movie. I couldn't help but think it was tongue in cheek but only a developer who was there would recognize the humor.

                              scooter_jsm

                              1 Reply Last reply
                              0
                              • X xperroni

                                Some say that "when the lady can't dance, she complains the band can't play". Generally that's my feeling towards complaints that such-and-such language is "bad", or that it produces "bad" code. I do agree that some languages lend themselves more than others to certain good (or bad) practices, and that some languages are better/worse suited than others for some problems. However, in my experience the most crippling problems are the result of poor programming style: the respective programmer community either doesn't know, or seems to forget how to write clear code once they join in. As way of example, this is my list of good practices for several widely-belittled languages. It's mostly about how you can use each language's specific features to uphold the principles of structured / OO programming: Visual Basic

                                • Always use Option Explicit for enforcing variable declaration;
                                • Shun Variant variables – always use definite types;
                                • Horribly misnamed as they are, embrace "Classes" as the way to go for behavior encapsulation;
                                • Use the Object type sparingly, but learn to recognize where it can be leveraged for generalizing algorithms;
                                • Well employed, the On Error machinery can make do as an effective Exception system;
                                • Prefer Collections over Arrays, and learn to explore their associative features.

                                C

                                • Just because the language doesn't enforce a type-oriented form of programming doesn't mean you shouldn't. Always think about problems in terms of data types and accompanying operation (function) sets;
                                • Structure your code as a collection of header / source pairs, where the header defines (ideally) one data type and its API, and the source contains the implementations;
                                • Create more complex types by composing simpler ones, and likewise implement their API's in terms of the lower types' interfaces;
                                • When designing a type's API, remember to provide functions for dynamic instantiation, initialization of stack-defined instances, and deletion. Consider providing macros for access to struct fields, instead of conceding to direct dereference;
                                • Preserve the global namespace by defining symbols as static whenever they don't have to be seen outside their compilation units;
                                • Use function pointers for generalizing complex algorithms;
                                • Though dreadful when used carelessly, macros have great potential for simplifying progr
                                N Offline
                                N Offline
                                Nick Rioux
                                wrote on last edited by
                                #44

                                How about brainf*ck, INTERCAL, and Whitespace?

                                File Association in VB.Net

                                modified on Tuesday, October 26, 2010 8:08 PM

                                1 Reply Last reply
                                0
                                • D Dalek Dave

                                  You are way too young then. Try COBOL, structured? they never heard of the word. MSX BASIC, you just hated it, that was all there was. Pascal, Let's just say that if you knew ALGOL, you stuck with ALGOL.

                                  ------------------------------------ I will never again mention that I was the poster of the One Millionth Lounge Post, nor that it was complete drivel. Dalek Dave CCC League Table Link CCC Link[^]

                                  K Offline
                                  K Offline
                                  KP Lee
                                  wrote on last edited by
                                  #45

                                  First thing I thought of was COBOL when I saw the title. It works. It was the first thing I learned after assembler. I have to say, I preferred assembler to COBOL even if it is less readable. Its usable. I coded in it for two years straight before I found a transfer that used FORTRAN. A year later, I was brought kicking and screaming back to it because my new partner liked it. It certainly is good background knowledge when told to use PLI (very COBOLesk) Love is a very serious term. Can't say I've ever seen code where that term applies. A lot of them I Like. NEVER EVER COBOL.

                                  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