Learn You a Haskell for Great Good! - Miran Lipovaca

Learn You a Haskell for Great Good!

Miran Lipovaca

出版时间

2010-01-01

ISBN

9781593272838

评分

★★★★★

标签

编程

书籍介绍

Learn You a Haskell for Great Good! is a fun, illustrated guide to learning Haskell, a functional programming language that's growing in popularity. Learn You a Haskell for Great Good! introduces programmers familiar with imperative languages (such as C++, Java, or Python) to the unique aspects of functional programming. Packed with jokes, pop culture references, and the author's own hilarious artwork, Learn You a Haskell for Great Good! eases the learning curve of this complex language, and is a perfect starting point for any programmer looking to expand his or her horizons. The well-known web tutorial on which this book is based is widely regarded as the best way for beginners to learn Haskell, and receives over 30,000 unique visitors monthly.

About the Author

Miran Lipovaca is a computer science student in Ljubljana, Slovenia. His online tutorial, "Learn You a Haskell for Great Good!," is widely regarded as the best way to learn Haskell.

AI导读
核心看点
  • 幽默风趣的插图与文风,降低学习门槛
  • 从基础语法到Monad,循序渐进讲解核心概念
  • 适合有命令式编程经验的读者入门函数式编程
适合谁读
  • 熟悉C++、Java或Python等命令式语言的程序员
  • 希望系统学习Haskell及函数式编程思想的初学者
  • 对类型系统、Functor及Monad概念感兴趣的读者
读前提醒
  • 建议配合官方免费在线版本阅读,获取最新内容
  • Monad部分较抽象,需结合代码示例反复琢磨理解
  • 内容偏重直觉与基础,深入应用建议搭配其他书籍
读者共识
  • 公认最好的Haskell入门书,讲解清晰且生动
  • 相比Real World Haskell更易懂,适合新手起步
  • 部分读者认为内容略显拖沓,进阶深度稍显不足

本导读基于书籍简介、目录、原文摘录、短评和书评生成,不等同于全文精读。

精彩摘录
  • "我们看到如何在函子值上映射“多参数”函数得到函数值的函子值。我们能对它做什么吗?对于一个参数,我们可以映射一个函数,它接受某个函数为参数,给这个函数应用一个参数。因为函子值里的任何东西都会被作为参数传递给我们的函数。"
  • "_ means that we don't care what we'll draw from the list anyway so instead of writing a variable name that we'll never use, we just write _."
  • "Use tuples when you know in advance how many components some piece of data should have. Tuples are much more rigid because each different size of tuple is its own type, so you can't write a general function to append an element to a tuple — you'd have to write a function for appending to a pair, one"
  • "In our gcd' function, the logging is fast because the list appending ends up looking like this: a ++ (b ++ (c ++ (d ++ (e ++ f)))) Lists are a data structure that's constructed from left to right, and this is efficient because we first fully construct the left part of a list and only then add a long"
  • "Function application has the highest precedence of all the operations in Haskell. In other words, these two statements are equivalent."
  • "This example introduces Haskell’s if statement. You’re probably already familiar with if statements from other languages, but what makes Haskell’s unique is that the else part is mandatory. On the other hand, a Haskell program is a collection of functions. Func- tions are used to transform data valu"
  • "Accessing List Elements If you want to get an element of a list by index, use the !! operator. As with most programming languages, the indices start at 0:"
  • "multThree :: Int -> Int -> Int -> Int multThree x y z = x * y * z"
作者简介
Miran Lipovaca is a computer science student in Ljubljana, Slovenia. His online tutorial, "Learn You a Haskell for Great Good!," is widely regarded as the best way to learn Haskell.
目录
Introduction
Chapter 1: Starting Out
Chapter 2: Believe the Type
Chapter 3: Syntax in Functions
Chapter 4: Hello Recursion!

显示全部
用户评论
必须推荐,学FP的绝佳入门语言和教程。
我读过最好的Haskell入门。内容不如Real World Haskell丰富,没有介绍网络和数据库等,但基础内容全面而且清晰易懂。Functor->Monoid->Monad的进阶也是目前我觉得了解Monad最合理的路径。
草。。。读到lambda真出来个freeman半身像。。。
起初跟 Real World Haskell 同时看的,后来索性先把他看完!
文风很幽默,讲解也很到位,简洁清晰。这本小书比Real World Haskell好懂。缺点是内容不够全面和深入。fold的用法也有错误,email给作者,他也已经意识到了这一点。
看得我稀里糊涂的,其实没理解。感觉讲得太浅了。
太棒了,学haskell就靠它看懂了
比我读过的所有Haskell中文教材好读十万甚至九万倍
再一次入门 Haskell。文风亲切,画风可爱,讲解得挺细致(对有经验的人来说算拖沓了)。不过离现代 Haskell 还挺远,只能算新手了解下 Haskell 风格用。
只读了前半部分,清晰易懂
收藏