--- name: chop status: documented runtime: pp source: src/runtime/pp/strings/chomp.rs --- ```{index} single: chop; Perl built-in (pp runtime) ``` # chop ## Synopsis ```perl $char = chop($var); $char = chop(@list); chop $var; ``` ## Description Removes the last character from each argument. Returns the last character removed (from the final argument). Unlike `chomp`, `chop` always removes exactly one character regardless of `$/`. Operates on each element when given an array. Returns the last character removed. Correctly handles multi-byte UTF-8 characters. ## See also chomp