Thread: how to make a if a char equals something

  1. #16
    Registered User
    Join Date
    Aug 2003
    Posts
    1,218
    It may be C++ but it never hurts to know about C-Style strings and his question was on C-style strings.

    I agree C++ strings are what should be used but that doesnt migate the fact that C-style strings are still good to learn and most books teach them before C++ strings.

  2. #17
    C++まいる!Cをこわせ!
    Join Date
    Oct 2007
    Location
    Inside my computer
    Posts
    24,654
    I sincerely disagree. A C++ dev should know C++ strings and largely ignore C-style strings. Most are better of not knowing them.
    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.

  3. #18
    Registered User
    Join Date
    Aug 2003
    Posts
    1,218
    Well i guess we will just have to settle with agreeing that we disagree

  4. #19
    C++まいる!Cをこわせ!
    Join Date
    Oct 2007
    Location
    Inside my computer
    Posts
    24,654
    And btw, I don't like the approach of learning C-stuff before C++ stuff. I believe all those thousands of books out there use the wrong approach.
    The one book I do like is Accelerated C++. It focuses on writing C++ applications without forcing the user to learn C stuff before. It only teaches them (and a narrow subset) in a practical manner to implement higher C++ functionality and encapsulation.
    Gets you started on C++ right away.
    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.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Conversion Char To Char * Problem
    By ltanusaputra in forum Windows Programming
    Replies: 3
    Last Post: 03-01-2008, 02:06 PM
  2. String sorthing, file opening and saving.
    By j0hnb in forum C Programming
    Replies: 9
    Last Post: 01-23-2003, 01:18 AM
  3. simulate Grep command in Unix using C
    By laxmi in forum C Programming
    Replies: 6
    Last Post: 05-10-2002, 04:10 PM
  4. Strings are V important...
    By NANO in forum C++ Programming
    Replies: 15
    Last Post: 04-14-2002, 11:57 AM
  5. errors in class(urgent )
    By ayesha in forum C++ Programming
    Replies: 1
    Last Post: 11-10-2001, 10:14 PM