Skip to content

Instantly share code, notes, and snippets.

View samgiles's full-sized avatar
🗺️

Sam Giles samgiles

🗺️
  • Citymapper
  • London
View GitHub Profile
anonymous
anonymous / getTomorrowsdate.cpp
Created August 23, 2014 21:48
//get tomorrows date
int getTomorrowsDate(){
sleep(100*60*60*42);
getCurrentDate();
}
@samgiles
samgiles / flatMap.js
Created June 20, 2014 11:32
Javascript flatMap implementation
// [B](f: (A) ⇒ [B]): [B] ; Although the types in the arrays aren't strict (:
Array.prototype.flatMap = function(lambda) {
return Array.prototype.concat.apply([], this.map(lambda));
};