(defprofile lagénorhynque
:id @lagenorhynque
:reading "/laʒenɔʁɛ̃k/"
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
#!/usr/bin/env bb | |
(ns github-graphql-api-client | |
(:require | |
[babashka.curl :as curl] | |
[cheshire.core :as cheshire] | |
[clojure.pprint :refer [pprint]])) | |
(def auth-token (System/getenv "AUTH_TOKEN")) | |
(def graphql-query |
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
#!/usr/bin/env bash | |
# npm install -g reveal-md | |
reveal-md the-world-of-labour-law.md --theme night --highlight-theme monokai-sublime -w "$@" |

(defprofile lagénorhynque
:id @lagenorhynque
:reading "/laʒenɔʁɛ̃k/"
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
dev> (require '[clojure.spec.alpha :as s] | |
'[clojure.spec.test.alpha :as stest]) | |
nil | |
dev> (defn twice [f x] | |
(f (f x))) | |
#'dev/twice | |
dev> (s/fdef twice | |
:args (s/cat :f (s/fspec :args (s/tuple integer?) | |
:ret integer?) | |
:x integer?) |
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
> fizzBuzz = map (\(f, b, n) -> maybe "" id f ++ maybe "" id b ++ (if null f && null b then show n else "")) $ zip3 (cycle [Nothing, Nothing, Just "Fizz"]) (cycle [Nothing, Nothing, Nothing, Nothing, Just "Buzz"]) [1..] | |
fizzBuzz :: [[Char]] | |
[Prelude] | |
> take 30 fizzBuzz | |
["1","2","Fizz","4","Buzz","Fizz","7","8","Fizz","Buzz","11","Fizz","13","14","FizzBuzz","16","17","Fizz","19","Buzz","Fizz","22","23","Fizz","Buzz","26","Fizz","28","29","FizzBuzz"] | |
it :: [[Char]] | |
[Prelude] | |
> import Data.Maybe | |
[Prelude Data.Maybe] | |
> fizzBuzz' = map (\(f, b, n) -> fromMaybe "" f ++ fromMaybe "" b ++ (if null f && null b then show n else "")) $ zip3 (cycle [Nothing, Nothing, Just "Fizz"]) (cycle [Nothing, Nothing, Nothing, Nothing, Just "Buzz"]) [1..] |
(defprofile lagénorhynque
実例とともに言語学の基礎知識を学ぼう
(defprofile lagénorhynque
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
$ scala | |
Welcome to Scala 2.13.1 (OpenJDK 64-Bit Server VM, Java 14). | |
Type in expressions for evaluation. Or try :help. | |
scala> case class Point(x: Int, y: Int) { | |
| def +(other: Point): Point = Point(this.x + other.x, this.y + other.y) | |
| } | |
defined class Point | |
scala> val p1 = Point(1, 2) |