Thread: cmd close's too soon...

  1. #16
    Programmer
    Join Date
    Nov 2005
    Location
    Canada
    Posts
    33
    Well I'll stick to cin.get() for now, "getch();" gives me errors so... Well I must go to work so I cannot read up about it now, thanks anyways!
    (Expert Visual Basic Programmer)
    (Newbie C/C++ Programmer)

  2. #17
    Deprecated Dae's Avatar
    Join Date
    Oct 2004
    Location
    Canada
    Posts
    1,034
    Quote Originally Posted by ElastoManiac
    This is much simplier, you just press enter at the end of program - and thats it.
    Code:
    #include <conio.h>
    
    // at the end
    cout<<"Press a key to continue...";
    getch();
    Thats the same as:

    Code:
    #include <iostream>
    using namespace std;
    // at the end
    cout<<"Press a key to continue...";
    cin.ignore();
    cin.get();
    Accept you wont have to include some wierd conio.h C header file.

    Alright, I didn't read all of what you said since I gota go in a few minutes. I got a lot...
    Cool. However that book is about C++, MFC, and VC++ (which is a compiler you arent using). Not only that but its 1100 pages longer than it needs to be for just learning C++ concepts, and has a rating of 3.5 at amazon. I would recommend (especially if you have it) Accelerated C++ as its more appropriate when you're trying to learn new concepts, and has a rating of 5. (well its 4.5, but thats because 1 out of 100 people voted 4 instead of 5).
    Last edited by Dae; 11-26-2005 at 04:11 PM.
    Warning: Have doubt in anything I post.

    GCC 4.5, Boost 1.40, Code::Blocks 8.02, Ubuntu 9.10 010001000110000101100101

  3. #18
    Programmer
    Join Date
    Nov 2005
    Location
    Canada
    Posts
    33
    Yep I use VC++ 6 but thats rare of me! :O Well I'll tell you my book list when I get back, well bye!
    (Expert Visual Basic Programmer)
    (Newbie C/C++ Programmer)

  4. #19
    Registered User
    Join Date
    Sep 2001
    Posts
    4,912
    This is much simplier, you just press enter at the end of program - and thats it.
    conio.h is not a standard header file from either the C or C++ libraries - not everybody has it.

  5. #20
    Programmer
    Join Date
    Nov 2005
    Location
    Canada
    Posts
    33
    Alright I looked through some of my books, here is a small list.

    Accelerated C++ (I found out I had it! )
    Visual C++ 101 Tips
    C Programming How-To
    The C Programming Language
    Sams: C++ Primer Plus (2005 EDITION)
    Sams: Tricks Of The Windows Game Programming Gurus
    C++ Programming with the Standard Template Library (SDL Tutorial and Refrence Book)
    Beginning C++ Game Programming
    Algorithms Data Structures and Problem Solving with C++ (Don't ask me why I even have this)
    Data Structures and Algorithms with Object-Oriented Design Patterns in C++ (Another one of those don't ask me why I even have)
    Advanced 3D Game Programming using Direct X 9.0
    C++ Weekend Crash Course
    Programming Role Playing Games with Direct X 8.0
    Masturing Visual C++ 6 (May never read)
    Visual C++ 6 for Dummies (May never read)
    Practical C++ Programming
    Game Programming All In One
    Sams: Teach Yourself Visual C++ In 24 Hours (May never read)
    Strategy Game Programming With Directx 9.0
    Sams: Teach Yourself Visual C++ 6 in 21 days (May never read)
    Sams: Tricks of the 3D Game Programming Gurus
    Sams: Visual C++ 4 Unleashed (Very old, and never will read)
    Visual C++ 6 Unleshed - MFC Programming
    Visual C++ and MFC Programming
    Wrox: Professional C++

    Well thats a big list, took some time to type out! Are any of these good for learning at all? I haven't looked through most of them just a few game programming ones. I'll read that Accelerated C++ as soon as possible though!

    Any other books I should have?
    (Expert Visual Basic Programmer)
    (Newbie C/C++ Programmer)

  6. #21
    Deprecated Dae's Avatar
    Join Date
    Oct 2004
    Location
    Canada
    Posts
    1,034
    Accelerated C++ and Sams: C++ Primer Plus together are a lethal combo to learn C++, and the only other one to learn C++ that you might need is The C++ Programming Language (Special 3rd Edition) by the creator of C++, Bjarne himself, as a reference of the advanced topics.

    Tricks of the 3D Game Programming Gurus looks alright, but I personally wouldn't read anything by LaMothe.

    Why aren't you sure why you have books on Data Structures and Design Patterns? those are huge topics in game programming. Data Structures and Algorithms with Object-Oriented Design Patterns in C++, looks to be a great book if you're in college studying for in CS, and is on my to-read list. But Algorithms Data Structures and Problem Solving with C++ isn't holding much of a rating.

    I don't know what you're shooting for, but the only ones out of that list I would read are the two C++ books, and possibly the 3d game programming one. Then after that I would go for.. two on data structures, one on the STL, and one on DirectX or openGL.

    I write down all the good books that I would read if I needed to learn the material. Its pretty much in categories, and in order of which one I'd read first. I'd look up any book you want to read on amazon.com first, at least.

    Accelerated C++: Practical Programming by Example
    by Andrew Koenig

    C++ Primer Plus, //(5th Edition),
    by Stephen Prata

    C++ Primer Answer Book, //(No Edition)
    by Clovis L. Tondo

    The C++ Programming Language, //(Special 3rd Edition)
    by Bjarne Stroustrup ISBN 0-201-70073-5

    C++ Solutions: Companion to the C++ Programming Language //(3rd Edition),
    by David Vandevoorde

    Exceptional C++ Style: 40 New Engineering Puzzles, Programming Problems, and Solutions
    by Herb Sutter (Author)

    More Exceptional C++: 40 New Engineering Puzzles, Programming Problems, and Solutions
    by Herb Sutter (Author)

    C++ Coding Standards : 101 Rules, Guidelines, and Best Practices (C++ in Depth Series) (Paperback)
    by Herb Sutter, Andrei Alexandrescu

    Data Structures and Algorithms in C++, Second Edition (Hardcover) //(2nd Edition)
    by Adam Drozdek

    Algorithms in C++, Parts 1-4: Fundamentals, Data Structure, Sorting, Searching, //(3rd Edition)
    by Robert Sedgewick

    Bundle of Algorithms in C++, Parts 1-5: Fundamentals, Data Structures, Sorting, Searching, and Graph Algorithms (3rd Edition) (Paperback)
    by Robert Sedgewick

    Generic Programming and the STL: Using and Extending the C++ Standard Template Library, //(No Edition)
    by Matthew H. Austern

    Pattern Hatching : Design Patterns Applied (Software Patterns Series) (Paperback)
    by John M. Vlissides

    Design Patterns: Elements of Reusable Object-Oriented Software (Addison-Wesley Professional Computing Series) (Hardcover)
    by Erich Gamma, Richard Helm, Ralph Johnson, John Vlissides

    UML and the Unified Process: Practical Object-Oriented Analysis and Design (Paperback)
    by Jim Arlow, Ila Neustadt

    Game Programming Gems 5
    by Kim Pallister (Editor)

    Essential Mathematics for Games and Interactive Applications : A Programmer's Guide (The Morgan Kaufmann Series in Interactive 3D Technology) (Hardcover)
    by James M. Van Verth, Lars M. Bishop

    read when into making an RPG:
    Swords & Circuitry: A Designer's Guide to Computer Role-Playing Games (Game Development) //(1st Edition)
    by Neal Hallford, Jana Hallford

    read when know calculus well:
    Mathematics for 3D Game Programming and Computer Graphics, Second Edition (Game Development Series) (Hardcover)
    by Eric Lengyel

    advanced c++ oriented:
    Design Patterns (Hardcover) //(No Edition)
    by Erich Gamma

    The C++ Standard Library: A Tutorial and Reference //(No Edition)
    by Nicolai M. Josuttis

    An Introduction to Data Structures and Algorithms (Hardcover)
    by J.A. Storer, John C. Cherniavsky

    advanced math oriented:
    Discrete Mathematics: For New Technology (Paperback)
    by Rowan Garnier, John Taylor

    Data Structures and Algorithms with Object-Oriented Design Patterns in C++ (Hardcover) //(1st Edition)
    by Bruno R. Preiss

    read after learning DirectX or OpenGL:
    3D Math Primer for Graphics and Game Development //(1st edition)
    by Fletcher Dunn

    Core Techniques and Algorithms in Game Programming
    by Daniel Sanchez-Crespo Dalmau

    3D Game Engine Architecture : Engineering Real-Time Applications with Wild Magic (The Morgan Kaufmann Series in Interactive 3D Technology) (Hardcover)
    by David H. Eberly "My book 3D Game Engine Design (3DGED) was written to explain the high-level details that arose in the development of the real-time 3D game engine..." (more)

    GUI: //be familiar with GLUT/OpenGL programming first
    Programming with Qt //(2nd Edition)
    by Matthias Kalle Dalheimer

    C++ GUI Programming with Qt 3 (Bruce Peren's Open Source) //(1st Edition)
    by Jasmin Blanchette, Mark Summerfield

    read after all else:
    GPU Gems: Programming Techniques, Tips, and Tricks for Real-Time Graphics (Hardcover)
    by Randima Fernando

    read last:
    The Pragmatic Programmer: From Journeyman to Master (Paperback)
    by Andrew Hunt, David Thomas
    I still haven't looked up a good book to learn DirectX.
    Last edited by Dae; 11-27-2005 at 08:49 PM.
    Warning: Have doubt in anything I post.

    GCC 4.5, Boost 1.40, Code::Blocks 8.02, Ubuntu 9.10 010001000110000101100101

  7. #22
    Programmer
    Join Date
    Nov 2005
    Location
    Canada
    Posts
    33
    Alright, thanks! I'm learning a lot from Accelerated C++: Practical Programming by Example, I'll be sure to buy some more books soon, off your list if course. The more the better!
    (Expert Visual Basic Programmer)
    (Newbie C/C++ Programmer)

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Replies: 23
    Last Post: 04-20-2009, 07:35 AM
  2. OOP Question DB Access Wrapper Classes
    By digioz in forum C# Programming
    Replies: 2
    Last Post: 09-07-2008, 04:30 PM
  3. Error running program in cmd - cygwin.dll missing -
    By JFonseka in forum C Programming
    Replies: 5
    Last Post: 08-27-2007, 12:12 PM
  4. Program closes when startup form closes
    By dcboy in forum C# Programming
    Replies: 1
    Last Post: 07-01-2006, 02:40 AM
  5. Little help with CMD
    By robid1 in forum C Programming
    Replies: 2
    Last Post: 02-23-2003, 04:09 AM