This is a test component made in ember twiddle. To edit this component, go here: https://ember-twiddle.com/24863d7b4c2f7a912bfa7d5b9e0f3b3b
By using Google Form's script editor, you can call Slack webhooks when form submissions are made. You can use this script to do things like creating a live feedback form for taking questions from an audience or notifying your team when someone signs up for an event.
First, be sure you're collecting the email address in the form:
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 amqp = require('amqplib/callback_api'); | |
// if the connection is closed or fails to be established at all, we will reconnect | |
var amqpConn = null; | |
var pubChannel = null; | |
var offlinePubQueue = []; | |
var mq = { | |
// Main start |
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
# This is supposedly what CRIME by Juliano Rizzo and Thai Duong will do | |
# Algorithm by Thomas Pornin, coding by xorninja, improved by @kkotowicz | |
# http://security.blogoverflow.com/2012/09/how-can-you-protect-yourself-from-crime-beasts-successor/ | |
import string | |
import zlib | |
import sys | |
import random | |
charset = string.letters + string.digits + "%/+=" |
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
# Towers of Hanoi | |
# | |
# Write a Towers of Hanoi game: | |
# http://en.wikipedia.org/wiki/Towers_of_hanoi | |
# | |
# In a class `TowersOfHanoi`, keep a `towers` instance variable that is an array | |
# of three arrays. Each subarray should represent a tower. Each tower should | |
# store integers representing the size of its discs. Expose this instance | |
# variable with an `attr_reader`. | |
# |
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
Spend no more than 2 hours building a Rails (or Sinatra) app that allows the player to play a game of tic-tac-toe. This should be for 2 human players, so no AI is needed (unless you wanted to make this harder for yourself). | |
Don't worry about views, in fact, we'd specifically like for it to render a readable plain text response in the response body. We should be able to play by just CURLing api. Moves can be made by postings the player (x or o) to positions like 0,2. | |
Please post the project to Github as you work. |
I hereby claim:
- I am jpsilvashy on github.
- I am jpsilvashy (https://keybase.io/jpsilvashy) on keybase.
- I have a public key whose fingerprint is 3113 805F 8E68 1E41 E6EA 2AFD 84D3 466E 3F7B EA1F
To claim this, I am signing this object:
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
" Learn vim navigation! | |
nnoremap <Left> :echoe "Use h"<CR> | |
nnoremap <Right> :echoe "Use l"<CR> | |
nnoremap <Up> :echoe "Use k"<CR> | |
nnoremap <Down> :echoe "Use j"<CR> |
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
#!/bin/sh | |
# Some things taken from here | |
# https://github.com/mathiasbynens/dotfiles/blob/master/.osx | |
# Set the colours you can use | |
black='\033[0;30m' | |
white='\033[0;37m' | |
red='\033[0;31m' | |
green='\033[0;32m' |
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
def clock_angles(time) | |
hour, min = time.split(":").map(&:to_i) | |
ans = ((hour * 30 + min * 0.5) - (min * 6)).abs | |
[360 - ans, ans].min | |
end |