[GAP Forum] InputTextFile string input as Permutation?
Matan Ziv-Av
matan at svgalib.org
Sat Oct 12 15:13:08 BST 2013
On Sat, 12 Oct 2013, szgycs at szemerja-szasz.hu wrote:
> Permutation is not a string, but input from InputTextFile is a string. How
> can I transform a string to a permutation?
There is the function EvalString().
I have a function for this purpose:
ReadAsExpression:=function(n)
local f,e;
f:=InputTextFile(n);
e:=ReadAll(f);
CloseStream(f);
return EvalString(e);
end;
--
Matan Ziv-Av. matan at svgalib.org
More information about the Forum
mailing list