Last active
September 23, 2019 11:55
-
-
Save Koisell/8e2b9605f71e8cfba45b975b139e3d63 to your computer and use it in GitHub Desktop.
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
// A type which holds a reference to itself: | |
sealed abstract class List[+A] | |
final case class Cons[+A](head: A, tail: List[A]) extends List[A] | |
final case object Nil extends List[Nothing] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment