Nasser M. Abbasi wrote:
> I know I can put code in a file and have it read by Fricas using )read 
> file.input
> 
> But sometimes I want to just copy and paste some code fragment I see which 
> goes 
> over multiple lines like this one, 
> from 
> http://www.axiom-developer.org/axiom-website/hyperdoc/axbook/section-5.4.xhtml#subsec-5.4.9
> 
> for i in 1..50 repeat
>   for j in 1..50 | factorial(i+j) < 25 repeat
>     output [i,j]
> 
> But I can't just paste this on the command line interface, since it wants 
> everything on one line.
> 
> Is there a way to suppress new line and paste the above without getting 
> syntax errors?
> 
> Something like Python REPL command line interface for example, which allows 
> one to 
> do this  sort of thing. one can paste multiple lines code, and it wants for 
> an extra 
> RETURN to accept it.

ATM no such thing.  It is a bit tricky but some day it will probably
irritate me enough to write a better command line handling.  Basically
one needs to switch to different mode on incomplete input.  Easy
to say, but devil is in details...

> I can't even paste one line at a time, since once I hit RETURN before I get 
> chance
> to paste the second line, Fricas will complain about syntax errors.

You can put '_' at the end of line so that FriCAS will treat next
line as continuation of the current one.  Note that since '_'
joins lines to form long logical line usual pile rules do not
work and you need to use parentheses and semicolons to delimit
statemets.

> Does Fricas have a nicer and more user friendly IDE to use to practice on, 
> other than the command line interface?

Some people use Emacs mode.

-- 
                              Waldek Hebisch

-- 
You received this message because you are subscribed to the Google Groups 
"FriCAS - computer algebra system" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/fricas-devel.
For more options, visit https://groups.google.com/d/optout.

Reply via email to