Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
explain this operator -> which is use as headnode->stnext(null);
#1
To access the data members or functions of a class with the help of an object, we have two operators: dot operator ( . ) and arrow operator ( -> )

When object is not a pointer, like we made List object as List myList; , we use dot operator to access functions of List class, like myList.add(2);
When object is of type pointer, like Node * currentNode; we use arrow operator to access functions of Node class, like currnetNode->getNext();

0300-9520262
Get solution in 24 hour
|cpmputer & internetConfusedmileys81:[SIZE="4"][SIZE="3"]....[/SIZE][/SIZE]
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  Dangling Pointers Explain in C++ Vuhelper 0 7,270 05-31-2012, 01:52 AM
Last Post: Vuhelper
  Explain the difference b/w Null Pointer and Null Nodes? C++ 2012 Vuhelper 0 1,951 01-06-2012, 12:24 AM
Last Post: Vuhelper
  Overloaded >> operator not reading more than first line from data file in c++ 2011 Vuhelper 0 915 07-23-2011, 05:38 PM
Last Post: Vuhelper
  Consitional Operator in C++ July 2011 Vuhelper 0 843 07-12-2011, 11:02 PM
Last Post: Vuhelper
  arithmetical operator in c++ may 2011 Vuhelper 0 1,724 05-29-2011, 06:18 PM
Last Post: Vuhelper
  explain error handling in c++ 2011 saneha 0 2,357 05-02-2011, 06:52 PM
Last Post: saneha
  cascading operator overloading in c++ 2011 saneha 1 2,966 05-02-2011, 05:08 PM
Last Post: Vuhelper
  explain the copy constructor, shallow copy, and deep copy with examples and c++ code saneha 1 5,439 05-02-2011, 06:45 AM
Last Post: Vuhelper
  is the dot operator connect the class object and a member of that class? saneha 1 2,741 05-02-2011, 06:41 AM
Last Post: Vuhelper
  how the information hidden within an object can be assessed either dot operator conne saneha 1 2,764 05-02-2011, 06:37 AM
Last Post: Vuhelper

Forum Jump:


Users browsing this thread: 1 Guest(s)