Skip to content

Instantly share code, notes, and snippets.

@fgnass
fgnass / LICENSE.txt
Created September 28, 2011 10:53 — forked from p01/LICENSE.txt
Sudoku Solver in 140bytes
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2011 Mathieu 'p01' Henri <http://www.p01.org/releases/>
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
@tylerhall
tylerhall / SFBestGuess.h
Created September 25, 2011 19:21
By inspecting the user's address book and finding the most common city, state, and zip code - we can make an educated guess as to the user's location without using CoreLocation.
#import <Foundation/Foundation.h>
#import <AddressBook/AddressBook.h>
@interface SFBestGuess : NSObject {
NSMutableArray *_cities;
NSMutableArray *_states;
NSMutableArray *_zipCodes;
}
@property (nonatomic, retain) NSMutableArray *cities;
@lwe
lwe / brew-more.rb
Created July 14, 2010 08:53
Try to scrape formula information from @formula.homepage.
# Small utility which uses the homepage and nokogori to get a description from the formula's homepage.
#
# As written in the homebrew wiki:
# > Homebrew doesn’t have a description field because the homepage is always up to date,
# > and Homebrew is not. Thus it’s less maintenance for us. To satisfy the description
# > we’re going to invent a new packaging microformat and persuade everyone to publish
# > it on their homepage.
#
# Too bad no packaging microformat has yet been invented, but brew-more just first looks for a
# `<meta name="description">` tag, then for an `a#project_summary_link` tag (which is used in