I am begining to understand the general idea of building and using a class. I have two diffferent begining c++ books that have enough information in them to make me realize I don't know enough. I would like to read a tutorial that completely excersises class building from "novice" to "semi-pro" to include strings and other types of variables not just integers. Is there a book dedicated to this topic or an extensive online tutorial? Thanks in advance and Happy new years.
I have been reading the cplusplus for the last few hours, I will read through the c++ faq next. Thanks I realy appreciate it.
I wonder how many years I will wander the streets of code until I realize where I am.
...*sigh*,What is the dif between a default contsructor and a constructor with parameters? They are both setting the rule of initialization of the new objects variables, right? So why would I declare more than one contstructor(I understand why the copy constructor is useful)?
You may want to make the same object in many different ways...
Originally Posted by Clayg
For example ..if you have a class called book, you may decide to construct objects using the book name and its author's name ....or if you have those details in a database, you can only take the..say.. isbn as the parameter and fill the object with the data obtained from the database.
The default constructor does not take any argument and it is needed to make a default object without any input from the program.
donyavhat, I am sure I miss spelled that. Thank you. I feel a bit clearer on the subject.