Each line is executed independently. Local variables from 1 line of code
will not persist between returns.

Some things do persist though, classes for instance will persist, roles will
persist, grammars will persist, but sub routines will not, neither will
variables. I believe there are plans for some improvements, eventually, but
right now its fairly simplistic.

On Tue, Mar 9, 2010 at 11:42 AM, Kiffin Gish <kiffin.g...@planet.nl> wrote:

> I want to play around with perl6 and see what it can do.
>
> $ cd rakudo
> $ ./perl6
> >  my $x = 8
> > say $x
> Symbol '$x' not predeclared in <anonymous>
>
> How can I define variables and use them later?
>
> --
> Kiffin Gish <kiffin.g...@planet.nl>
> Gouda, The Netherlands
>
>
>


-- 
John "ash" Harrison

Reply via email to