Home
My Books
Browse ▾
Recommendations
Choice Awards
Genres
Giveaways
New Releases
Lists
Explore
News & Interviews
Genres
Art
Biography
Business
Children's
Christian
Classics
Comics
Cookbooks
Ebooks
Fantasy
Fiction
Graphic Novels
Historical Fiction
History
Horror
Memoir
Music
Mystery
Nonfiction
Poetry
Psychology
Romance
Science
Science Fiction
Self Help
Sports
Thriller
Travel
Young Adult
More Genres
Community ▾
Groups
Quotes
Ask the Author
Sign In
Join
Sign up
View profile
Profile
Friends
Groups
Discussions
Comments
Reading Challenge
Kindle Notes & Highlights
Quotes
Favorite genres
Friends’ recommendations
Account settings
Help
Sign out
Home
My Books
Browse ▾
Recommendations
Choice Awards
Genres
Giveaways
New Releases
Lists
Explore
News & Interviews
Genres
Art
Biography
Business
Children's
Christian
Classics
Comics
Cookbooks
Ebooks
Fantasy
Fiction
Graphic Novels
Historical Fiction
History
Horror
Memoir
Music
Mystery
Nonfiction
Poetry
Psychology
Romance
Science
Science Fiction
Self Help
Sports
Thriller
Travel
Young Adult
More Genres
Community ▾
Groups
Quotes
Ask the Author
Software Engineering
discussion
11 views
Learn You a Haskell
> Hello Recursion!
Comments
Showing 1-2 of 2
(2 new)
post a comment »
date
newest »
message 1:
by
[deleted user]
(new)
Jan 15, 2012 06:48PM
Here is an even more compact quicksort:
qsort [] = []
qsort (x:xs) = qsort (filter (< x) xs) ++ [x] ++ qsort (filter (>= x) xs)
I think that some of the Haskell advantages in compactness and readability (after a little learning curve) shine through with this example.
reply
|
flag
message 2:
by
Aleksander
(new)
Jan 23, 2012 09:40AM
I think this example could be a good fit for language design discussions in this book.
reply
|
flag
back to top
post a comment »
Add a reference:
Book
Author
Search for a book to add a reference
add:
link
cover
Author:
add:
link
photo
Share
Software Engineering
Group Home
Bookshelf
Discussions
Photos
Videos
Send invite
Members
Polls
unread topics
|
mark unread
Welcome back. Just a moment while we sign you in to your Goodreads account.
qsort [] = []
qsort (x:xs) = qsort (filter (< x) xs) ++ [x] ++ qsort (filter (>= x) xs)
I think that some of the Haskell advantages in compactness and readability (after a little learning curve) shine through with this example.