| Models | Examples |
|---|---|
| Display ads | Yahoo! |
| Search ads |
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
| // SymSpell: 1000x faster through Symmetric Delete spelling correction algorithm | |
| // | |
| // The Symmetric Delete spelling correction algorithm reduces the complexity of edit candidate generation and dictionary lookup | |
| // for a given Damerau-Levenshtein distance. It is three orders of magnitude faster and language independent. | |
| // Opposite to other algorithms only deletes are required, no transposes + replaces + inserts. | |
| // Transposes + replaces + inserts of the input term are transformed into deletes of the dictionary term. | |
| // Replaces and inserts are expensive and language dependent: e.g. Chinese has 70,000 Unicode Han characters! | |
| // | |
| // Copyright (C) 2012 Wolf Garbe, FAROO Limited | |
| // Version: 1.6 |
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
| require 'net/http' | |
| class HttpClient | |
| def initialize(base_url, username = nil, password = nil) | |
| @base_url = base_url | |
| @username = username | |
| @password = password | |
| end | |
| def get(path, headers = {}) |
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
| #!/bin/sh | |
| ### | |
| # SOME COMMANDS WILL NOT WORK ON macOS (Sierra or newer) | |
| # For Sierra or newer, see https://github.com/mathiasbynens/dotfiles/blob/master/.macos | |
| ### | |
| # Alot of these configs have been taken from the various places | |
| # on the web, most from here | |
| # https://github.com/mathiasbynens/dotfiles/blob/5b3c8418ed42d93af2e647dc9d122f25cc034871/.osx |
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
| t = 236 # seconds | |
| Time.at(t).utc.strftime("%H:%M:%S") | |
| => "00:03:56" | |
| # Reference | |
| # http://stackoverflow.com/questions/3963930/ruby-rails-how-to-convert-seconds-to-time |
As configured in my dotfiles.
start new:
tmux
start new with session name:
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
| #!/bin/bash | |
| # remove __MACOSX foldr and .DS_Store files | |
| # from *_original.zip file | |
| # zip again and place under fixed/* | |
| for x in $* | |
| do | |
| unzip $x |
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
| # Convert Hashes to CSV easily | |
| # source.rb | |
| # | |
| # { valid: "ruby", hash: "" } | |
| # { another: "valid", ruby: "hash" } | |
| # { etc... | |
| # usage: | |
| # |
NewerOlder