This file contains 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
body {background: #ccc;} | |
* {box-sizing:border-box;} | |
#container {width:300px;background:#eee;margin:0 auto} | |
.item {height:150px; width: 100px; background: white; | |
border:1px solid #ddd;line-height:50px;text-align:center;font-family:sans-serif;color:#ccc; font-size:20px;color:black;} | |
.item:after {color:gray;font-size:10px;} | |
.item.one-by-one:after {content:"1x1"} | |
.item.one-by-two {width:200px;} | |
.item.one-by-two:after {content:"1x2"} | |
.item.two-by-two {width:200px;height:300px;line-height:200px;} |
This file contains 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
sudo apt-get install build-essential libsqlite3-dev zlib1g-dev libncurses5-dev libgdbm-dev libbz2-dev libreadline5-dev libssl-dev libdb-dev | |
wget http://www.python.org/ftp/python/2.7.3/Python-2.7.3.tgz | |
tar -xzf Python-2.7.3.tgz | |
cd Python-2.7.3 | |
./configure --prefix=/usr --enable-shared | |
make | |
sudo make install | |
cd .. |
This file contains 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
!!! 5 | |
/[if lt IE 7] <html class="no-js ie6 oldie" lang="en"> | |
/[if IE 7] <html class="no-js ie7 oldie" lang="en"> | |
/[if IE 8] <html class="no-js ie8 oldie" lang="en"> | |
<!--[if gt IE 8]><!--> | |
%html.no-js{ :lang => "en" } | |
<!--<![endif]--> | |
%head | |
= render :partial => "/layouts/additional_meta" | |
<<<<<<< HEAD |
This file contains 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
# Black-Scholes Option Value | |
# Call value is returned in values[1], put in values[2] | |
blackscholes <- function(S, X, rf, T, sigma) { | |
values <- c(2) | |
d1 <- (log(S/X)+(rf+sigma^2/2)*T)/sigma*sqrt(T) | |
d2 <- d1 - sigma * sqrt(T) | |
values[1] <- S*pnorm(d1) - X*exp(-rf*T)*pnorm(d2) | |
values[2] <- X*exp(-rf*T) * pnorm(-d2) - S*pnorm(-d1) | |
values | |
} |
This file contains 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
for(i in 1:7) mean(rnorm(N)) |
This file contains 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
R version 2.14.2 (2012-02-29) | |
Copyright (C) 2012 The R Foundation for Statistical Computing | |
ISBN 3-900051-07-0 | |
Platform: i386-apple-darwin9.8.0/i386 (32-bit) | |
R is free software and comes with ABSOLUTELY NO WARRANTY. | |
You are welcome to redistribute it under certain conditions. | |
Type 'license()' or 'licence()' for distribution details. |
This file contains 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
<?php | |
$key = 'our passphrase here'; | |
$hash = 'f8956ba8af19b58e6a92e234abfebf13'; | |
// Encryption function we'll use on our side. This would be retrieved as $_POST['signature'] on your side. | |
$signature = base64_encode(mcrypt_encrypt(MCRYPT_RIJNDAEL_256, md5($key), $hash, MCRYPT_MODE_CBC, md5(md5($key)))); | |
$decrypted = rtrim(mcrypt_decrypt(MCRYPT_RIJNDAEL_256, md5($key), base64_decode($signature), MCRYPT_MODE_CBC, md5(md5($key))), "\0"); | |
if($hash == $decrypted) |
This file contains 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
<table border="0" cellspacing="5" cellpadding="5" style="border:0;border-collapse:collapse;"> | |
<tr><th colspan="2">Live Barclays Premier League</th></tr> | |
<tr><td>Bolton v Liverpool</td><td>Saturday, 21st January, 4:30pm</td></tr> | |
<tr><th colspan="2">Clydesdale Bank Premier League</th></tr> | |
<tr><td>Dunfermline v Celtic</td><td>Monday, 2nd January, 2:30pm</td></tr> | |
<tr><td>Bolton v Liverpool</td><td>Saturday, 21st January, 4:30pm</td></tr> | |
<tr><td>Bolton v Liverpool</td><td>Saturday, 21st January, 4:30pm</td></tr> | |
<tr><td>Bolton v Liverpool</td><td>Saturday, 21st January, 4:30pm</td></tr> |
This file contains 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
// TemperatureConverterGUI.java | |
// Author: Laurencia Walker-Fooks | |
// Program last changed: 7 December 2011 | |
import java.awt.*; | |
import java.awt.event.*; | |
import javax.swing.*; | |
import java.awt.event.ActionListener; | |
public class TemperatureConverterGUI extends JFrame |