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
await (async () => { | |
function wrap(p) { | |
return p.then( | |
(res) => ["ok", res], | |
(err) => ["error", err] | |
); | |
} | |
async function compare(title, pa, pb) { | |
const a = await wrap(pa); |
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
from enum import Enum | |
from draftsman.blueprintable import Blueprint, BlueprintBook | |
from draftsman.entity import ElectricPole, Roboport, Radar, Lamp | |
from draftsman.tile import Tile | |
def main(): | |
book = base_grid_book() | |
print(book.to_string()) |
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
/* | |
* Convert "Hebrew frequency list: 10,000 most commonly used words" into Anki cards. | |
* | |
* https://www.teachmehebrew.com/hebrew-frequency-list.html | |
* http://web.archive.org/web/20230320182549/https://www.teachmehebrew.com/hebrew-frequency-list.html | |
* | |
* Go to the page and run this script in the developer console. | |
*/ | |
/* |
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
#Warn | |
#SingleInstance | |
SetWorkingDir(A_ScriptDir) | |
Component := "" | |
Device := "Analogue 1 + 2 (Microphone)" | |
Mute(State) { | |
OldState := SoundGetMute(Component, Device) |
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
// Censor a part of the screen (such as a chat window) by pixelation in | |
// obs-shaderfilter. | |
// https://obsproject.com/forum/resources/obs-shaderfilter.775/ | |
// https://creativecommons.org/publicdomain/zero/1.0/ | |
// To the extent possible under law, ion has waived all copyright and related | |
// or neighboring rights to obs-pixelate-rectangle. This work is published | |
// from: Suomi. | |
// https://gist.github.com/ion1/0e028ad096aa6f375bc9a97334639fa3 |
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
/dts-v1/; | |
/plugin/; | |
/ { | |
compatible = "ti,beaglebone", "ti,beaglebone-black"; | |
part-number = "gps-pps"; | |
version = "00A0"; | |
exclusive-use = "P8.4", "gpio1_7"; |
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
$Search = "E:\Music Production\" | |
$Replace = "D:\Music Production\" | |
function Confirm { | |
for (;;) { | |
Write-Host "[YNQ] " -NoNewline | |
$Key = [System.Console]::ReadKey().Key | |
Write-Host "" | |
switch ($Key) { | |
"Y" { return $true } |
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
-- Exercise: prove Peirce’s law <=> law of excluded middle in Haskell | |
{-# LANGUAGE Rank2Types #-} | |
import Data.Void | |
type Not a = a -> Void | |
type Peirce = forall a b. ((a -> b) -> a) -> a | |
type LEM = forall a. Either (Not a) a |
NewerOlder