running a C program with python script

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • M.N.A.Smadi

    #1

    running a C program with python script

    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
  • Thomas Ganss

    #2
    Re: running a C program with python script

    M.N.A.Smadi schrieb:[color=blue]
    > 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[/color]
    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

    Comment

    Working...