S
S
sddvxd2018-12-12 16:40:21
C++ / C#
sddvxd, 2018-12-12 16:40:21

I correctly understood the relationship between a pointer to a pointer and a two-dimensional array?

Good afternoon! In Paint, I drew a diagram in which I expressed my understanding of the structure of a two-dimensional array. Can you please tell me how accurate it is?
5c110fc2bb427639760751.png

Answer the question

In order to leave comments, you need to log in

1 answer(s)
J
jcmvbkbc, 2018-12-12
@sddvxd

No, I misunderstood. int[2][2] != int **.
But the arrangement of the elements drew the correct one.
The idea is that a two-dimensional array is an array of arrays. Those. int [2][2] == int ([2])[2].
A pointer to a pointer is a completely different story.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question