start new:
tmux
start new with session name:
tmux new -s myname
// Adapted from generic web server example as part of IDE created by David Mellis and Tom Igoe. | |
#include "Arduino.h" | |
#include <Ethernet.h> | |
#include <SPI.h> | |
#include <string.h> | |
#include <stdlib.h> | |
#define DEBUG false |
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta name="description" content="JavaScript Refresher"> | |
<meta charset="utf-8"> | |
<title>JS Bin</title> | |
<style id="jsbin-css"> | |
p { | |
color: red; | |
} |
Book the First -- Recalled to Life | |
Chapter I | |
The Period | |
It was the best of times, it was the worst of times, it was the age of | |
wisdom, it was the age of foolishness, it was the epoch of belief, it | |
was the epoch of incredulity, it was the season of Light, it was the | |
season of Darkness, it was the spring of hope, it was the winter of |
The sample text is here: https://gist.github.com/0474c33e403ab243019c | |
Undo justification: replace all newline characters with two spaces | |
regex: "\n\b" | |
subst: "\ \ " | |
Replace all paragraph markers with actual paragraphs | |
regex: "-P-" |
The IPython Notebook has two different keyboard input modes. Edit mode allows you to type code/text into a cell and is indicated by a green cell border. Command mode binds the keyboard to notebook level actions and is indicated by a grey cell border.
This list is meant to be a both a quick guide and reference for further research into these topics. It's basically a summary of that comp sci course you never took or forgot about, so there's no way it can cover everything in depth. It also will be available as a gist on Github for everyone to edit and add to.
###Array ####Definition:
// | |
public boolean isUgly(int num) { | |
if (num == 0) return false; | |
while (num % 2 == 0) num /= 2; | |
while (num % 3 == 0) num /= 3; | |
while (num % 5 == 0) num /= 5; | |
return num == 1; | |
} | |
// | |
public boolean isUgly(int num) { |
package recfun | |
import scala.collection.mutable.ListBuffer | |
import common._ | |
/** https://class.coursera.org/progfun-2012-001/assignment/view?assignment_id=4 */ | |
object Main { | |
def main(args: Array[String]) { | |
println("Pascal's Triangle") | |
for (row <- 0 to 10) { |
# @param A : A List of integers | |
# @return List of integers | |
def wave(A): | |
A.sort() | |
i = 0 | |
while i < len(A) : | |
if i + 1 < len(A) : | |
A[i], A[i+1] = A[i+1], A[i] | |
i = i + 2 | |
else : |