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
options(scipen = 20) | |
worst_case = (2 / 5) * 2^32 | |
(worst_cases = c(worst_case - 1, worst_case)) | |
(not_worst_cases = c((1 / 5) * 2^32, 1.5 * 2^32)) | |
(m_max = c(round(exp(10:21)), not_worst_cases, worst_cases)) | |
set.seed(3932354) | |
result = data.frame(m_max, lg_m_max = log(m_max), stat = NA) | |
for (m_i in 1:length(m_max)) { | |
x = sample(m_max[m_i], 1000000, replace = TRUE) |
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
Password: | |
Please wait, logging in... | |
Log in successful. | |
Starting at line 0. | |
Line: 50. Added: 50. Failed: 0. | |
Line: 100. Added: 100. Failed: 0. | |
Line: 150. Added: 150. Failed: 0. |
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
$ easy_install mechanize | |
$ wget http://downloads.sourceforge.net/libgmail/libgmail-0.1.11.tar.gz | |
$ tar zxvf libgmail-0.1.11.tar.gz | |
$ cd libgmail-0.1.11/; sudo python setup.py install | |
$ wget http://is.gd/kois | |
$ python gmail_add_emails.py data_sync_account@gmail.com one_email_per_line.txt |
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
#!/usr/bin/env python | |
# | |
# gmail_add_emails.py - Add a file of emails into a gmail contact list. | |
# | |
# Author: chrisken (at) ck37 com (hat tip to libgmail example code) | |
# | |
# License: GPL 2.0 | |
# | |
import os |