Skip to content

Instantly share code, notes, and snippets.

@lambdahands
Created August 16, 2014 20:00
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save lambdahands/e3d981f8d33e0ce1a5fe to your computer and use it in GitHub Desktop.
Save lambdahands/e3d981f8d33e0ce1a5fe to your computer and use it in GitHub Desktop.
import Data.Text (split, pack, unpack)
splitStr :: Char -> String -> [String]
splitStr c str = map unpack $ split (== c) (pack str)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment