ASKSAGE: Sage Q&A Forum - Individual question feedhttp://ask.sagemath.org/questions/Q&A Forum for SageenCopyright Sage, 2010. Some rights reserved under creative commons license.Mon, 04 Jan 2016 20:00:59 -0600comple data types pasing to/form sage fotm/to Chttp://ask.sagemath.org/question/9243/comple-data-types-pasing-toform-sage-fotmto-c/Hi.
Its easy to pass simple format data like double, int between sage and C programs.
int add_one(int i)
{
return i+1;
}
than
cdef extern from "file":
int add_one(int n)
but what if i want to pass list, tuples etc ( simple int * doesnt work ;) )
Does anybody know how to do that, or if thher is samoe manual (in this what i found are only simple examples )
Thank You in advance
Luke
Wed, 15 Aug 2012 23:11:01 -0500http://ask.sagemath.org/question/9243/comple-data-types-pasing-toform-sage-fotmto-c/Comment by vdelecroix for <p>Hi.
Its easy to pass simple format data like double, int between sage and C programs.</p>
<p>int add_one(int i)
{
return i+1;
}</p>
<p>than</p>
<p>cdef extern from "file":
int add_one(int n)</p>
<p>but what if i want to pass list, tuples etc ( simple int * doesnt work ;) )
Does anybody know how to do that, or if thher is samoe manual (in this what i found are only simple examples )
Thank You in advance
Luke</p>
http://ask.sagemath.org/question/9243/comple-data-types-pasing-toform-sage-fotmto-c/?comment=32071#post-id-32071you should have a look at the [Cython website](http://cython.org/)Mon, 04 Jan 2016 20:00:59 -0600http://ask.sagemath.org/question/9243/comple-data-types-pasing-toform-sage-fotmto-c/?comment=32071#post-id-32071