Arrow (->) Operator : Accessing Structure members using Pointer

Use : 
  1. When Structure elements are to accessed by using Pointer then we use Arrow Operator.
  2. Here Structure variable is of Type Pointer.
Example :
struct student
{
  char name[20],
  int roll;
}*ptr;
How to Access Structure Members :
  1. roll number is accessed using  ptr->roll
  2. Name can be accessed using  ptr->name
Live Example :  Click Here for Live Example


Bookmark & Share


Tags / Keywords : | , , ,

0 comments

Post a Comment

Your Feedback :This is Growing Site and Your Feedback is important for Us to improve the Site performance & Quality of Content.Feel Free to contact and Please Provide Name & Contact Email