1.) Download a Nerd Font
2.) Unzip and copy to ~/.fonts
3.) Run the command fc-cache -fv to manually rebuild the font cache
1.) Download a Nerd Font
2.) Unzip and copy to ~/.fonts
3.) Run the command fc-cache -fv to manually rebuild the font cache
| // Immutable Stack Type using List | |
| case class Stack[A] (elems: Seq[A] = List.empty[A]) { | |
| def push(v: A) : Stack[A] = Stack(v +: elems) | |
| def pushAll(xs: Iterable[A]) : Stack[A] = | |
| xs.foldLeft (this) ((accStack, e) => accStack.push(e)) | |
| def pop(): Either[String, (A, Stack[A])] = { | |
| if (isEmpty) Left("Cannot pop from empty stack") |