chomp(my $userid = `/usr/ucb/whoami` || `/usr/bin/whoami` || 'root');
Why not use $< to find out who you are?
because in the original exercise (OP) I was showing how to greatly simplify a chain of possible failure and still have a usable outcome.
Maybe root wasnt a great choice maybe I could have just said:
$rawstats = (`/usr/bin/prstat -u sx 0 1` || `/usr/local/bin/top -b -Usx ` || 'none for system');
Point being - make sure program paths are set. -Bill- __Sx__________________________________________ http://youve-reached-the.endoftheinternet.org/
-- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>