Q:

parse all arguments and store to hash

How can i parse all the arbitrary arguments to a hash without specifying the argument names inside my perl script.
Running command with below argument should give hash like below. 
-arg1=first --arg2=second -arg3 -arg4=2.0013 -arg5=100
    {
      'arg2' => 'second',
      'arg1' => 'first',
      'arg4' => '2.0013',
      'arg3' => 1,
      'arg5' => 100
    };

This can be achieved using Getopt::Long as below 
 GetOptions(\%hash,
    "arg1=s",
    "arg2=s",
    "arg3",
    "arg4=f",
    "arg5=i");

However, my argument list is too long and i don't want to specify argument names in GetOptions. 
So a call to GetOptions with only hash as a parameter should figure out what arguments are (and their type integer/string/floats/lone arguments) and just create a hash.

A:

There are a lot of Getopt modules.  The following are some that will just slurp everything into a hash like you desire:

Getopt::Mini
Getopt::Whatever
Getopt::Casual

I personally would never do something like this though, and have no real world experience with any of these modules.  I'd always aim to validate every script for both error checking and as a means to self-document what the script is doing and uses.

