Purpose of a pointer to a pointer

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • dissectcode
    New Member
    • Jul 2008
    • 66

    Purpose of a pointer to a pointer

    Hello - I am new to this...In C, what the heck is the purpose of having a "pointer to a pointer"?
  • oler1s
    Recognized Expert Contributor
    • Aug 2007
    • 671

    #2
    Worth searching first.

    But two common reasons you'll run into pointer to pointers is that you need to deal with arrays of arrays, and you need to pass a pointer into a function and modify that pointer directly.

    Comment

    • JosAH
      Recognized Expert MVP
      • Mar 2007
      • 11453

      #3
      Maybe the OP hadn't noticed it but the second argument of the main function is
      a pointer to an entire array of pointers.

      kind regards,

      Jos

      Comment

      Working...