Thread: is C appropriate for intro to computers?

  1. #121
    C++まいる!Cをこわせ!
    Join Date
    Oct 2007
    Location
    Inside my computer
    Posts
    24,654
    Doesn't a memory pool almost do the same, though?
    Quote Originally Posted by Adak View Post
    io.h certainly IS included in some modern compilers. It is no longer part of the standard for C, but it is nevertheless, included in the very latest Pelles C versions.
    Quote Originally Posted by Salem View Post
    You mean it's included as a crutch to help ancient programmers limp along without them having to relearn too much.

    Outside of your DOS world, your header file is meaningless.

  2. #122
    Cat without Hat CornedBee's Avatar
    Join Date
    Apr 2003
    Posts
    8,895
    Quote Originally Posted by Elysia View Post
    Doesn't a memory pool almost do the same, though?
    Yes, but it doesn't compact, so it only works if you really can release the whole pool at once.
    All the buzzt!
    CornedBee

    "There is not now, nor has there ever been, nor will there ever be, any programming language in which it is the least bit difficult to write bad code."
    - Flon's Law

  3. #123
    (?<!re)tired Mario F.'s Avatar
    Join Date
    May 2006
    Location
    Ireland
    Posts
    8,446
    Quote Originally Posted by Elysia View Post
    C# reminds me of typical stupid or lazy VB programmers, which there are a lot of out there.
    ... elysia, please shutup!
    Originally Posted by brewbuck:
    Reimplementing a large system in another language to get a 25% performance boost is nonsense. It would be cheaper to just get a computer which is 25% faster.

  4. #124
    Registered User
    Join Date
    Oct 2001
    Posts
    2,129
    Quote Originally Posted by Elysia View Post
    I don't want any cuddly, duddly things that tells me what I can do or can't
    Aha, so you can understand why somebody would like C over C++?

    You say that C++ would be be better for a beginner because the language is aimed at a specific platform. But why would that be an advantage? Wouldn't portability be an advantage, as well as being a common base for most other programming languages out there, even if they were not directly derived from C?
    Last edited by robwhit; 10-09-2008 at 12:15 PM.

  5. #125
    C++まいる!Cをこわせ!
    Join Date
    Oct 2007
    Location
    Inside my computer
    Posts
    24,654
    Quote Originally Posted by robwhit View Post
    Aha, so you can understand why somebody would like C over C++?
    Erm, C is the base of C++. C++ is not restricted in such a sense.

    You say that C++ would be be better for a beginner because the language is aimed at a specific platform. But why would that be an advantage? Wouldn't portability be an advantage, as well as being a common base for most other programming languages out there, even if they were not directly derived from C?
    It's better if it's aimed at the platform you're trying to develop, yes. Just as it's better to learn PHP or Perl rather than C/C++ if you're going to do server-side business. Not to say it can't be done, but it would be easier in php/pearl.
    And C++ is portable.
    Last edited by Elysia; 10-09-2008 at 12:59 PM.
    Quote Originally Posted by Adak View Post
    io.h certainly IS included in some modern compilers. It is no longer part of the standard for C, but it is nevertheless, included in the very latest Pelles C versions.
    Quote Originally Posted by Salem View Post
    You mean it's included as a crutch to help ancient programmers limp along without them having to relearn too much.

    Outside of your DOS world, your header file is meaningless.

  6. #126
    pronounced 'fib' FillYourBrain's Avatar
    Join Date
    Aug 2002
    Posts
    2,297
    Quote Originally Posted by Elysia View Post
    Erm, C is the base of C++. C++ is not restricted in such a sense.
    I would say that C++ added a level of type safety and the concept of privatization does in fact add a layer of coddling
    "You are stupid! You are stupid! Oh, and don't forget, you are STUPID!" - Dexter

  7. #127
    C++まいる!Cをこわせ!
    Join Date
    Oct 2007
    Location
    Inside my computer
    Posts
    24,654
    I don't agree.
    Quote Originally Posted by Adak View Post
    io.h certainly IS included in some modern compilers. It is no longer part of the standard for C, but it is nevertheless, included in the very latest Pelles C versions.
    Quote Originally Posted by Salem View Post
    You mean it's included as a crutch to help ancient programmers limp along without them having to relearn too much.

    Outside of your DOS world, your header file is meaningless.

  8. #128
    pronounced 'fib' FillYourBrain's Avatar
    Join Date
    Aug 2002
    Posts
    2,297
    tells you what you can and can't do
    "You are stupid! You are stupid! Oh, and don't forget, you are STUPID!" - Dexter

  9. #129
    pronounced 'fib' FillYourBrain's Avatar
    Join Date
    Aug 2002
    Posts
    2,297
    sorry chief, when the argument isn't logical you're going to have a hard time in here.
    "You are stupid! You are stupid! Oh, and don't forget, you are STUPID!" - Dexter

  10. #130
    C++まいる!Cをこわせ!
    Join Date
    Oct 2007
    Location
    Inside my computer
    Posts
    24,654
    I've noticed that. But I don't like, for example, having a "garbage collector" by default. That's the language forcing stuff upon me that I'd rather be without.
    I'll just call C++ "base line", where all features and things are (mostly) to my liking. Any added features that are forced upon me from there is not to my liking. It's "coddling."
    Quote Originally Posted by Adak View Post
    io.h certainly IS included in some modern compilers. It is no longer part of the standard for C, but it is nevertheless, included in the very latest Pelles C versions.
    Quote Originally Posted by Salem View Post
    You mean it's included as a crutch to help ancient programmers limp along without them having to relearn too much.

    Outside of your DOS world, your header file is meaningless.

  11. #131
    C++ Witch laserlight's Avatar
    Join Date
    Oct 2003
    Location
    Singapore
    Posts
    28,413
    Quote Originally Posted by Elysia
    Any added features that are forced upon me from there is not to my liking. It's "coddling."
    Not bondage and discipline?
    Quote Originally Posted by Bjarne Stroustrup (2000-10-14)
    I get maybe two dozen requests for help with some sort of programming or design problem every day. Most have more sense than to send me hundreds of lines of code. If they do, I ask them to find the smallest example that exhibits the problem and send me that. Mostly, they then find the error themselves. "Finding the smallest program that demonstrates the error" is a powerful debugging tool.
    Look up a C++ Reference and learn How To Ask Questions The Smart Way

  12. #132
    C++まいる!Cをこわせ!
    Join Date
    Oct 2007
    Location
    Inside my computer
    Posts
    24,654
    Yeah, I dislike B&D nature.
    Quote Originally Posted by Adak View Post
    io.h certainly IS included in some modern compilers. It is no longer part of the standard for C, but it is nevertheless, included in the very latest Pelles C versions.
    Quote Originally Posted by Salem View Post
    You mean it's included as a crutch to help ancient programmers limp along without them having to relearn too much.

    Outside of your DOS world, your header file is meaningless.

  13. #133
    Malum in se abachler's Avatar
    Join Date
    Apr 2007
    Posts
    3,195
    Quote Originally Posted by Elysia View Post
    Unfortunately, that's BAD code and bad practice. It should be used with a cast, preferable not done at all.
    Not in C it isn't. That was standard practice for decades before C++ required explicit type casting. As stated there are billions of lines of code 'out there' and people arent goign to spend the man hours to fix them all just so they can make the code C++ compliant when they dont use any C++ features. Your conhjecture that C isnt necessary is just plain short sighted, there is no defence for that argument. C is necessary for many practical reasons some of which have been laid out here.

  14. #134
    Registered User
    Join Date
    Oct 2001
    Posts
    2,129
    > Erm, C is the base of C++. C++ is not restricted in such a sense.

    So I should cast void pointers just because some C++ guy says?

    > It's better if it's aimed at the platform you're trying to develop, yes.

    C is aimed at the same platforms as C++, and more.

    > Just as it's better to learn PHP or Pearl

    Perl

    > rather than C/C++ if you're going to do server-side business. Not to say it can't be done, but it would be easier in php/pearl.

    I don't see the analogy.

    > And C++ is portable.

    Not as portable as C.
    Last edited by robwhit; 10-09-2008 at 01:01 PM.

  15. #135
    Cat without Hat CornedBee's Avatar
    Join Date
    Apr 2003
    Posts
    8,895
    C++ is by nature just as portable as C. It's less portable in practice because implementing compilers for it is so horribly complex.

    Frankly, it's a wonder that C++ enjoys as much success as it does, given how much effort goes into developing even an adequate C++ compiler. (I would contend that a "good" C++ compiler doesn't exist.)
    All the buzzt!
    CornedBee

    "There is not now, nor has there ever been, nor will there ever be, any programming language in which it is the least bit difficult to write bad code."
    - Flon's Law

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Numeric addresses for computers
    By great in forum C Programming
    Replies: 4
    Last Post: 08-23-2010, 11:53 AM
  2. Computers as authors
    By hk_mp5kpdw in forum A Brief History of Cprogramming.com
    Replies: 8
    Last Post: 11-22-2004, 08:55 PM
  3. Industrial vs home computers
    By nbo10 in forum Tech Board
    Replies: 10
    Last Post: 09-01-2004, 02:04 AM
  4. Matrix and vector operations on computers
    By DavidP in forum A Brief History of Cprogramming.com
    Replies: 11
    Last Post: 05-11-2004, 06:36 AM
  5. Love programming, hate computers
    By PJYelton in forum A Brief History of Cprogramming.com
    Replies: 15
    Last Post: 12-14-2002, 01:04 PM