Topic: RFI: C++ Strings
Author: brahms@mindspring.com (Stan Brown)
Date: 1999/04/25 Raw View
[This followup was also e-mailed to the cited author for speed -- please
follow up in the newsgroup.]
Dixitque Goran-LongAxe@email.msn.com (The Dwarven Assassin) in
comp.std.c++:
>Could someone out there help me?
>
>I am trying to teach myself C++ but I am having trouble finding a decent
>tutorial book/website etc. that explains strings in a clear precise way.
>Could someone direct me to a good book (available in the
>UK) or a web site that could give me the information I require.
Lippman & Lajoie /C++ Primer/ (third edition) uses strings naturally
throughout. Be careful though: there are some horrendous errors in the
code, things like
string badfile("The file "code.txt" could not be opened.");
That's from memory, but you get the idea -- code that obviously they
never ran through *any* compiler.
Apart from that., I think it's a decent introduction. I assume it's
available in the UK, but you can check with your bookseller or library.
Be sure you get the third edition -- it's the only one that is up to date
with the standard.
As for Web documentation, here's what's in my bookmarks file:
http://www.pgroup.com/ppro_docs/pgC++_lib/stdlibug/str_8586.htm
http://www.dinkumware.com/htm_cpl/string2.html
--
Stan Brown, Oak Road Systems, Cleveland, Ohio, USA
http://www.mindspring.com/~brahms/
My reply address is correct as is. The courtesy of providing a correct
reply address is more important to me than time spent deleting spam.
---
[ comp.std.c++ is moderated. To submit articles, try just posting with ]
[ your news-reader. If that fails, use mailto:std-c++@ncar.ucar.edu ]
[ --- Please see the FAQ before posting. --- ]
[ FAQ: http://reality.sgi.com/austern_mti/std-c++/faq.html ]
Author: Francis Glassborow <francis@robinton.demon.co.uk>
Date: 1999/04/26 Raw View
In article <098a70340121949CPIMSSMTPU07@email.msn.com>, The Dwarven
Assassin <Goran-LongAxe@email.msn.com> writes
>Although I have many years of programming experience in BASIC, COBOL, and
>recently (this week) Visual Basic 6.0 I cannot get my head around C++
>strings.
Do you really mean C++ strings or are the books you are reading using C
ones?
to distinguish:
Do programs include
#include <string>
using namespace std;
(which indicate C++ strings)
or possibly
#include <string.h>
which would suggest C style strings (definitely clumsy and difficult)
Do strings get declared as
char message[100]
// just an example, the key feature is the use of char
(this declares a C-style string)
or as
string message;
(whereas this declares a C++ version)
For books check the book reviews at www.accu.org
Francis Glassborow Journal Editor, Association of C & C++ Users
64 Southfield Rd
Oxford OX4 1PA +44(0)1865 246490
All opinions are mine and do not represent those of any organisation
---
[ comp.std.c++ is moderated. To submit articles, try just posting with ]
[ your news-reader. If that fails, use mailto:std-c++@ncar.ucar.edu ]
[ --- Please see the FAQ before posting. --- ]
[ FAQ: http://reality.sgi.com/austern_mti/std-c++/faq.html ]
Author: "The Dwarven Assassin" <Goran-LongAxe@email.msn.com>
Date: 1999/04/25 Raw View
Could someone out there help me?
I am trying to teach myself C++ but I am having trouble finding a decent
tutorial book/website etc. that explains strings in a clear precise way.
I purchased 'Learn C++ in 21 days (3rd edition)' by SAMS and although it
explained what strings are, it didn't show much of string manipulation, and
comparison etc. Could someone direct me to a good book (available in the
UK) or a web site that could give me the information I require.
Although I have many years of programming experience in BASIC, COBOL, and
recently (this week) Visual Basic 6.0 I cannot get my head around C++
strings.
I use MS Visual C++ 6.0.
Thankyou in advance.
The Dwarven Assassin.
---
[ comp.std.c++ is moderated. To submit articles, try just posting with ]
[ your news-reader. If that fails, use mailto:std-c++@ncar.ucar.edu ]
[ --- Please see the FAQ before posting. --- ]
[ FAQ: http://reality.sgi.com/austern_mti/std-c++/faq.html ]