Dear Rohit, Put your commands in a plain text file, using a text editor, then read the file using GAP's Read command. For example, if you name the file MyLoop.g, then in GAP enter the command
gap> Read("MyLoop.g"); Make sure the file is in the same directory from which you launched GAP, or else use the absolute path name. -William On Thu, Jan 12, 2012 at 9:36 PM, (((1/f))) <fade...@gmail.com> wrote: > Dear Forum, > > I now know how to write a normal for loop to generate some kind of data, > such as: > > *>for i in [1..30] do;* > *>Print(IsPrime(i*10+9), ":", i*10+9, "\n");* > *>od;* > > But after running this I just want to play with minor variations on the > theme instead of > having to type out the whole command all over again. How can I do this? > I'm sure this is simple, but I'm new to this software. Kindly help. > > regards, > - Rohit Gupta > _______________________________________________ > Forum mailing list > Forum@mail.gap-system.org > http://mail.gap-system.org/mailman/listinfo/forum _______________________________________________ Forum mailing list Forum@mail.gap-system.org http://mail.gap-system.org/mailman/listinfo/forum