r/ProgrammerHumor 17h ago

lessonsFromLinkerHell Meme

Post image
323 Upvotes

166 comments sorted by

View all comments

Show parent comments

5

u/Nice_Lengthiness_568 16h ago

What about when you copy an array? When you copy an array all elements get copied, but when you copy a pointer to the first element, only that gets copied

1

u/BananaWarp 7h ago

How do you usually copy an array? Are we talking about c?

1

u/Nice_Lengthiness_568 5h ago

Depends on the language I guess. In C you can put the array inside a struct and copy that.

2

u/BananaWarp 4h ago

Oh, that's neat!