DEV Community


Discussion on: Daily Challenge #1 - String Peeler

peterbunting profile image
Peter Bunting

And it turns out that you don't even need to explicitly convert it to an array. F# will let you do splicing on a string. So a much better solution is:

let stringPeeler (s: string) = s.[1..(s.Length - 2)]