http://qs1969.pair.com?node_id=1049621


in reply to easiest way to read multiple word command arguments

Process the options one by one. If the option does not start with a dash, add it to the previous one:
#!/usr/bin/perl use warnings; use strict; use Data::Dumper; my %options; my $current_option; my $space; for (@ARGV) { if (/^-/) { $current_option = $_; $space = q(); # No space before the + first word. } else { $options{$current_option} .= $space . $_; $space = ' '; } } print Dumper \%options;
لսႽ† ᥲᥒ⚪⟊Ⴙᘓᖇ Ꮅᘓᖇ⎱ Ⴙᥲ𝇋ƙᘓᖇ