Skip to content

Instantly share code, notes, and snippets.

@wktk
Created April 6, 2012 10:30
Show Gist options
  • Save wktk/2318713 to your computer and use it in GitHub Desktop.
Save wktk/2318713 to your computer and use it in GitHub Desktop.
3 文字以下の取得可能 Twitter ユーザー名を探す
#!/usr/bin/perl -w
use strict;
use LWP::Simple;
my $target = 'http://twitter.com/users/username_available?username=';
my @range = ('a'..'x', '0'..'9', '_', '');
while (1) {
my $str;
$str .= $range[rand @range] foreach 0..2;
print '@'. $str. ' is '. (get($target. $str) =~ /"valid":true/ ? 'available!!!!!!!!!!' : 'unavailable.'). "\n";
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment