Help for this page

Select Code to Download


  1. or download this
    sub foo {chop(@_=@_)}
    
  2. or download this
    @a = ('ab','cd','ef');
    print chop @a;     # f
    ...
    
    # the list assignment has the same effect here:
    print chop(@a=@a); # b
    
  3. or download this
    sub foo {chop(@_=reverse @_)}