Skip to content

Instantly share code, notes, and snippets.

@t9md
t9md / movement.md
Last active January 4, 2024 13:24
Movement, animal flow

I'm t9md

t9md__t9md_.png Presentation1.png

  • My editor history: Vim > Emacs > Vim > Atom
@t9md
t9md / go-tour-select.go
Last active May 29, 2021 07:46
Go's Channel and select {} illustrated
package main
/*
Channel and select {} illustrated by t9md
===========================================================
sample program to understand goroutine communication via channel.
based on go-tour's example
https://tour.golang.org/concurrency/5
*/
@t9md
t9md / back.html
Created February 22, 2021 02:48
Anki
{{FrontSide}}
<hr id="answer">
{{answer}}
<div id="search-container">
<a class="search" id="bing-img-search" href="https://www.bing.com/images/search?safeSearch=Strict&setLang=en&mkt=en-US&q={{text:word}}&tsc=ImageBasicHover&qft=+filterui:license-L1">
Bing
</a>
&nbsp;
<a class="search" href="https://www.google.co.jp/search?q={{text:word}}&tbm=isch">
@t9md
t9md / README.md
Last active May 14, 2020 01:19
Bookmarklet to copy subtitles when you are using LLN(for Netflix)+LLY(for Youtube)

bookmarklet-setup

This bookmarklet works for both LLN and LLY.

  1. Create bookmark on bookmarkbar with the name copy-subtitle.
  2. Edit bookmark you've just created and replace URL with content of clip-subtitle.js.
  3. On Yourtube with LLY enabled, click bookmarklet. Done.
  4. Now, you have subtitles in your clipboard. So you can paste it to DeepL

If you want to modify bookmarklet.

- リスニング能力は総合力。ここが本当の実力
- スピーキングは大分後回しで良い、勝手にレベルアップする(という理論、事例が多数あり)
- 何故かと言うと、自然に喋れるためには Grammar intuition と パターン蓄積が必須だが、これは大量Inputによって得られるから。
- 常にスピーキング能力はリスニング能力より下になる。これは当たり前の話。日本語でもそうだよね?
- パターン蓄積とは、特定の事言いたい場合の言い方の例を溜めること。 例: お腹空いた vs I am hungry
- なので、大量のリアルな音声インプットが必須
- このとき、50%しか、あるいは20%しか分からなかったとき、それで完璧主義/潔癖主義に陥らないこと。
- 曇った眼鏡でも楽しめるはず。そして続けていれば20%→21%になる。それはレンズの曇りが晴れてより楽しめるようになる。
- こういう姿勢で臨めば自分が興味がある分野の動画/音声を、"楽しんで毎日聞き続ける"(お勉強ではなく)ことが可能になる。
- 楽しめる→継続できる→慣れる→解像度が上がる(キャッチできる部分が増える)→より楽しめる→勝手に少しずつレベルアップする
@t9md
t9md / vital_doc.md
Last active March 16, 2019 01:15
vital.vim チュートリアル

このドキュメントの状態(超ドラフト)

かなりドラフトの状態なので ウソ が含まれているかもしれない。

github vital.vim

vital.vim とは

ピュア Vim script で書かれた、便利なライブラリ集 .vimrc の中で気軽に使ったり、プラグイン作成者がライブラリとして利用する。

def copy_reduced_image(file)
puts "#### #{file}"
File.readlines(file).each do |line|
word = line.split("\t")[0]
cmd = "ffmpeg -y -i slideshow/imgs/#{word}.png -vf 'scale=1334:-1' -q 2 icloud-app/imgs/#{word}.png"
system cmd
# puts cmd
end
end
window.AudioContext = window.AudioContext || window.webkitAudioContext
class AudioPlayer {
constructor () {
this.context = new AudioContext()
}
// Audio 用の buffer を読み込む
getAudioBuffer (url, callback) {
const req = new XMLHttpRequest()
req.responseType = 'arraybuffer' // array buffer を指定