how do I store stdout value from system(); into a char* variable ?

e.g.

I have child process that executes system(); function , but the output is displayed on server (parent) tty,

I would...