>  >>> Short_Text="n=90; if n==90:print 'ok'"
>  >>> compound_lines = Short_Text.split(";")
>  >>> for line in compound_lines:
> ...   line = line.replace(":", ":\n    ")
> ...   print line
> ...
> n=90
>   if n==90:
>      print 'ok'

A variation of this will work if the input file isn't too
complicated.  I found this link with a Google of "c to python".  This
will give you an idea of how difficult it can be if you take into
account every possibility when converting.  You might check the web
first, since someone has probably already done what you want.  Good
luck.
http://www.catb.org/~esr/ctopy/

-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to