Is this a pointer to a pointer of the start of an array?

  • &dataArray[0] is of type char *. That is a pointer to char.
  • dataArray is of type char[10]
  • &dataArray will be of type char (*)[10]. That is a pointer-to-array.

Apart from that, the value will be same, i.e., they point to the same address but their types need not be compatible.

None of them is a pointer-to-pointer here. They are just pointer with different types.

Note: Because the array decaying property, char [100] will decay to a char *, for example, when passed as an agument of a function.

Leave a Comment