Page 1 of 1

haskell very newbie question

Posted: Sun Nov 13, 2005 9:48 pm
by Anonymous
til :: [String] -> String -> String
til [] s=s
til tks@(c:t) s
|substr c s = til tks (a++B) where (a,B)=split c s (head t)
|otherwise = til (drop 2 tks) s

i don't understand why it says ...syntax error in input (unexpected |')
substr checks if c is a substring of s
i have other functions that look like this and work so i'm completly in the dark here
thx

Archived topic from Iceteks, old topic ID:3953, old post ID:32333

haskell very newbie question

Posted: Wed Nov 16, 2005 8:00 pm
by wtd
There are some problems with the formatting.

Could you repost this, but make sure to diable smilies, and enclose your code in code tags?

Archived topic from Iceteks, old topic ID:3953, old post ID:32510