Skip to content

Instantly share code, notes, and snippets.

@hlprmnky
Created February 25, 2016 04:59
Show Gist options
  • Select an option

  • Save hlprmnky/b2a67003b22be21013e2 to your computer and use it in GitHub Desktop.

Select an option

Save hlprmnky/b2a67003b22be21013e2 to your computer and use it in GitHub Desktop.
import subprocess as sp
proc = sp.Popen(['/usr/local/bin/node', '-p'], stdin=sp.PIPE, stdout=sp.PIPE)
(stdout, stderr) = proc.communicate('4 * 1\n')
print(stdout)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment