Re: help
Quoting Alastair Reid [EMAIL PROTECTED] (2002-08-30 02:09:50 BST): Your message seems to be about removing HTML tags from an HTML document. Unfortunately, I had trouble reading your mail because... it was full of HTML tags. yan == yan zhong [EMAIL PROTECTED] writes: htmldiv style='background-color:'DIV P class=MsoNormal style=MARGIN: 0cm 0cm 0ptFONT face=Times New Roman size=2Dear sir/madum/FONT/P P class=MsoNormal style=MARGIN: 0cm 0cm 0ptSPAN style=mso-spacerun: yesFONT face=Times New Roman size=2/FONT/SPANnbsp;/P P class=MsoNormal style=MARGIN: 0cm 0cm 0ptFONT face=Times New Roman size=2I am a Haskell beginner; I got the problem in use Haskell because I never touch it before. Can you help me to solve the following two exercises please?/FONT/P P class=MsoNormal style=MARGIN: 0cm 0cm [SNIP, SNIP] You're more likely to get useful responses if you resend your mail as normal (i.e., ASCII) text. ...but not _much_ more likely. We don't do people's homework for them. However, a hint for the first one. Write a function of type String - [String] that tokenises then another one that determines if a set of tokens comprises an HTML element (that's [String] - Bool). Using this and a bit of cunning, you should get there. -- DOVER WIGHT PORTLAND SOUTHWEST VEERING NORTHWEST 4 OR 5. DRIZZLE AT TIMES. MODERATE OR POOR BECOMING GOOD ___ Haskell-Cafe mailing list [EMAIL PROTECTED] http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: Haskell
Quoting Law [EMAIL PROTECTED]: hi, how do I define this function: tupleWithf :: [Int] - [(Int, Int)] such that tupleWithf [x1,x2,.,xn] = [ (f x1, x1), (f x2 x2),, (f xn, xn) ] ^ you wanted a comma there, I guess. I don't see where you're getting `f' from. I think you want the type to be: tupleWithf :: (Int - Int) - [Int] - [(Int, Int)] Still, you can do this with a trivial list comprehension or map. I leave the implementation as an exercise for the reader. -- IRISH SEA NORTHEASTERLY BACKING WESTERLY 4, INCREASING 5 TO 7 PERHAPS GALE 8 LATER. OCCASIONAL RAIN LATER. GOOD ___ Haskell-Cafe mailing list [EMAIL PROTECTED] http://www.haskell.org/mailman/listinfo/haskell-cafe