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
// undeclared function you need to declare: | |
// cb(data): fired when new data from the stream is available. | |
// data is the updated line. use JSON.parse to parse data. | |
// hungup(): fired when the user stream is disconnected. | |
// this function needs to handle it. maybe retry or display error. | |
// undeclared variables you need to declare. | |
// url: user stream's url endpoint. | |
var xh = new XMLHttpRequest(); |
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
(function() { | |
var factor = 0.25; | |
var _Date = Date; | |
var _setTimeout = setTimeout; | |
var _setInterval = setInterval; | |
var start = new _Date().getTime(); | |
Date = function(a,b,c,d,e,f,g) { | |
if (arguments.length == 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
<?php | |
define ('CONSUMER_KEY', '__________'); | |
define ('CONSUMER_SECRET', '__________'); | |
define ('ACCESS_TOKEN', '__________'); | |
define ('ACCESS_TOKEN_SECRET', '__________'); |
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
/* | |
LANG: C | |
TASK: oct14_sort | |
*/ | |
#include <stdio.h> | |
#include <stdlib.h> | |
int canwn; | |
int ladab_khxng_canwn[1000]; | |
void rabkha(int cak, int thung) { | |
if (cak >= thung) return; |
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
<?php | |
function thai($x) { | |
$back = array( | |
"\xE0\xB9\x88" => "\xEF\x9C\x85", | |
"\xE0\xB9\x89" => "\xEF\x9C\x86", | |
"\xE0\xB9\x8A" => "\xEF\x9C\x87", | |
"\xE0\xB9\x8B" => "\xEF\x9C\x88", | |
"\xE0\xB9\x8C" => "\xEF\x9C\x89" | |
); |
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
>>> from pizza import pizza | |
>>> print ''.join([ '- ' + crust['name'] + '\n' for crust in pizza.pizza.getAllCrustType('EN') ]) | |
- Thirty Bites Pizza(Promotion) | |
- Thirty Bites Pizza | |
- Pan Pizza | |
- Thin Crispy | |
- Cheesy Max | |
- Extreme Pizza | |
- Extra Cheesy Sausage Bites | |
- X-Pan |
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
/* FULL SCREEN MODE MOD! | |
replace 1280 and 800 with your screen size and do not zoom. | |
use F11 to go to full screen mode. | |
use ctrl+alt+c to edit custom CSS. | |
hidden/experimental feature. use at your own risk. */ | |
@media (min-width: 1280px) and (min-height: 800px) { | |
#head { | |
padding-bottom: 5px; | |
font-size: 16pt; |
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
from ctypes import * | |
bass = cdll.LoadLibrary('./libbass.so') | |
# init bass | |
bass.BASS_Init(-1, 44100, 0, 0, None) | |
# load sample | |
file = '/path/to/wav/file.wav' | |
sample = bass.BASS_SampleLoad(False, file, c_longlong(0), 0, 2, 0x20000) |
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
fs = require 'fs' | |
sys = require 'sys' | |
(-> # force global scope | |
input = | |
if process.argv[2] | |
try | |
fs.readFileSync process.argv[2], 'utf-8' | |
catch e |