method
chop

chop()
public
Equivalent to ($_.dup).chop!, except nil is never returned. See String#chop!. Available only when -p/-n command line option specified.
chop()
public
Equivalent to ($_.dup).chop!, except nil is never returned. See String#chop!. Available only when -p/-n command line option specified.