+ 5

Can a function return a pointer variable

like return *p

19th Nov 2016, 4:01 PM
Tarun Sharma
Tarun Sharma - avatar
5 Answers
+ 2
Yup! Check out this thread: https://www.sololearn.com/Discuss/101263/how-to-return-an-array It's pretty much the same thing since arrays are just pointers.
19th Nov 2016, 4:04 PM
scott johnson
scott johnson - avatar
+ 1
yes! that's what we do while creating linked lists, stacks and queues!
21st Nov 2016, 9:24 AM
Chitransh Vishwakarma
Chitransh Vishwakarma - avatar
+ 1
yes
10th Jan 2017, 8:42 AM
Shivam Upadhyay
Shivam Upadhyay - avatar
0
yes it's incredibly useful and helpful!
5th Jan 2017, 5:21 AM
theMike97_
theMike97_ - avatar
0
Creo que sĂ­ amigo.
11th Jan 2017, 12:49 AM
Juan Pablo Yañez
Juan Pablo Yañez - avatar