Talk:Haskell/Lists and tuples
From Wikibooks, the open-content textbooks collection
DavidHouse: oops! Sorry about those edit conflicts! Don't think I'll have much time for wikibook hacking. Over to you. -- Kowey 18:05, 25 July 2006 (UTC)
Contents |
[edit] Dupes
Is the List section supposed to summarize or duplicate Haskell/Lists or what? I'm just confused. --maru (talk) contribs 23:38, 1 October 2006 (UTC)
- DavidHouse and I were rearranging things. Haskell/Lists should probably be renamed to something like Haskell/More on lists. This page is meant to be very introductory; give the reader the bare list and tuple essentials for learning the other stuff. -- Kowey 08:48, 2 October 2006 (UTC)
[edit] FIXME: Is this too hard?
I'm not sure what you meant by that comment. Coming up with the answer "You can't just add on to a tuple because it has a size restraint" is trivial. Coming up with a more in-depth answer doesn't seem feasible to me, as a programming novice, without more information than covered so far.
-Humble Reader, 10/04/06 10:58 pm
[edit] consistent form for describing operators?
The comma operator is mentioned with double quotes around the comma, and the cons operator is written with parentheses. It might be nice for them to be done in bold, so I can tell if the () is textually parenthesizing of if the parentheses are part of the formal definition, and whether the comma operator is formally defined with or without parens. Msouth 14:53, 15 July 2007 (UTC)
[edit] cons8 exercise: write a function that takes a list? how?
Am I supposed to know how to write a function that "takes a list"? I tried to figure out how to tell my function to expect a list, didn't know how to do it. It might be easier for people to guess what to do if you just said "write a function cons8 that takes a single argument and conses 8 on to it" or something like that. Msouth 15:12, 15 July 2007 (UTC)
[edit] lists - we should introduce ++ before :
How about introducing ++ before :? It would be easier to understand as it's commutative. We would need to give examples such as
- [someThing]++someListofThings
The : should be mentioned last, only after it's clear what lists are, and how they must have elements of the same type. I think the list of lists example should be mentioned before : also. Concatenation of lists is easier to understand then is cons. Aaron McDaid (talk) 23:08, 5 January 2008 (UTC)