How to handle PERMUTATIONobjectsPermutationsHow to change a PERMUTATIONobjectHow to build a PERMUTATIONobject

How to build a PERMUTATIONobject

Here comes the routine that allows to build a PERMUTATIONobject: We provide an example which reads with the standard C-function scanf an INT variable from stdin, and generates a permutation of the entered length, the entries of the list, representing the permutation are empty objects ( =# ):
#include "def.h"
#include "macro.h"
main()
{
OP a;
INT l;
anfang();
a = callocobject();
scanf("% ld",& l);
m_il_p(l,a);
println(a);
freeall(a);
ende();
}

harald.fripertinger@kfunigraz.ac.at,
last changed: November 19, 2001

How to handle PERMUTATIONobjectsPermutationsHow to change a PERMUTATIONobjectHow to build a PERMUTATIONobject