Posted on 10/13/2011 9:00:58 PM PDT by budj
"Dennis Ritchie, an internationally renowned computer scientist who created the C programming language, has died at age 70. ..."
(Excerpt) Read more at news.cnet.com ...
This old fart concurs with your assessment. Languages, compilers, and libraries have become so abstract and bloated it's ridiculous. Programmers become removed from what's really going on, and are clueless if their particular flavor of the year can't get the job done. Computing history is littered with the carcasses of languages, frameworks, libraries, and the 'latest and greatest' *new* ways of doing things. I'll continue to use C whenever and wherever I can.
Your post would be funny if it were not true.
I don’t doubt that it is possible to write good software in C. Linus Torvalds has certainly proven that. But if you write reliable software in C, you did it *despite* C, not because of C. Or you used a small subset of C. Or your application was relatively simple.
Sorry, but C is just fundamentally more error prone than some other languages. I think of programming in C as analogous to riding a motorcycle as opposed to driving a car. It takes more skill. Yes, some people can ride a motorcycle safely for years, but it would be nonsensical to claim that motorcycles are as safe as or safer than cars.
C pointers are notoriously error prone, array bounds are not checked, there is no garbage collection, the preprocessor allows all kinds of mischief, and all sorts of dubious constructs are allowed, such as assignment within a conditional test, and don’t get me started on ++i and i++, etc., etc.
There is really no controversy about this. Check in to why the RTCA standard language for flight-critical systems on commercial airlines is Ada.
You are wrong on all accounts. We old farts are just better than those who walk with crutches.
Only about 2% of the software engineers are worth the powder it would take to blow them to hell?
No, I've written very large and complex C programs on a multitude of platforms.
You place the blame on C, but the blame actually belongs to the alleged programmers that are flummoxed by pointers, recursion, memory allocation and cleanup, or get confused by ++i and i++.
I went to the bug link you posted, and every 'bug' I looked at was due to programmer error or ignorance. Just curious - have you ever programmed professionally in C?
True, but in their defense we have to realize that they didn't have to learn the nuts and bolts like we did. I've worked with and trained younger guys, and get the eye-glaze-over when stressing that they should learn the low-level stuff, so that they can better understand what their wonder tools are insulating/isolating them from in their pursuit of writing bloated and buggy wares. The majority of the time it's a total waste of my time.
My formal training is in aeronautical engineering, not CS or programming. Being a nerd, however, I like to program my own research projects rather than direct some programmer as most of my peers do. I started off with Fortran back around 1986, then I used C for a couple of years, then I moved on to C++ for several years. About 8 years ago I started using Python, and about two years I switched to Scala.
I was using C and C++ to develop a research prototype of an integrated inertial/GPS navigation system for precision landing of aircraft. It involved advanced Kalman filtering, which in turn involves vectors and matrices (in the linear algebra sense). As far as I am concerned, C was not well suited at all for that environment. Yes, it can be made to do the job, but the result is not very elegant. C++ made the job a bit cleaner, but it was still ugly. I haven’t used C or C++ for probably around 15 years not, so I would imagine that these areas are better supported by now. I certainly hope so.
Scala took some getting used to, but I like it. It combines object-orientation with functional programming. The guys who are hard-core functional programmers are absolutely convinced that any other approach is crap. Functional programming has a lot to offer, but it really takes some getting used to. Pure functional programming (as in Haskell) allows no variables, for example. Try that some time.
Have you heard of the “anti-Java Professor”? He’s saying essentially the same thing you’re saying, but he’s an Ada guy. Check out this article:
Excerpt:
When I noticed that this list of the popular programming languages placed Java in the top position, I picked up the phone to call Robert Dewar. Several months back I interviewed Dewar, a professor emeritus of computer science at New York University, about Javas role in the college classroom.
What he said in that interview about Java in the classroom wasnt pretty.
In essence, he said that todays Java-savvy college grad is tomorrows pizza delivery man. Their skills are so easily outsourced that theyre heading for near-term obsolescence.
Dewar stresses that hes not against Java itself. But the fact that Java is taught as the core language in so many colleges is resulting in a weak field of computer science grads, he says.
The reason: students reliance on Javas libraries of pre-written code means they arent developing the deep programming skills necessary to make them invaluable. Colleges, alarmed by falling CS enrollment, have dumbed down the course requirements. Consequently, CS majors sail through a curriculum of Math Lite, earning a smiley-face on their papers for developing projects using pre-built libraries.
In the end, they graduate with a diploma whose value is questionable. They may be equipped for a dynamic career in fast food delivery, yet they are not fully prepared to compete against what is now a global field of rigorously educated software developers.
I will indeed look at that language. I rarely pass up a chance to look around. Are the compilers inexpensive? One advantage to C/C++ is the availability of good compilers ... for free even.
I appologize for my gruff demeanor. I am bottled up with a bunch of young programmers who don't know the nuts and bolts; and, they need to in this set-top box video project. They are irritating and disrespectful at times and have a poor work ethic.
Heavy-duty language are a poor choice for what I do, which is generally "under the hood" with operating systems, file systems, database internals, device drivers, and high-speed processes like video decoding. A machine just doesn't have time for "purity" in applications like video, and operating systems can't use the bloat, and I/O ports can't even be serviced by languages like ADA except through abstraction layers that are written in low-level languages.
The language wars are generally a product of different needs and capabilities. ADA has been proven to be effective in high reliability applications like avioncs; and, C is about the only reasonable way to go when writing operating systems, interrupt handlers, and device drivers.
I developed inertial navigation stuff when I worked with Sperry in 1973-1975. Our lab included Apollo's inertial platform. We used assembler and FORTRAN because that is all we had, and it had to fit in a computer with a 16-bit address space. We used PDP-11s and Honeywell 2116s (I think).
Even today microprocessor applications like I work on could never be accomplished with a "fat" language. It wouldn't fit into the machine and it wouldn't run fast enough.
I have worked on some very large scale projects, and those were done in assembler and FORTRAN. Later we lucked out and got 'C' and still worked on large projects. Bear in mind that the telephone network is built with 'C', and that is no small scale undertaking. The SS7s are frightful.
When people get used to languages that are strongly typed and permit limited methodologies for implementation, I think they get lazey and careless because they know the compiler will pull their fat out of the fire. I can understand that they'd be in for some unpleasant surprises in 'C'. Enforcement of "best practices" can help with languages like 'C', but that is never a replacement for experience.
Code well and prosper!. Steer clear of COBOL and RPG.
I know what you saying here exactly. I've been down that path many times. They freak out when I look at the assembler that a compiler generates when doing bug hunts.
I have had this very problem with our new hires, even from a prestigous school. They know Java and other "sandbox" languages, but are totally lost when it comes to bit-fiddling in a hurry for video stream processing. We had to let a fellow go who had only been with us six months because he couldn't adapt to coding that is close to the hardware. (I/O control registers, what's that? Use a pointer to access them, that's Heresy!)
Schools better be careful. Low-level work is still very much alive, and will probably save the American software work force.
A better analogy is to think of 'C' as the way to manufacture the car so that others can drive it.
Now you can be let in on what will give you one of those "AHA moments". I left aerospace programming because I didn't want to program in ADA. Young ADA was really bitchy and twitchy, and was forced into the domain by management that never wrote software. In the long run, ADA did pay off with reliability issues particularly when you factor in the truth that most software people are just mediocre. I was always a loose cannon that just couldn't go with the flow.
C is a little dangerous but so are high performance aircraft. Nothing runs as fast as a well designed C application. Low drag low overhead. If you want it to go faster write the assembler yourself.
Assember? Meh. Pure 0s and 1s for me.
Yet you can't indent your source code correctly. :)
Scala is free. It is an open-source project that originates with Prof. Martin Odersky at EFPL in Switzerland. It has a fairly vibrant user online user community.
As for Ada, I can sympathize with your aversion to it. As I said before, I have never actually used it for real work. Several years ago I tried to generate some interest in it at my organization (which uses mainly the usual C, C++, and Java), but nobody was interested. I’m actually afraid that Ada is dying a slow, painful death, and that’s a shame.
As for C, I’ll take your word for it that you can do a lot with it. However, I suggest you check out MISRA C (Motor Industry Software Reliability Assoc.). It is a “safe” subset of C. Why would they need that if standard is as good as you say it is? OK, in fairness, there is also a subset of Ada called Spark Ada that is intended for the really critical applications. It takes defensive programming to the limit. I’m no expert, but my guess is that MISRA C is about as “safe” as Ada, and Spark Ada takes it a level higher.
When you get regulatory bureaucracies involved (such as the FAA), C just does not cut it. Maybe that’s partly a bureaucratic problem, but I think it’s more than that.
\tthanks for pointing that out!
Disclaimer: Opinions posted on Free Republic are those of the individual posters and do not necessarily represent the opinion of Free Republic or its management. All materials posted herein are protected by copyright law and the exemption for fair use of copyrighted works.