View Problem

Remove leading and trailing whitespace from a string

Given the string "  hello    " return the string "hello".
ExpandDiskEdit
fsharp
let s = " hello "
let trimmed = s.Trim()
ExpandDiskEdit
fsharp
let trimmed = " hello ".Trim()
ExpandDiskEdit
fantom
s := " hello ".trim

Submit a new solution for fsharp or fantom
There are 19 other solutions in additional languages (clojure, cpp, csharp, erlang ...)