Skip to content

Instantly share code, notes, and snippets.

View dedicatedfuture's full-sized avatar

Bill Zerega dedicatedfuture

View GitHub Profile
@dedicatedfuture
dedicatedfuture / index.html
Last active September 4, 2015 14:13 — forked from anonymous/index.html
zvxRVL
<link href="http://fonts.googleapis.com/css?family=Cardo:400,400italic|Radley|Tangerine" rel="stylesheet">
<h1>Random Quotes Rewritten</h1>
<p> These are some of my favorite quotes I had collected during medical school I recently rediscovered via the wayback machine. I hope you enjoy them!</p>
<button class=button>New Quote</button>
<div class="quote"><span class = "saying"></span><br>
<span class= "author"></span></div>
<div class=link><a href="http://web.archive.org/web/20020204185254/http://www.pitt.edu/~smast27/">Original Site</a></div>
function inventory(arr1, arr2) {
// All inventory must be accounted for or you're fired!
arr2.forEach(function(a, i1){
var index = -1;
arr1.forEach(function(b, i2){
if(b[1] === a [1]){
index = i2;
}
});
if(index !== -1){
function friendly(str) {
var months = ['January', 'February', 'March', 'April', 'May', 'June', 'July', 'August', 'September', 'November', 'December'];
var suffix = function(day){
if(day === 1 || day ===21) day += 'st';
else if(day === 2|| day ===22) day += 'nd';
else if(day ===3 || day ===23) day += 'rd';
else day += 'th';
return day;
};
function factorilize(num){
var n = 1;
for(var i = 2; i <= num; i++){
n *= i;
}
return n;
}
var permArr = [], usedChar = [];
function telephoneCheck(str) {
// Good luck!
var valid = false;
if(!str.match(/^\([^\(\)]{10}\)$/g)){
if(!str.match(/^\-/g)){
var reg = /[^0-9]/g;
str = str.replace(reg, "");
if(str.length ===10){
valid = true;
}else if(str.length === 11){