import subprocess child = subprocess.Popen("perl", stdin=subprocess.PIPE) child.stdin.write('print "Python -> Perl\n"') child.stdin.close() child.wait()