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/python | |
""" Calculate compounding interest on recurring expenses """ | |
import locale | |
locale.setlocale(locale.LC_ALL, "en_US") | |
# User configured parameters | |
years = 15 | |
interest = .05 |
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
INTEREST_RATE = [5, 7] | |
ANNUAL_SAVINGS = [40, 50, 60] | |
YEARS = [10, 15, 20] | |
def calculate_total(interest, savings, years): | |
interest = 1. + interest / 100. | |
return sum([savings * (interest ** i) for i in range(years)]) | |
for interest in INTEREST_RATE: | |
for savings in ANNUAL_SAVINGS: |
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
# Make sure we're up to date | |
apt-get -y update | |
apt-get -y dist-upgrade | |
# Some basic tools to get started | |
apt-get -y install vim-gtk build-essential | |
# Install and setup Git | |
apt-get -y install git | |
git config --global user.name "Martin Wozniewicz" |
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
/** Martin | |
* The first commented line is your dabblet’s title | |
*/ | |
background: #ffd; | |
background: -webkit-linear-gradient(45deg, #0a4, #09a); | |
min-height:100%; | |
color:white; | |
font-family:arial; |
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
/** Martin | |
* The first commented line is your dabblet’s title | |
*/ | |
background: #f06; | |
background: linear-gradient(45deg, #f06, yellow); | |
min-height:100%; | |
color:white; | |
font-family:arial; |