Skip to content

Instantly share code, notes, and snippets.

View wofockham's full-sized avatar
💭
raging at Microsoft

wofockham

💭
raging at Microsoft
View GitHub Profile
@env = { :label => proc { |(name,val), _| @env[name] = eval(val, @env) },
:car => lambda { |(list), _| list[0] },
:cdr => lambda { |(list), _| list.drop 1 },
:cons => lambda { |(e,cell), _| [e] + cell },
:eq => lambda { |(l,r), ctx| eval(l, ctx) == eval(r, ctx) },
:if => proc { |(cond, thn, els), ctx| eval(cond, ctx) ? eval(thn, ctx) : eval(els, ctx) },
:atom => lambda { |(sexpr), _| (sexpr.is_a? Symbol) or (sexpr.is_a? Numeric) },
:quote => proc { |sexpr, _| sexpr[0] } }.merge(ext)
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>static.</title>
<link rel="stylesheet" href="static.css">
<script src="static.js"></script>
</head>
<body>

Article Title

Subheading level 1

Hello you stupid little world.

I find that offensive.

Here is emphasis and different emphasis.

Wordy Addition

Write a program that takes a word problem in the format:

What is 5 plus 13?

and returns the answer as an integer.

The program should handle large numbers and negative numbers.

Some caption

Groucho

Harpo

Chico

Some paragraph of text.

require 'minitest/autorun'
require 'minitest/pride'
require 'pry'
require_relative './nucleotide'
class DNATest < MiniTest::Test
def test_empty_dna_string_has_no_adenosine
# skip
assert_equal 0, DNA.new('').count('A')
end
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>United Document</title>
<link rel="stylesheet" href="plasma.css">
</head>
<body>
<canvas id="plasma" width="255" height="160"></canvas>
<script src="plasma.js"></script>
var x = 10; // This is a comment
if (x > 5) {
  console.log('hello world');
}

var x = 10; // This is a comment if (x > 5) { console.log('hello world');

@wofockham
wofockham / ffs
Last active July 12, 2016 01:40 — forked from tobyturnbullknokal/ffs
// Increase/decrease progress bar on button click
$(document).ready(function() {
$('.appbutton').on('click', function(){
var currentVal = $('#signup-progress').val();
currentVal += 10;
$('#signup-progress').val(currentVal); // Actually update the input?
console.log(currentVal)
});
});