+ 8

Any one knows what (data_type**(any_name)) means?I've basic concept of pointers..but this one seems a little odd...?

I can tell that a pointer is used to store memory address of another location in memory and using *(dereference operator) we can access the value stored in the memory address pointer contains...but the above syntax is a little bit odd..maybe there's something silly i'm missing...?

1st Jan 2018, 5:26 PM
Cyberspace Cyborg
Cyberspace Cyborg - avatar
5 ответов
+ 4
double ** mean you have created a double pointer that points to another double pointer that finally points to a double value... so it's like a chain.. you can extend it to double *** which means that you've created a 3rd pointer that points to the 2nd pointer that points to the 1st pointer that points to double value... and so on. p2 --> p1 --> value p3 --> p2 --> p1 --> value we usually use this way when we want to keep our 1st pointer unchanged... so we send the 2nd pointer instead and if it changed this will not affect the 1st pointer.. hope that was clear!
27th Jan 2018, 3:43 PM
Silver Key
Silver Key - avatar
+ 3
pointer to ponter
28th Jan 2018, 6:02 AM
ijhar
ijhar - avatar
+ 2
Thanks for that :)
1st Jan 2018, 6:40 PM
Cyberspace Cyborg
Cyberspace Cyborg - avatar
0
I don't know but I would guess it is an attempt to change the data type.
1st Jan 2018, 5:32 PM
josh mizzi
josh mizzi - avatar