Question
struct point{
int x;
int y;
};
struct point origin,*pp;
main(){
pp=&origin;
printf("origin is(%d%d)
",(*pp).x,(*pp).y);
printf("origin is (%d%d)
",pp->x,pp->y);
}

Answers

Answer:
origin is(0,0)
origin is(0,0)
Explanation:
pp is a pointer to structure. we can access the elements of the structure either with arrow mark or with indirection operator.
Note:
Since structure point is globally declared x & y are initialized as zeroes   Your Comment






Search
Can you Answer!!
  • Q Tippani is famous folk dance of which states
  • Q Explain XML Schema-based aspect implementation
  • Q List three of your most important/proudest accomplishments.
  • Q Write the sequence of energy transformation taking place in the following places a) Nuclear power plant b) Thermal power plant c) Hydro power plant d) Tidal power plant e) Geo-thermal power plant
  • Q How to use nullable types in .Net?
  • Q Explain the terms Test Object Model, Test Object and Run-Time object?
  • Q Have you consider starting your own business?
  • Q Do you receive the attribute byte in the symbolic map?
  • Q What is Yarn?
  • Q What are the relational operations that can be performed on the database?
  • Q Mention what is the command syntax for inserting a document?