+ 2
What is meant by char *message[10]={"hello", "world"};
Explain me how can we access these stringa by pointer and is it right statement in c language?
6 Respuestas
+ 12
Yes this statement is absolutely right. Message is char pointer which has 10bytes allocated. You can access hello as first member of the array, message[0].and world can be accessed as message[1]. Pointers are a challenging🙂
+ 1
How can we access them and print??
+ 1
What if i want print only 'h' character from that array??
+ 1
Thank you kaimi
You helped me alot
Thanks ☺☺
+ 1
One more question that *message [10] create normal array like message[10] and point to first character address??
+ 1
Its create 10 elements of character array but i store it 2d array elements how?