Skip to content

Instantly share code, notes, and snippets.

@tkmfujise
tkmfujise / lfcd
Last active November 29, 2024 17:48
`lf` command configuration
# https://github.com/gokcehan/lf/wiki/Tips
set cursorpreviewfmt ""
cmd yank-file $printf '%s' "$f" | pbcopy
cmd opener-open &$OPENER $f
cmd opener-open-wsl &{{
cmd.exe /c start "" "$(wslpath -w $f)" 2> /dev/null
}}
cmd mkdir %mkdir "$@"
cmd touch %touch "$@"
@tkmfujise
tkmfujise / fizzbuzz.scm
Last active November 26, 2024 01:50
FizzBuzz を scheme (gauche) で書いた。
#!/usr/bin/env gosh
(define (fizzbuzz n)
(define (% x y) (eq? (mod x y) 0))
(define (get i)
(cond ((% i 15) "FizzBuzz")
((% i 5) "Buzz")
((% i 3) "Fizz")
(else (x->string i))))
(define (show str)
(display str)