[try Beta version]
Not logged in

 
what is this dot?

Oct 16, 2014 at 1:14pm
example = str.emphatic();

what is this .?
is this a assigning function prototypes?
base on the = (assigning operator)
and emphatic(); (prototypes function)

Please help me understand
Oct 16, 2014 at 1:19pm
. is a member selection operator.
This means that whatever class str is an instance of, has member function emphatic

In your snipped example is assigned result of calling emphatic() member function on str object

http://www.learncpp.com/cpp-tutorial/612-references-vs-pointers-and-member-selection/
http://www.learncpp.com/cpp-tutorial/82-classes-and-class-members/
http://www.cplusplus.com/doc/tutorial/classes/
Oct 16, 2014 at 1:20pm
Thanks miinipaa
Topic archived. No new replies allowed.