- 動かして学ぶ量子コンピュータプログラミング https://www.oreilly.co.jp/books/9784873119199/
- Rubyのしくみ https://shop.ohmsha.co.jp/shopdetail/000000004065/
- 定理証明手習い https://www.lambdanote.com/products/littleprover
- 計算理論の基礎 原著第2版 ①オートマトンと言語 https://www.kyoritsu-pub.co.jp/bookdetail/9784320122079
- n月刊ラムダノート シリーズ https://www.lambdanote.com/collections/n
- Vol1のNo.2とNo.3を持ってます。揃えたい。
- ラムダノート社の直販サイトで本を買うとき、n月刊ラムダノートを一緒に買うと送料無料になります。
- ラムダノート社の本は、直販サイトで買うとpdfの電子書籍版が無料で付いてきます!うれしい!
- みんなのデータ構造 https://www.lambdanote.com/products/opendatastructures
- プログラミング言語の基礎概念 https://www.fos.kuis.kyoto-u.ac.jp/~igarashi/CoPL/
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
// アイテムやスキルの効果を、プログラム上のデータとして表現し、それを解釈・実行することで各パラメータを算出する。 | |
// EDSL (Embedded Domain Specific Language 組み込みDSL) として知られているテクニック。 | |
namespace Edsl | |
{ | |
// Stats represents parameters of the character. | |
// Stats can only be calculated by Effect.execute() method. | |
record Stats(string Name, int HP, int MP, int ATK, int DEF); | |
// Condition represents the condition of the game. |
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
import time | |
import pyautogui | |
from pyjoycon import device | |
from pyjoycon.joycon import JoyCon | |
# Set up JoyCon | |
id = device.get_L_id() | |
joycon = JoyCon(*id) | |
is_pressed = False |
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
{ | |
description = "malgo flake"; | |
inputs = { | |
nixpkgs.url = "github:NixOS/nixpkgs"; | |
flake-utils.url = "github:numtide/flake-utils"; | |
}; | |
outputs = { self, nixpkgs, flake-utils }: | |
flake-utils.lib.eachDefaultSystem (system: |
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 stack | |
-- stack script --resolver lts-18.26 | |
-- | 詳細は https://twitter.com/takoeight0821/status/1501899867249000448 | |
module Main where | |
import Data.Foldable | |
import Data.IORef | |
import Data.List | |
import Data.List.HT |
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 Main exposing (..) | |
import Playground exposing (..) | |
cupWidth : number | |
cupWidth = | |
100 | |
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
((N(N(WE)*S+(W+N(WE)*WS)(NS+NE(WE)*WS+WE)*(E+NE(WE)*S))*S+N(N(WE)*S+(W+N(WE)*WS)(NS+NE(WE)*WS+WE)*(E+NE(WE)*S))*(W+N(WE)*WS)(NS+NE(WE)*WS+WE)*WS(NS+NE(NS+NE(WE)*WS+WE)*WS+NE(NS+NE(WE)*WS+WE)*(E+NE(WE)*S)(N(WE)*S+(W+N(WE)*WS)(NS+NE(WE)*WS+WE)*(E+NE(WE)*S))*(W+N(WE)*WS)(NS+NE(WE)*WS+WE)*WS)*NE(NS+NE(WE)*WS+WE)*(E+NE(WE)*S)(N(WE)*S+(W+N(WE)*WS)(NS+NE(WE)*WS+WE)*(E+NE(WE)*S))*S+(W+N(N(WE)*S+(W+N(WE)*WS)(NS+NE(WE)*WS+WE)*(E+NE(WE)*S))*(W+N(WE)*WS)(NS+NE(WE)*WS+WE)*S+N(N(WE)*S+(W+N(WE)*WS)(NS+NE(WE)*WS+WE)*(E+NE(WE)*S))*(W+N(WE)*WS)(NS+NE(WE)*WS+WE)*WS(NS+NE(NS+NE(WE)*WS+WE)*WS+NE(NS+NE(WE)*WS+WE)*(E+NE(WE)*S)(N(WE)*S+(W+N(WE)*WS)(NS+NE(WE)*WS+WE)*(E+NE(WE)*S))*(W+N(WE)*WS)(NS+NE(WE)*WS+WE)*WS)*(E+NE(NS+NE(WE)*WS+WE)*S+NE(NS+NE(WE)*WS+WE)*(E+NE(WE)*S)(N(WE)*S+(W+N(WE)*WS)(NS+NE(WE)*WS+WE)*(E+NE(WE)*S))*(W+N(WE)*WS)(NS+NE(WE)*WS+WE)*S))(N(NS+NE(WE)*WS+WE)*S+N(NS+NE(WE)*WS+WE)*(E+NE(WE)*S)(N(WE)*S+(W+N(WE)*WS)(NS+NE(WE)*WS+WE)*(E+NE(WE)*S))*(W+N(WE)*WS)(NS+NE(WE)*WS+WE)*S+(W+N(NS+NE(WE)*WS+WE)*WS+N(NS+NE(WE)*WS+WE)*( |
星にゃーん(@takoeight0821)です。 HaskellとかSF小説とかが好きです。
今日は自作言語Malgoの話をします。 https://github.com/malgo-lang/malgo
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
echo '#include <stdio.h>' | |
echo 'int main(void) {' | |
echo 'int tape[256] = {0};' | |
echo 'int i = 0;' | |
cat $@ |\ | |
sed -e 's/\]/}/g' |\ | |
sed -e 's/\[/while(tape\[i\]){/g' |\ | |
sed -e 's/+/tape\[i\]++;/g' |\ | |
sed -e 's/-/tape\[i\]--;/g' |\ | |
sed -e 's/>/i++;/g' |\ |
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
// libraryDependencies += "org.scala-lang.modules" %% "scala-parser-combinators" % "1.1.2" | |
import scala.util.parsing.combinator._ | |
import scala.collection.mutable._ | |
sealed trait SExpr | |
case class Symbol(x: String) extends SExpr | |
case class IntLiteral(x: Int) extends SExpr | |
case class SList(xs: List[SExpr]) extends SExpr | |
sealed trait SValue |
NewerOlder