Skip to content

Instantly share code, notes, and snippets.

@f3r
f3r / wdi_hk_p1.md
Last active August 29, 2015 14:24
WDI Project1 Guidelines

WDI Project #1

The Game


Let's start out with something fun - Your own game!!

@f3r
f3r / gist:4db341f5e624f56908f3
Created May 11, 2015 04:02
visibility-test.rb
class ParentClass
def public_method
puts '[works] parent # public'
protected_method
end
protected # Can only be called from within the methods
def protected_method
puts '[works] parent # protected'
end
@f3r
f3r / HackerMission-Solution.md
Last active August 29, 2015 14:18
WDI-HK-7::HackerMission-Solution

Here is the Student Asessment

Mission Brief

Morning 007s.

Your mission, should you choose to accept it, is to identify and eliminate the hacker who breached our secure data centers.

@f3r
f3r / HackerMission.md
Created April 8, 2015 03:29
WDI-HK-7::HackerMission

Mission Brief

Morning 007s.

Your mission, should you choose to accept it, is to identify and eliminate the hacker who breached our secure data centers.

All the identities of your fellow WDI agents will be open and they will all be in great danger if we don't react fast.

Our security records indicate this following log access to the servers

@f3r
f3r / standup.md
Created April 8, 2015 03:25
WDI-HK-7::MorningStandup
______________$$$$$____________________________________________________ WDI 7 - Hong Kong
__$$$$_______$$$___$$$$$______________________________________________ Tue, March 31 2015
_$$$$$$_____$$$___$$$$$$$________________________________________________________________
$$$_$$$$___$$$__$$$$____$________________________________________________________________
$____$$$$_$$$$_$$$_______________________________________________________________________
_______$$$$$$$$$$___$$$$$________________________________________________________________
____$$$$$$$$$$$$_$$$$_$$$$$______________________________________________________________
___$$$$$$$$$$$$$$$$$_____$$$_____________________________________________________________
__$$$__$$$$$$$$$$$$________$_____________________________________________________________
@f3r
f3r / areYouAnObject.js
Created February 12, 2015 11:41
Everything is an object!
var stuff = [42, "forty-two", [], {}, (function(){}) ];
var isAnObject = false;
for(var i=0; i < stuff.length; i++) {
isAnObject = stuff[i] instanceof Object;
console.log(stuff[i].constructor + ' instanceof Object? ' + isAnObject);
}
@f3r
f3r / bindingBehaviour.js
Last active August 29, 2015 14:15
Binding Behaviour quiz :)
loggest('Let\'s get the party STARTED');
function loggest(txt){
var length = (txt.length + 2);
if (length > 80) { length = 80 };
console.log(txt); console.log(new Array(length + 2).join('-'));
}
function bindBehavior(config) {
@f3r
f3r / apis.md
Last active August 29, 2015 14:10
APIs Intro
@f3r
f3r / bmi.coffee
Created November 15, 2014 10:48
bmi calculator
cal_bmi = (weight_kg, height_cm) ->
height_m = height_cm/100
bmi = weight_kg / (height_m * height_m)
f_bmi = Math.floor(bmi)
diff = Math.round((bmi - f_bmi) * 10)
if diff == 10 # Need to bump up the whole thing instead
f_bmi += 1
diff = 0
@f3r
f3r / return.js
Created November 2, 2014 23:25
5-min Quiz - Javascript return
///
// https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/return
//
// $ brew update && install node
// $ node return.js
//
var print = function(t){ console.log(t) };
var counter = function() {