This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
" Basic configuration. | |
set nomodeline " for security reasons | |
set nocompatible " be iMproved, required | |
filetype off " required | |
" set the runtime path to include Vundle and initialize | |
set rtp+=~/.vim/bundle/Vundle.vim | |
call vundle#begin() | |
" alternatively, pass a path where Vundle should install plugins | |
"call vundle#begin('~/some/path/here') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## Status bar design | |
# status line | |
set -g status-justify left | |
set -g status-bg default | |
set -g status-fg colour12 | |
set -g status-interval 2 | |
# messaging | |
set -g message-fg black | |
set -g message-bg yellow |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// attributes of a song | |
// song | |
const song = { | |
// artist | |
artist: { | |
firstName: 'Herbie', | |
lastName: 'Hancock', | |
}, | |
title: 'Stars in Your Eyes', |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* | |
* Hoisting... | |
* | |
* In es5 and es6 variables are hoisted. This means that the interpreter | |
* parses files or code for variable declarations and moves them to the | |
* top of the top of their respective scopes, or "hoists" them. | |
* Variables are declared automatically, but may or may not be initialized | |
* based on how the user wites their code. Initially, any variable that is not | |
* assigned is given the default value of `undefined`, i.e typeof === 'undefined'. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* All men are mortal | |
* Socrates is a man. | |
* Therefore, socrates is mortal. | |
*/ | |
const Man = function(name) { | |
this.name = name; | |
}; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* All men are mortal | |
* Socrates is a man. | |
* Therefore, socrates is mortal. | |
*/ | |
const Man = function(name) { | |
this.name = name; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const timeAdder = (value1, label1, value2, label2) => { | |
if (typeof value1 !== "number" || typeof value2 !== "number") { | |
console.log("Values must be numbers"); | |
return false; // must be numbers | |
} | |
if (/\./.test(value1) || /\./.test(value2)) { | |
console.log("Values must be integers"); | |
return false; // must be integers | |
} | |
if (value1 < 0 || value2 < 0) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const fizzbuzz = () => { | |
let index = 0, max = 100, log = ''; | |
const initialPrimes = [2, 3, 5, 7, 11]; | |
for (; index < max; index++) { | |
if ((index !== 1 && initialPrimes.indexOf(index) !== -1) || | |
(index !== 1 && | |
index % 2 !== 0 && | |
index % 3 !== 0 && | |
index % 5 !== 0 && | |
index % 7 !== 0)) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<head> | |
<title>DOM Homework Page</title> | |
<style> | |
#rectangleWrapper { | |
padding-top: 50px; | |
padding-left: 50px; | |
padding-right: 50px; | |
padding-bottom: 0; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<head> | |
<title>Tic-Tac-Toe</title> | |
<script src="tic-tac-toe.js"></script> | |
<link rel="stylesheet" type="text/css" href="tic-tac-toe.css"> | |
</head> | |
<body> | |
<h1>Tic-Tac-Toe</h1> | |
<div id="board"> | |
<div class="row"> |
OlderNewer