Skip to content

Instantly share code, notes, and snippets.

View JayTailor45's full-sized avatar
🎯
Focusing

JAY TAILOR JayTailor45

🎯
Focusing
View GitHub Profile
@jdah
jdah / .vimrc
Created June 14, 2021 11:54
jdh's NeoVim .vimrc
call plug#begin()
Plug 'drewtempelmeyer/palenight.vim'
Plug 'vim-airline/vim-airline'
Plug 'wlangstroth/vim-racket'
Plug 'sheerun/vim-polyglot'
Plug 'rust-lang/rust.vim'
Plug 'preservim/tagbar'
Plug 'universal-ctags/ctags'
Plug 'luochen1990/rainbow'
Plug 'vim-syntastic/syntastic'
import java.util.*;
public class AdditionUnderXOR {
static final int SS = 1000000;
enum Ore {
COAL(60005),
IRON(60006),

Seed Cracking

Part 1: A little explanation about Java Random

  • java.util.Random, An instance of this class is used to generate a stream of pseudorandom numbers. The class uses a 48-bit seed, which is modified using a linear congruential formula. (See Donald Knuth, The Art of Computer Programming, Volume 2, Section 3.2.1.)

  • This class has 6 nifty functions:

    • nextBoolean()
    • nextDouble()
  • nextFloat()

@tobiaslins
tobiaslins / worker.js
Last active September 27, 2023 15:19
Notion Custom Domain using Cloudflare Workers + Splitbee Analytics
const MY_DOMAIN = "help.splitbee.io"
const START_PAGE = "https://www.notion.so/splitbee/Help-Center-bbf26e2b70574901b9c98e5d11e449de"
addEventListener('fetch', event => {
event.respondWith(fetchAndApply(event.request))
})
const corsHeaders = {
"Access-Control-Allow-Origin": "*",
"Access-Control-Allow-Methods": "GET, HEAD, POST,PUT, OPTIONS",
@zthxxx
zthxxx / Activate Office 2019 for macOS VoL.md
Last active May 1, 2024 22:04
crack activate Office on mac with license file
@hediet
hediet / main.md
Last active March 11, 2024 15:05
Proof that TypeScript's Type System is Turing Complete
type StringBool = "true"|"false";


interface AnyNumber { prev?: any, isZero: StringBool };
interface PositiveNumber { prev: any, isZero: "false" };

type IsZero<TNumber extends AnyNumber> = TNumber["isZero"];
type Next<TNumber extends AnyNumber> = { prev: TNumber, isZero: "false" };
type Prev<TNumber extends PositiveNumber> = TNumber["prev"];
@Pokechu22
Pokechu22 / Setting up MCP without a full MCP release.md
Last active March 31, 2024 21:35
Setting up MCP for newer versions (e.g. 1.12.2)

It's possible to use create an MCP installation for versions of Minecraft where there hasn't been a full MCP release. It takes a little bit of manual setup, but the end result is highly useful.

  1. Download and extract the most recent MCP build from http://www.modcoderpack.com/. (Currently, the latest build is http://www.modcoderpack.com/files/mcp940.zip)

  2. Edit version.cfg in the conf folder, and change ClientVersion and ServerVersion to the version you want (for instance, 1.12.2).

  3. Download the SRG zip for the version you want; these can generally be found at http://mcpbot.bspk.rs/mcp/<version>/mcp-<version>-srg.zip (for example, http://mcpbot.bspk.rs/mcp/1.11.2/mcp-1.11.2-srg.zip) or at http://files.minecraftforge.net/maven/de/oceanlabs/mcp/mcp/<version>/mcp-<version>-srg.zip (for example, http://files.minecraftforge.net/maven/de/oceanlabs/mcp/mcp/1.12.2/mcp-1.12.2-srg.zip). (For 1.12.1 and 1.12.2, only the minecraftforge link works)

  4. Extract that zip into the MCP conf folder, over

@btroncone
btroncone / ngrxintro.md
Last active February 9, 2024 15:37
A Comprehensive Introduction to @ngrx/store - Companion to Egghead.io Series

Comprehensive Introduction to @ngrx/store

By: @BTroncone

Also check out my lesson @ngrx/store in 10 minutes on egghead.io!

Update: Non-middleware examples have been updated to ngrx/store v2. More coming soon!

Table of Contents

[Emmet cheatsheet](http://docs.emmet.io/cheat-sheet/)
##html
- press tab after line
- div>ul>li
- ! => (=html5 template)
- script:src
- style =>
- a =>
- a:mail =>
- img =>