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 sys | |
import random | |
def process (text, length): | |
for line in text.split("\n"): | |
if len(line) < length+1: continue | |
for i in range(len(line) - length): | |
yield tuple(line[i:i+length+1]) | |
def parse (text, length=2): |
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
<!DOCTYPE html> | |
<!-- | |
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE | |
Version 2, December 2004 | |
Copyright (C) 2004 Sam Hocevar <sam@hocevar.net> | |
Everyone is permitted to copy and distribute verbatim or modified | |
copies of this license document, and changing it is allowed as long | |
as the name is changed. |
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
(function() { | |
"use strict" | |
function map (a, fn) { | |
var r = [] | |
for (let i = 0; i < a.length; i++) r.push(fn(a[i])) | |
return r } | |
const works = document.querySelectorAll("ol.work.index.group > li.own.work") | |
const data = map(works, el => { | |
const obj = {} |
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
--- script.gs 2016-12-15 11:35:47.288013274 +0200 | |
+++ new.gs 2016-12-15 11:36:52.824766596 +0200 | |
@@ -216,6 +216,7 @@ | |
text.replaceText('<h4>', '<h4 dir="rtl">'); | |
text.replaceText('<h5>', '<h5 dir="rtl">'); | |
text.replaceText('<h6>', '<h6 dir="rtl">'); | |
+ text.replaceText('<dl>', '<dl dir="rtl">'); | |
} | |
else if (action == 'removeRtl') { | |
text.replaceText('<p dir="rtl">', '<p>'); |
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
@powershell -NoProfile -ExecutionPolicy Bypass -Command "iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1'))" && SET "PATH=%PATH%;%ALLUSERSPROFILE%\chocolatey\bin" | |
choco install chocolateygui 7zip firefox vlc classic-shell flashplayerplugin bleachbit transmission-qt libreoffice steam paint.net --yes |
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
(defvar-local writing-mode nil) | |
(defvar-local cached-mode-line nil) | |
(define-minor-mode writing-mode | |
"Minor mode for writing" | |
:variable writing-mode | |
:init-value nil | |
:group 'editing-basics | |
(if (not writing-mode) | |
(progn | |
(toggle-frame-fullscreen) |
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
const $ = x => document.querySelector(x) | |
const $$ = x => [...document.querySelectorAll(x)] | |
const nonempty = x => x.length > 0 | |
const lower_case = x => x.toLowerCase() | |
const includes = y => x => x.includes(y) | |
const multiple_included = xs => x => xs.some(includes(x)) | |
const show = x => x.style.display = "" | |
const hide = x => x.style.display = "none" | |
const head = x => x[0] | |
const last = x => x[x.length - 1] |
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
let trigrams = null | |
const $$ = q => [...document.querySelectorAll(q)] | |
const lower_case = x => x.toLowerCase() | |
const alnum_only = x => x.replace(/[^A-Za-z0-9]/g, "") | |
function trigram(string) | |
{ const t = new Set() |
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
kwik.cx##.plyr::after | |
old.reddit.com##.cookie-infobar | |
www.reddit.com##.cookie-infobar |
OlderNewer