Skip to content

Instantly share code, notes, and snippets.

View quigebo's full-sized avatar

Stephen Wooten quigebo

View GitHub Profile
import Foundation
import XCPlayground
XCPlaygroundPage.currentPage.needsIndefiniteExecution = true
let searchTerm = "philip+glass"
let url = NSURL(string: "https://itunes.apple.com/search?term=\(searchTerm)")
let request: NSURLRequest = NSURLRequest(URL: url!)
let session = NSURLSession.sharedSession()
let task: NSURLSessionDataTask = session.dataTaskWithRequest(request, completionHandler: {

Keybase proof

I hereby claim:

  • I am quigebo on github.
  • I am quigebo (https://keybase.io/quigebo) on keybase.
  • I have a public key whose fingerprint is A1E3 245D 5635 6860 93CC D44E 5479 BB4E 1DBB CA24

To claim this, I am signing this object:

### Keybase proof
I hereby claim:
* I am quigebo on github.
* I am quigebo (https://keybase.io/quigebo) on keybase.
* I have a public key whose fingerprint is 88F0 A1AC 1D77 C9B2 448D BDC9 EF22 FEEE D671 40F7
To claim this, I am signing this object:
@quigebo
quigebo / 0_reuse_code.js
Created June 11, 2014 19:45
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
// in document ready, obviously
$('body').bind('activate', function() {
alert('zomg bo');
});
module CalorieCalculator
def caloric_need
caloric_need_without_goal + calorie_need
end
private
# formula from http://www.bodybuilding.com/fun/issa64.htm
def caloric_need_without_goal
(weight * gender_multiplier * weight_multiplier * bodyfat_multiplier * activity_multiplier).round