R
Ravi
I can define functions within the class body as well as outside by
using the scope operator. Which is the better place to do so? In Java
we do it it within the class body so the former method seems more
logical to me.
Another related question is that experienced C++ programmers use
separate header files for class definition and method definitions.
What will be the loss if I make class definitions and function
definition in the same file and include it in other files?
I am an experienced C programmer who has a little experience of Java
and started learning C++, so many concepts are new to me.
using the scope operator. Which is the better place to do so? In Java
we do it it within the class body so the former method seems more
logical to me.
Another related question is that experienced C++ programmers use
separate header files for class definition and method definitions.
What will be the loss if I make class definitions and function
definition in the same file and include it in other files?
I am an experienced C programmer who has a little experience of Java
and started learning C++, so many concepts are new to me.