Women in Technology

Hear us Roar

  What I Hate About Your Programming Language
Subject:   Why C sucks...
Date:   2003-05-14 02:35:00
From:   anonymous2
I recently wrote another article here, before this one:


Main Topics Oldest First

Showing messages 1 through 6 of 6.

  • Why C sucks...
    2004-03-18 07:15:41  kuashio [View]

    My comment is very similar to all others'

    I think you are VERY wrong about "Why C sucks"... Actually, I think that your article has only one thing wrong: the title. It should be titled: "Why C Rules..."

    And what's all that about newbies? (a.k.a. lamers)
    C does not become newbies! Period.

    All the things you mention in your bad-language-based article as being "bad" about C, are actually the things I love about it.

    Boolean variables force you to write more code, resulting in larger and slower programs. Is it that hard to believe that "false", "NULL", '\0', etc. all equal ZERO in C?

    And don't mess with the ?: ternary operator. Even Visual BASIC (a programming language intended for retards) has a function called "iif()" that does the same thing (sort of).

    That's about it. Thanks for reading.
  • Why C sucks...
    2003-05-15 02:15:13  anonymous2 [View]

    As many others said, you have some points, but these are only the reasons why C is GREAT for what it is. It is a low level language. Who said that people who aren't programming kernels, (and other things .. but you get the point), should learn C. #includes are part of the isolation compilation/linking/relocation part of a compiled laguage. It is necessary to have reffereces to things in other files such as function declarations or external variables. Since you must declare something before you can use it, headers are often used for prototypes. This type of use leads to things that can be thought of as bad style for new programmers as you have mentioned. Either way my point is that it is for the purpose of fast compilation that it is structured in such a way so that multiple passes don't have to be made through code and refferences to external entities are intentional and not a spelling error. A computer allows processes to have basically a stack and a heap, and C is the simplest way to directly access these in the way that it really is being done by processor instructions. I agree that other languages like Java for example give you a larger layer of abstraction in how it handles things, but that is why beginners should use Java and not C. C is the simplest, most direct control of the basic computer architecture while Java is some nice fluffy language that is as benign as a fluffy bunny. So my point is that people who don't understand what C is controlling should not use it. C is great the way it is.
  • Why C sucks...
    2003-05-14 16:45:05  anonymous2 [View]

    I agree with some of the points in the article, but I think most of the complaints fall under the category of "How C is Misused," rather than "How C sucks." C was designed to be a portable assembly language in which to rewrite Unix so that it would be portable to more than one machine. It has obviously succeeded in that capacity. C was not intended to be a general application language, a teaching language, or the parent of a high level, general purpose language (C++). I don't consider it a failure of C that it hasn't worked out well in those capacities, but rather a failure of its users to realize when a different language would be better.
  • Why C sucks...
    2003-05-14 12:25:14  anonymous2 [View]

    your "for loop" example is incorrect. the way you have it written is the way the zero-impaired newbies you talk about might think it works:

    i = 0;
    while (i<10) {
    /* some other stuff */

    in fact, the statement:
    for (i=0; i<10; i++) { ... }
    actually translates to:

    i = 0;
    while (i<10) {
    /* some other stuff */

    (increments i AFTER it does the work, not before)
  • Give me C syntax or give me death!
    2003-05-14 10:59:47  anonymous2 [View]

    Some good points, but the funny thing is: If I were to write an article on why C *doesn't* suck, I'd include quite a few of the same issues you did.
  • Why C sucks...
    2003-05-14 07:59:25  anonymous2 [View]

    I enjoyed your article on why C sucks (and what would suck less). I agree with many of the issues raised there. However, I would like to point out one area on which I am in strong disagreement:

    We should not blame the language if the newbie programmer faces difficulty with its constructs. It is one thing to say a language has readability or even learnability issues. It is quite another to say that "it would not be clear to the newbie why this would work/fail". Someone who lacks full knowledge of a language has NO business doing serious work in it.

    But all that aside, I understand where you're coming from. I am fluent in C and know all of its constructs, but I still have great difficult with actual examples of it (including my own).

    Btw, IMHO, I share your sentiments about Pascal/Delphi, but I would really appreciate it if they changed "begin" and "end" to "{" and "}", respectively.