Skip to content

Instantly share code, notes, and snippets.

View kevinkace's full-sized avatar

Kevin Cameron kevinkace

View GitHub Profile
@kevinkace
kevinkace / ps.js
Created December 10, 2015 22:00
PL
team = {
name : "",
desc : "",
logo : "",
members : [ player ],
matches : [],
contact : {
twitter : "",
twitch : "",
fb : ""
@kevinkace
kevinkace / AOC7a.js
Created December 8, 2015 17:25
Advent of Code - 7a - Unfinished
"use strict";
var stack = [],
input = require("./sample.js").split("\n"),
solve = function(v1) {
if(typeof stack[v] === number) {
}stack[]
return val;
@kevinkace
kevinkace / AOC6b.js
Created December 8, 2015 05:48
Advent of Code - 6b
"use strict";
var input = require("./input.js"),
g = [],
gs = 1000,
x, y,
count = 0,
gridlington = function(size) {
var arr = [];
@kevinkace
kevinkace / AOC6a.js
Created December 8, 2015 05:41
Advent of Code - 6b
"use strict";
var input = require("./input.js"),
g = [],
gs = 1000,
x, y,
count = 0,
gridlington = function(size) {
var arr = [];
@kevinkace
kevinkace / AOC5b.js
Created December 7, 2015 05:44
Advent of Code - 5b
var names = document.querySelector("pre").innerHTML.trim(),
niceCount = 0;
function vowelCheck(name) {
var count = name.match(/[aeiou]/gi);
return count && count.length >= 3;
}
function doubleCheck(name) {
return /(.)\1/.test(name);
@kevinkace
kevinkace / AOC5a.js
Last active December 7, 2015 04:34
Advent of Code - 5a
var names = document.querySelector("pre").innerHTML.trim(),
niceCount = 0;
function vowelCheck(name) {
var count = name.match(/[aeiou]/gi);
return count && count.length >= 3;
}
function doubleCheck(name) {
return /(.)\1/.test(name);
@kevinkace
kevinkace / AOC4b.js
Last active December 7, 2015 04:35
Advent of Code - 4b
// include this: https://blueimp.github.io/JavaScript-MD5/js/md5.js
var input = "yzbqklnj",
found = false,
suffix = 1;
while(found === false) {
// noprotect
if(window.md5(input + suffix++).indexOf("000000") === 0) {
found = --suffix;
@kevinkace
kevinkace / gist:e07a5cc4a2f0bcef3452
Last active December 7, 2015 02:51
Advent of Code - 3b
var dirs = "v>v<vvv<<vv^v<v>vv>v<<<^^^^^<<^<vv>^>v^>^>^>^>^><vvvv<^>^<<^><<<^vvvv>^>^><^v^><^<>^^>^vvv^<vv>>^>^^<>><>^>vvv>>^vv>^<><>^<v^>^>^><vv^vv^>><<^><<v>><>^<^>>vvv>v>>>v<<^<><^<v<>v>^^v^^^<^v^^>>><^>^>v<>^<>>^>^^v^><v<v>>><>v<v^v>^v<>>^><v>^<>v^>^<>^v^^^v^^>>vv<<^^><^<vvv>^>^^<^>>^^^^^v^<v>vv<>>v^v<^v^^<><^<^vv^><>><><>v>vvv^vv^^<<><<vvv><<^v^><v<>vvv^<^>vvvv^>^>>^v^<v^vv<^^v<>v>vv^<>><v<<<^v^<<><v<^<^<><^^^>^>>v>^>v^<>v><^<^<v^>^^vv<^^<>v^v^vv<>>>>v^v<>><^^v>vv^^>v^v>v<vv>>v>><v^v^v>vv>^^>^v><<vv^v^^vv<^v><^<<v<v^>vv^^^<v^>v>v^^^>><^^<v^<^>>v><vv<v^^>^^v>>v^^^<^^v>^v>><^<^<>>v<<^^vv>^^^v<^<^<v<v^^vv>^vv^>>v^><v>><<<>^vv^<^<>v^^<<<v<^>^><><v^^>>^^^<^vv<^^^>><^^v>^^v^<v^v^>^^<v>^<^v<^<<<<^<v^>v^<^^<>^^>^><<>>^v><>><^<v><^^^>>vv>^><vv>^^^^^v^vvv><><^<^>v>v^v^>^><><^<^><>v<<vv<^>><>^v^^v>^<<<>^v^>^<<v^vv<>v^<v^^vv><<v^<>>>^<v>vv>v>>>^<^>><vv<>>>>v<v>>>^v>v><>>vvv<^^><<^>^>v<^vvvv<v><vv<><^^^v^^^>v^v<>v<^^v>>><>v<v^>>v><v^>>^^<v<<<^<v<><^^v><<v^><<<<^vv<^<>^><vv<<<<^>>>^v>^v>vv>^v<>v>v<v><^>>v>>^>^><^<v^v^
module.exports = [
function(r,s,c) {
log("1");
c();
},
function(r,s,c) {
c();
log("2");
c();
},
.border-x(@args) {
border-top: @args;
border-bottom: @args;
}
.border-y(@args) {
border-right: @args;
border-left: @args;
}
.margin-x(@args) {
margin-top: @args;