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 hooks(hooksTitle, hooksMessage, hooksApi){ | |
var data = { hooksTitle: hooksTitle, hooksMessage: hooksMessage, hooksApi: hooksApi }; | |
body = ""; | |
for (var key in data){ | |
body += key + "=" + encodeURIComponent(data[key]) + "&"; | |
} | |
body = body.substring(0, body.length - 1); | |
var req = new XMLHttpRequest; |
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
.gotcha { | |
width: 100%; | |
} | |
.gotcha:after { | |
content: "OPT OUT OF OUR WEEKLY NEWSLETTER"; | |
padding-left: 40px; | |
} | |
.gotcha:checked:after { |
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
{ | |
"Version": "2012-10-17", | |
"Statement": [ | |
{ | |
"Effect": "Allow", | |
"Action": [ | |
"s3:DeleteObject", | |
"s3:DeleteObjectVersion", | |
"s3:ListBucket", | |
"s3:PutObject", |
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.prototype.myCall = function (context) { | |
var args = Array.prototype.slice.call(arguments, 1); | |
return this.apply(context, args); | |
} | |
sayHello = function (greeter, greetie) { | |
var message = greeter + " says hello to " + greetie + " from " + this; | |
console.log(message); | |
} |
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
first = (promises...) -> | |
out = $q.defer() | |
for promise in promises | |
promise.then(out.resolve, out.reject) | |
out | |
timeoutIn = (delay) -> | |
$timeout(-> 'timed out', delay) |
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
queue = []; | |
function send(data){ | |
queue.push(data); | |
setTimeout(flush); | |
} | |
function flush(){ | |
if (queue.length){ | |
actuallyMakeRequest(queue); |
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
javascript:(function()%7B(function()%7Bvar%20a%2Cb%2Cc%2Cd%2Ce%2Cf%3Ba%3D%22table%5Bdata-sortable%5D%22%2Cc%3D%2F%5E-%3F%5B%C2%A3%24%C2%A4%5D%3F%5B%5Cd%2C.%5D%2B%25%3F%24%2F%2Cf%3D%2F%5E%5Cs%2B%7C%5Cs%2B%24%2Fg%2Ce%3D%22ontouchstart%22in%20document.documentElement%2Cb%3De%3F%22touchstart%22%3A%22click%22%2Cd%3D%7Binit%3Afunction(b)%7Bvar%20c%2Ce%2Cf%2Cg%2Ch%3Bfor(null%3D%3Db%26%26(b%3D%7B%7D)%2Cnull%3D%3Db.selector%26%26(b.selector%3Da)%2Ce%3Ddocument.querySelectorAll(b.selector)%2Ch%3D%5B%5D%2Cf%3D0%2Cg%3De.length%3Bg%3Ef%3Bf%2B%2B)c%3De%5Bf%5D%2Ch.push(d.initTable(c))%3Breturn%20h%7D%2CinitTable%3Afunction(a)%7Bvar%20b%2Cc%2Ce%2Cf%2Cg%3Bif(1%3D%3D%3Da.tHead.rows.length%26%26%22true%22!%3D%3Da.getAttribute(%22data-sortable-initialized%22))%7Bfor(a.setAttribute(%22data-sortable-initialized%22%2C%22true%22)%2Ce%3Da.querySelectorAll(%22th%22)%2Cb%3Df%3D0%2Cg%3De.length%3Bg%3Ef%3Bb%3D%2B%2Bf)c%3De%5Bb%5D%2C%22false%22!%3D%3Dc.getAttribute(%22data-sortable%22)%26%26d.setupClickableTH(a%2Cc%2Cb)%3Breturn%20a%7D%7D |
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
using System; | |
using System.Collections.Generic; | |
using System.Text; | |
class MyClass { | |
public void compute_palindromes(string[] words) { | |
// Write your code here | |
// To print results to the standard output you can use Console.WriteLine() | |
// Example: Console.WriteLine("Hello world!"); | |
foreach(string word in words) { | |
Dictionary<char, int> dict = createWordDict(word); |
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 d = document.createElement('div'); | |
d.innerHTML = '\ | |
<style>\ | |
*:not(.icon):not(i), *:not(.icon):not(i):after, *:not(.icon):not(i):before {\ | |
box-shadow: none !important;\ | |
text-shadow: none !important;\ | |
background-image: none !important;\ | |
}\ | |
*:not(.icon):not(i) {\ | |
border-color: transparent !important;\ |
This file has been truncated, but you can view the full file.
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
<pre style="font: 10px/5px monospace;"><span style="color: #c5a479;"></span><span style="color: #be9f71;">#</span><span style="color: #d6b191;">#</span><span style="color: #dcb898;">#</span><span style="color: #cfae9d;">#</span><span style="color: #c5a79a;">#</span><span style="color: #c8ab9c;">#</span><span style="color: #cbae9f;">#</span><span style="color: #caaf9f;">#</span><span style="color: #cab1a3;">#</span><span style="color: #c5b0a3;">#</span><span style="color: #c7b3a5;">#</span><span style="color: #cbb5a7;">#</span><span style="color: #cdb6a8;">#</span><span style="color: #cfb8a7;">#</span><span style="color: #d4baab;">#</span><span style="color: #d5bbad;">#</span><span style="color: #d8bcae;">#</span><span style="color: #d7bcac;">#</span><span style="color: #dabfae;">#</span><span style="color: #dbc0ab;">#</span><span style="color: #dac0ab;">#</span><span style="color: #dbc1b2;">#</span><span style="color: #ddc2b3;">#</span><span style="color: #dcc0b5;">#</span><span style="color: #ddc2b7;">#</spa |