View Problem

Remove the last element of a list

DiskEdit
ruby
list = ['Apple', 'Banana', 'Carrot']
list.delete_at(-1)
DiskEdit
ruby
list = ['Apple', 'Banana', 'Carrot']
list.pop

Submit a new solution for ruby
There are 22 other solutions in additional languages (clojure, cpp, csharp, erlang ...)