[prog]More questions on my first attempt at C++
Sue Stones
suzo at bigpond.net.au
Mon Apr 14 22:00:03 EST 2003
On Mon, 14 Apr 2003 09:50 pm, Sue Stones wrote:
> I have been looking at C++ for the last 2 days and trying to sort out the
> very basics of its approach to object oriented programing. I have a few
> questions I hope that someone can answer.
>
> 1) I am trying to sort out how to use the string class; when I declare a
> variable of this class is it best done by declaring it std::string? ie
> with the scope name. Is it used in the same way as the return type for
> a function?
>
> 2) How do i put numbers (eg int double) into a string object?
>
> 3) In construcing my own class when do I need a destructor? What do I need
> to put into it?
>
> sue
Is there a convention for naming writters and readers? ie functions to set
(or read) the value of a private variable within an object. eg Java tends to
call them setSomething and getSomething.
Are there any basic differences in writing a makefile for C++ than for C?
I know that many companies have strong conventions about makefiles. Do you
have any comments on good makefiles?
sue
More information about the Programming
mailing list