Created
May 15, 2014 03:09
-
-
Save jwhiteman/3625a7479082e245bf71 to your computer and use it in GitHub Desktop.
Trolling twitter for 2-letter handles
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
require 'httparty' | |
include HTTParty | |
('aa'..'zz').select { |r| | |
sleep 0.20 | |
puts "trying #{r}" | |
self.class.head("https://twitter.com/#{r}").code == 404 | |
} | |
# => ['me', 'oh'] | |
# Sadly, 'me' and 'oh' both return 404s, but aren't available. Too bad. I would have enjoyed either one. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment