RosettaCodeData/Task/Binary-strings/Haskell/binary-strings-6.hs
Ingy döt Net 86c034bb8b new files
2013-04-10 12:38:42 -07:00

4 lines
163 B
Haskell

{- Take a certain substring, specified by
two integers, from the given string -}
strPull :: Int -> Int -> String -> String
strPull x y s = take (y-x+1) (drop x s)