Executing a shell program with read and write availability

Hi there. I want to make a C++ program that executes a shell program with read and write availability. I've read about exec, shell_exec and popen. The most near one was popen but the problem is that I want simultaneous reading and writing. I've read about pipes and forks but it seems pretty complicated for me so I guess I'll need some help with that.

Any help is appreciated of course :)
I'm looking for help if someone can...
simultaneous reading and writing.

Of the same data?
No. Different one.
Then you'll need to fork a new process
Topic archived. No new replies allowed.