Hi,

you can very well try the following

 $x = ENV{'PWD'};

this reads the present working directory from the $PWD environment
variable.


On Feb 7, 6:59 pm, pouliakh...@gmail.com (Pouliakhina) wrote:
> Hello,
>
> I try to write the name of the current directory in $x:
>
> $x = system ("pwd");
>
> But it doesn't work. It also doesn't work in all these combinations:
> 
> $x = 'system("pwd")';
> $x = system("`pwd`");
>
> Can You help me to write the result of 'pwd' in $x?
>
> Thank You,
> Irina


--
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/


Reply via email to