Passing integer value in C module
i would like to pass the integer value in the module. following is my C code;
int i;
SYMBOL di;
di = symbol_CreateStandardVariable();
and the module is
t = term_Create(Door,list_Cons(term_Cre开发者_C百科ate(di, list_Nil()), list_List(term_Create(di, list_Nil()))));
is there any way so that i can pass the value like d1, d2 , d3 ... iteratively and pass in the module in place of di?
Thanks in advance.
If I understand your question correctly, you are asking how to iterate the variables d1
, d2
, d3
in sequence, based on the name of the variable and the value of i
.
So, while you cannot do that directly, it sounds like what you are looking for is a for loop that loops over an array.
精彩评论