Help for this page

Select Code to Download


  1. or download this
    use UNIVERSAL qw( isa );
    
    ...
    if ( isa($value, 'HASH') || isa($value, 'ARRAY') ) {
        # Do something here
    }
    
  2. or download this
    use Scalar::Util qw( blessed reftype );
    
    ...
    if ( $r eq 'HASH' || $r eq 'ARRAY' ) {
        # Do something here
    }