Skip to content

Instantly share code, notes, and snippets.

@phasetr
phasetr / P651-what-is-just.scm
Last active October 11, 2021 00:13
素数夜曲P.651で突如出てきた `just?` は何者?
;;; P.648
(define (collatz n)
(cond ((= n 1) '(1))
((even? n) (cons n (collatz (/ n 2))))
(else (cons n (collatz (+ (* 3 n) 1))))))
;;; P.650
(define (peak n)
(map (lambda (i) (apply max (collatz i)))
(iota 1 n)))
@phasetr
phasetr / gist:2ee21423608012f33179578ee4b1bf0c
Created April 10, 2022 06:45
MacでのFSACエラー:何故`have 'arm64', need 'x86_64'`と言われるのか
Process fsac stderr finished
Failed to load /usr/local/share/dotnet/host/fxr/6.0.3/libhostfxr.dylib, error: dlopen(/usr/local/share/dotnet/host/fxr/6.0.3/libhostfxr.dylib, 0x0001): tried: '/usr/local/share/dotnet/host/fxr/6.0.3/libhostfxr.dylib' (mach-o file, but is an incompatible architecture (have 'arm64', need 'x86_64')), '/usr/local/lib/libhostfxr.dylib' (no such file), '/usr/lib/libhostfxr.dylib' (no such file)
The library libhostfxr.dylib was found, but loading it from /usr/local/share/dotnet/host/fxr/6.0.3/libhostfxr.dylib failed
- Installing .NET prerequisites might help resolve this problem.
https://go.microsoft.com/fwlink/?linkid=2063366
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>phasetr sample</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<!-- KaTeX -->
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/katex@0.16.0/dist/katex.min.css" integrity="sha384-Xi8rHCmBmhbuyyhbI88391ZKP2dmfnOl4rT9ZfRI7mLTdk1wblIUnrIq35nqwEvC" crossorigin="anonymous">
<script defer src="https://cdn.jsdelivr.net/npm/katex@0.16.0/dist/katex.min.js" integrity="sha384-X/XCfMm41VSsqRNQgDerQczD69XqmjOOOwYQvr/uuC+j4OPoNhVgjdGFwhvN02Ja" crossorigin="anonymous"></script>
<script defer src="https://cdn.jsdelivr.net/npm/katex@0.16.0/dist/contrib/auto-render.min.js" integrity="sha384-+XBljXPPiv+OzfbB3cVmLHf4hdUFHlWNZN5spNQ7rmHTXpd7WvJum6fIACpNNfIR" crossorigin="anonymous"