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
<html> | |
<head> | |
<script src="http://nondefault.net/c_lite.js"></script> | |
<script> | |
var mxp = Mouse.x, mxy = Mouse.y; | |
function init() { | |
} | |
function step() { | |
if (Mouse.down) { |
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
/*! | |
* | |
* wavepot windchimes | |
* nondefault.net | |
* | |
*/ | |
var transpose = 0; | |
var ct = 0; |
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 ramp(t, min, max, fluff) { | |
var diff = t>fluff?1-t:t; | |
var deaden = 0; | |
if (diff < fluff) | |
deaden = (fluff-diff)/fluff; | |
return min+(max-min)*(1-deaden); | |
} | |
var min = 1, max = 10; | |
for (var i=0; i<=max; i++) { |
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
/** | |
* Represents a color that can be expressed as an RGB value. | |
* RGB values are in the range 0 ~ 255 (rounded for display). | |
* HSL values are in the range 0 ~ 1. | |
* A color can be constructed using any of the following: | |
* - No arguments; will be interpreted as black | |
* - A single integer representing a packed RGB value | |
* - Three integers or floats representing RGB or HSL values (depending on Color.DEFAULT_MODE) | |
* - A hex #NNNNNN color string | |
* - A canvas2d/CSS rgb(n,n,n) or hsl(n,n%,n%) color 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
var http = require("http"), | |
url = require("url"), | |
path = require("path"), | |
fs = require("fs"), | |
port = process.argv[2] || 8001; | |
http.createServer(function(request, response) { | |
var uri = url.parse(request.url).pathname | |
, filename = path.join(process.cwd(), uri); |
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
class Vector { | |
constructor(x,y) { | |
if (arguments.length === 2) { | |
this.x = x; | |
this.y = y; | |
} | |
else if (arguments.length === 0) { | |
this.x = 0; | |
this.y = 0; | |
} |
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
/** | |
* This file has been modified slightly for public release. | |
* Some documentation has been removed. | |
*/ | |
import java.util.List; | |
import java.util.ArrayList; | |
import java.util.LinkedList; | |
import java.util.function.Function; |
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 random | |
import math | |
class Noise: | |
def __init__(self, seed=None): | |
self.P = [x for x in range(1,256)] | |
self.P += self.P | |
random.seed(seed) | |
random.shuffle(self.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
"Logan's vimrc | |
"Basic setup | |
set autoread "update automatically when file is modified externally | |
filetype plugin on | |
filetype indent on | |
set wildmenu | |
syntax on | |
set mouse=a |
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 long = require("long"); | |
const execSync = require("child_process").execSync; | |
const fs = require("fs"); | |
const N = 5, M = 40, UNTIL_FAIL = true; | |
const MAX64 = long.MAX_VALUE; | |
const MIN64 = long.MIN_VALUE; | |
const BIN = { | |
"+": function(a,b) {return a.add(b)}, | |
"-": function(a,b) {return b.sub(a)}, |
OlderNewer