RosettaCodeData/Task/Binary-strings/Haskell/binary-strings-5.hs

5 lines
132 B
Haskell
Raw Permalink Normal View History

2023-07-01 11:58:00 -04:00
{- Take the specified number of characters
from the given string -}
strExtract :: Int -> String -> String
strExtract x s = take x s