Skip to content

Instantly share code, notes, and snippets.

View sheepla's full-sized avatar
🐑
メェ〜

sheepla sheepla

🐑
メェ〜
View GitHub Profile
@Hayao0819
Hayao0819 / jirou.ts
Created December 20, 2023 08:06
ラーメン二郎の型定義
export type MenuAmount = "マシ" | "多め" | "マシマシ" | "かなり多め" | "普通" | "少なめ" | "無し";
export type IsGarlicAdded =
| "全てマシ"
| "全て普通"
| "全て少なめ"
| {
ニンニク?: MenuAmount;
ヤサイ?: MenuAmount;
アブラ?: MenuAmount;
@RyushiAok
RyushiAok / FsFizzBuzz.fsx
Created December 5, 2023 03:43
FsFizzBuzz.fsx
let (|Fizz|_|) n = if n % 3 = 0 then Some "Fizz" else None
let (|Buzz|_|) n = if n % 5 = 0 then Some "Buzz" else None
let (|FizzBuzz|_|) n =
if n % 15 = 0 then Some "FizzBuzz" else None
let fizzBuzz =
function
| FizzBuzz fizzbuzz -> fizzbuzz
| Fizz fizz -> fizz
@AWtnb
AWtnb / sushi-yunomi.ps1
Created November 12, 2023 03:21
寿司屋の湯呑に使えそうな魚偏の漢字を出力
0x9b5a..0x9ce4|% {[char]::ConvertFromUtf32($_)}
@RyushiAok
RyushiAok / markdown.fs
Created October 18, 2023 15:03
F# Markdown Builder
type Block =
| H1 of string
| H2 of string
| P of string
type Markdown = {
title: string
author: string
blocks: Block list
} with
@RyushiAok
RyushiAok / unko_builder.fs
Created October 9, 2023 12:56
uncode💩
type NextChar = NextChar
type NextWidth = NextWidth of char
type NextHeight = NextHeight of char * int
type EndUnnko = EndUnnko of char * int * int
type UnnkoBuilder () =
member _.Yield(_: unit) = NextChar
member _.Run(EndUnnko (char, w, h): EndUnnko) =
let nChars n c = c |> Array.replicate n |> System.String
printfn "%s∫ ∫ ∫ " <| nChars h ' '
printfn "%sノヽ " <| nChars h ' '
@Hayao0819
Hayao0819 / destroy.sh
Last active June 22, 2023 17:35
シェル芸ロシアンルーレット
#!/bin/sh
# 参考
# https://qiita.com/_-_-_-_-_/items/214d537aae2c1488692c
get_random(){
od -v -An --width=1 -tu1 -N1 < /dev/urandom | \
awk "{ print \$1 % 10 }"
}
@Comamoca
Comamoca / onimai.md
Last active November 27, 2023 01:04
flowchart TB
A[あり] --> B[なし] --> B
B --> A
A --> C[ついて] --> E[] --> C
C --> D[ない] --> F[あれ]
F --> G[どっち] --> G
G --> I[trans] --> I
I --> I
I --&gt; I
@TwoSquirrels
TwoSquirrels / 画像保存ブックマークレット.md
Last active July 23, 2023 11:42
画像保存ブックマークレット

画像保存ブックマークレット

This bookmarklet downloads up to four images from a Twitter page, and names them based on the username, tweet ID, and image number. It only works on Twitter pages and will throw an error if run on a different website.

Bookmarklet

javascript:(async()=>{if(location.hostname.match(/\.?twitter\.com$/)){let[,t,,e]=location.pathname.split("/");return[...document.getElementsByTagName("img")].filter(t=>t.src.startsWith("https://pbs.twimg.com/media/")).slice(0,4).map((a,c)=>({url:a.src.replace(/&name=.+/,""),name:`Title-twitter-${t}-${e}-${c+1}.jpg`}))}throw Error("This page is not supported.")})().then(t=>t.forEach(async({url:t,name:e})=>{let a=document.createElement("a");a.href=URL.createObjectURL(await (await fetch(t,{mode:"cors"})).blob()),a.download=e,a.click()})).catch(t=>alert(t))
@haruki7049
haruki7049 / unko.hs
Created October 20, 2022 00:53
うんこの量が多すぎる!!
unkoJudge :: Double -> String
unkoJudge volume
| volume <= 10.0 = "Too little..."
| volume <= 20.0 = "Uh... OK. It may be safe."
| otherwise = "Oh!! Your unko is very big!!! You are LEGEND!!!"
@shariqmalik
shariqmalik / Configure_WSA_for_Pentest.md
Last active September 16, 2025 05:44
Configure WSA (Windows Subsystem for Android) for Pentest