Machine-translated by Google. Questions are authored in English.
Top

Discussion

A pointer is

  • A.A keyword used to create variables
  • B.A variable that stores address of an instruction
  • C.A variable that stores address of other variable
  • D.All of the above

Answer: C

Correct answer: A variable that stores address of other variable

A pointer is a variable whose value is the address of another object. It has a type - the type of what it points to - which determines both how the pointed-to bytes are interpreted and how pointer arithmetic is scaled.

It is not a keyword; there is no pointer keyword in C, the asterisk in a declaration doing the work. And while a function pointer holds the address of code, the general definition is in terms of objects, so the option naming instructions describes a special case rather than the concept.

No comment is present. Be the first to comment.
Loading…

Post your comment

Please log in or register to post a comment.