Created
December 12, 2015 13:23
-
-
Save thewhitetulip/ba0bddf61fc5c1ad1970 to your computer and use it in GitHub Desktop.
A simple python script to to create links to download shareholder letts of bershire hathaway
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
start_year = 1977 | |
end_year = 2015 | |
ltr_year = 2004 | |
link = "http://berkshirehathaway.com/letters/" | |
for i in range(start_year, end_year): | |
if i <ltr_year: | |
print(link+str(i)+".html") | |
else: | |
print(link+str(i)+"ltr.pdf") | |
####this will print the links of the annual letters, now use a file downloader like wget to download the files | |
#### save this to a file.txt and run `wget -i file.txt` and you are done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment