• Courses
  • Tutorials
  • DSA
  • Data Science
  • Web Tech
July 07, 2022 |80 Views

Pointer to an Array PART - 2

  Share   Like
Description
Discussion

In this program, we have a pointer ptr that points to the 0th element of the array. Similarly, we can also declare a pointer that can point to whole array instead of only one element of the array. This pointer is useful when talking about multidimensional arrays. 
Syntax:  

data_type (*var_name)[size_of_array];
Example:

int (*ptr)[10];