Help for this page

Select Code to Download


  1. or download this
    print "not ref:\n";
    test(dogs=>'bark', cats=>'miaow');
    ...
      ref($_[0]) ? $params = shift : $params = {@_};
      print Dumper($params);
    }
    
  2. or download this
    not ref:
    $VAR1 = {
    ...
              'HASH(0x81194e0)' => undef
            };
    
  3. or download this
    not ref:
    hello
    ...
              'dogs' => 'bark',
              'cats' => 'miaow'
            };
    
  4. or download this
      if(ref($_[0])){
        $params = shift;
    ...
      else{
        $params = {@_};
      }
    
  5. or download this
    not ref:
    $VAR1 = {
    ...
              'cats' => 'miaow',
              'dogs' => 'bark'
            };