Help for this page

Select Code to Download


  1. or download this
    $arg1 = $ARGV[0];
    
  2. or download this
    my $arg1 = shift @ARGV;
    
  3. or download this
    $restargs = @ARGV;
    
  4. or download this
    my @restargs = @ARGV[1..$#ARGV]; # An array of all the args except the
    + first (uses array slice)
    
    my $restargs = "@ARGV"; # A string containing all the args concatenate
    +d together with spaces between them
    
    my $restargs = "@ARGV[1..$#ARGV]"; # As above excluding the first argu
    +ment
    
  5. or download this
    $restargs = ~s/$arg1 //g;