- Trail Head
- Bike Trail
- Skiing Area
- Swimming Area
- Ski Resort
- Ice Skating
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{-# LANGUAGE NoImplicitPrelude #-} | |
import Prelude(Eq(..), Bool, (.)) | |
class Functor f where | |
(<$>) :: | |
(a -> b) | |
-> f a | |
-> f b |
-
Look at the scaladoc for Option#zip.
(Option[A])([B]GenIterable[B] => Option[(A, B)]
-
Look at the Option.scala source.
> grep zip | wc -l
0
Item 151234269792
22-Feb-14 20:49
dibblego:
Hi there, I was wondering if I could just "buy it now" for this item at $120.00 + postage instead of waiting 4 days for the auction to end. What do you think?
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module FirstNothing where | |
-- $setup | |
-- >>> import Test.QuickCheck | |
-- >>> instance Arbitrary a => Arbitrary (FirstNothing a) where arbitrary = fmap FirstNothing arbitrary | |
newtype FirstNothing a = | |
FirstNothing (Maybe a) | |
deriving (Eq, Show) | |
class Semigroup a where |
-
Trivial example of dependent types that is also useful (therefore, not the canonical vector size example). Better example: function spaces
-
Interoperability of the Idris language with legacy libraries (JVM).
-
Stream processing with scalaz-stream.
-
Profunctors, the new Arrows.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
object LetsTellLies { | |
def f1[A]: List[A] => Int = | |
_ => util.Random.nextInt | |
def f2[A]: List[A] => Int = | |
f2 | |
def f3[A]: List[A] => Int = | |
_ => { | |
println("hi") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
case class ~=>[T, A](f: T => A) { | |
def map[B](g: A => B): T ~=> B = | |
~=>(f andThen g) | |
def flatMap[B](g: A => T ~=> B): T ~=> B = | |
~=>(t => g(f(t)).f(t)) | |
} | |
object ~=> { | |
// unit: A => F[A] |
OlderNewer