running a C program with python script

M

M.N.A.Smadi

hi;

how can i do the following:
1- run a C program from a python script
2- pass that C program an argument
3- Read the out of the program into a buffer that is local to the script

thanks
m.smadi
 
T

Thomas Ganss

M.N.A.Smadi said:
hi;

how can i do the following:
1- run a C program from a python script
2- pass that C program an argument
3- Read the out of the program into a buffer that is local to the script

thanks
m.smadi
in addition to the other approaches:
if you want only a few specific lines of c you can inline the code.
google for scipy, weave, inline and python

HTH

thomas
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,007
Latest member
obedient dusk

Latest Threads

Top