Help for this page

Select Code to Download


  1. or download this
    sub rec_reverse {
      return $_[0] if $_[0] eq '';
    ...
    }
    
    print rec_reverse( "Hello\nworld." ), "\n";
    
  2. or download this
    sub rec_reverse {
      my $problem = shift;
    ...
        return rec_reverse( $smaller_problem ) . $char;
      }
    }