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
import java.io.InputStream; | |
import java.io.InputStreamReader; | |
import java.net.URL; | |
import java.util.Scanner; | |
public class Lucky | |
{ | |
public static int winnings(int bet) throws Exception | |
{ | |
return "13".equals(new Scanner(((InputStream) new URL("http://roulette.engineyard.com/").getContent())).findInLine("\\d+")) ? bet * 35 : 0; |
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
var tls = require('tls'); | |
var fs = require('fs'); | |
var Buffer = require('buffer').Buffer; | |
var zlib = require('zlib'); | |
var BufferList = require('bufferlist'); | |
var Binary = require('bufferlist/binary'); | |
var Put = require('put'); | |
var http = require('http'); | |
var options = |
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
# | |
# Get development tools installed | |
# | |
sudo yum install -y git cvs zlib-devel | |
sudo yum groupinstall -y "Development Tools" | |
# | |
# Install RVM | |
# | |
bash < <(curl -s https://rvm.beginrescueend.com/install/rvm) |
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
function gapagespeed($push) | |
{ | |
$push[] = "'_trackPageLoadTime'"; | |
return $push; | |
} | |
add_filter( 'yoast-ga-push-after-pageview', 'gapagespeed' ); |
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
=== CLEAN AGGREGATE TARGET ZERO_CHECK OF PROJECT mruby WITH THE DEFAULT CONFIGURATION (Debug) === | |
Check dependencies | |
Clean.Remove clean build/mruby.build/Debug/ZERO_CHECK.build | |
builtin-rm -rf /tmp/mruby/build/mruby.build/Debug/ZERO_CHECK.build | |
=== CLEAN NATIVE TARGET xpcat OF PROJECT mruby WITH THE DEFAULT CONFIGURATION (Debug) === | |
Check dependencies |
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
function createCORSRequest(method, url) | |
{ | |
var xhr = new XMLHttpRequest(); | |
if ("withCredentials" in xhr) | |
{ | |
xhr.open(method, url, true); | |
} | |
else if (typeof XDomainRequest != "undefined") | |
{ | |
xhr = new XDomainRequest(); |
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
set -g default-terminal "screen-256color" | |
set -g history-limit 20000 | |
# Set the prefix to ^A. | |
unbind C-b | |
set -g prefix ^A | |
bind a send-prefix | |
# Bind appropriate commands similar to screen. | |
# lockscreen ^X x |
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
class Bar | |
def initialize(name) | |
@name = name | |
@x = 0 | |
@y = 0 | |
end | |
def name | |
@name | |
end |
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
{ | |
map: function (doc) | |
{ | |
if(doc.text.indexOf("RT ") != -1 || doc.text.indexOf("RT:") != -1 || | |
doc.text.indexOf("rt ") != -1 || doc.text.indexOf("rt:") != -1) | |
{ | |
return; | |
} | |
function pre_replacements(obj) |
OlderNewer