Skip to content

Instantly share code, notes, and snippets.

View jessegilbride's full-sized avatar

Jesse Gilbride jessegilbride

View GitHub Profile
@jaysonrowe
jaysonrowe / FizzBuzz.js
Created January 11, 2012 01:39
FizzBuzz JavaScript solution
for (var i=1; i <= 20; i++)
{
if (i % 15 == 0)
console.log("FizzBuzz");
else if (i % 3 == 0)
console.log("Fizz");
else if (i % 5 == 0)
console.log("Buzz");
else
console.log(i);
@samwize
samwize / mocha-guide-to-testing.js
Created February 8, 2014 05:53
Explain Mocha's testing framework - describe(), it() and before()/etc hooks
// # Mocha Guide to Testing
// Objective is to explain describe(), it(), and before()/etc hooks
// 1. `describe()` is merely for grouping, which you can nest as deep
// 2. `it()` is a test case
// 3. `before()`, `beforeEach()`, `after()`, `afterEach()` are hooks to run
// before/after first/each it() or describe().
//
// Which means, `before()` is run before first it()/describe()
@sergejmueller
sergejmueller / ttf2woff2.md
Last active March 9, 2024 13:37
WOFF 2.0 – Learn more about the next generation Web Font Format and convert TTF to WOFF2
@mbejda
mbejda / Industries.csv
Last active July 21, 2024 10:47
Compiled list of industries.
Industry
Accounting
Airlines/Aviation
Alternative Dispute Resolution
Alternative Medicine
Animation
Apparel/Fashion
Architecture/Planning
Arts/Crafts
Automotive
@luruke
luruke / smashingmagazine.js
Last active January 12, 2022 15:34
Source code of the demo "Improving User Flow Through Page Transitions" on Smashing Magazine.
/*
https://www.smashingmagazine.com/2016/07/improving-user-flow-through-page-transitions/
You can copy paste this code in your console on smashingmagazine.com
in order to have cross-fade transition when change page.
*/
var cache = {};
function loadPage(url) {
if (cache[url]) {
@tparveen
tparveen / Big_O_practice.md
Last active July 10, 2021 00:03
Big O exercises

Exercise: What's the complexity?

Implement the following algorithms and analyze its expected (average) and worst run time complexities. You should work through the functions one by one, making comments and identifying the complexity of each part of the algorithm. If you are unsure of how the algorithms scale, then try adding counter variables and incrementing them each time an operation takes place. By logging out the counters for different sizes of input you should be able to see a trend developing.

Exercise 1:

Write a program that determines if an input is even or odd. Explain its average and worst run time

Exercise 2:

Write a program that doubles every value in an array. Explain its average and worst run time

@chranderson
chranderson / nvmCommands.js
Last active July 26, 2024 20:22
Useful NVM commands
// check version
node -v || node --version
// list locally installed versions of node
nvm ls
// list remove available versions of node
nvm ls-remote
// install specific version of node
@cole007
cole007 / rogueone.md
Last active January 2, 2021 21:26
Why Rogue One is my favourite Star Wars film

Star Wars, socialism and twentieth century models of historiography [^1]

Warning: this brain dump contains spoilers for Rogue One

Earlier this week I took my son to see Rogue One when he was off school sick. I was hoping for a good film - I'm a big fan of Gareth Edwards' previous offerings Monsters and Godzilla, and of course a massive fan of the original Star Wars films - but I didn't have any particular expectations; especially as this was the first Star Wars film to sit outside the main canon (perhaps excluding Caravan of Courage).

What I wasn't expecting was to love it. It was a different take on a universe I had grown up loving, replete in the visual and auditory iconography of the original trilogy. But it had license to do things differently, from the score to the opening crawl. There were nods throughout to the original films that this preceded, and of course the plot

@aishydevil12286
aishydevil12286 / introrx.md
Created September 27, 2017 04:10 — forked from staltz/introrx.md
The introduction to Reactive Programming you've been missing
@NotSoSuper
NotSoSuper / numbers.txt
Last active May 14, 2024 20:30
almost all the police numbers in the U.S (to blacklist from calling services) prefix: +1
423-279-3200
440-564-7014
845-677-7300
904-266-4468
315-393-1555
918-423-5858
440-293-4555
701-577-1212
765-584-6891
863-291-5200