-
Notifications
You must be signed in to change notification settings - Fork 10
Expand file tree
/
Copy pathapp.py
More file actions
52 lines (38 loc) · 2.47 KB
/
app.py
File metadata and controls
52 lines (38 loc) · 2.47 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
# 1. As a valued customer at the Bank of Honolulu, you make a deposit of $1000.
# Your savings account balance prior to the deposit has an amount of $8000.
# Calculate the new savings account balance.
# Print the new savings account balance and concatenate the dollar sign.
# 2.You need to pay taxes on the $500 cash prize that you won to the IRS ( The tax rate is 30%).
# Calculate the tax amount and subtract this from your savings balance.
# Print the updated savings account balance and concatenate the dollar sign.
# 3. The savings account accrues an annual interest rate of 2%.
# Calculate the interest earned for the first quarter of 2018,
# using the original account balance from Question 1.
# Print the interst earned in the first quarter and concatenate the dollar sign.
# 4. Function add
# Create a function that will take two parameters named num1 and num2.
# This function will add two numbers. Print your result.
# 5. Function subtract
# Create a function that will take two parameters named num1 and num2.
# This function will subtract two numbers. Print your result.
# 6. Function add-then-subtract
# Create a function that will take in three parameters named num1, num2 and num3.
# The function will sum up the first two parameters (num1 and num2) and subtract it from the third parameter (num3).
# Please use your previous functions (i.e. add or subtract) for this exercise. Print your result.
# 7. Function shoe size
# Create a function that will take in a parameter named inches.
# This function will convert inches to centimeters(cm). Print your result.
# 8. Create a function that will take in a parameter named cel.
# The function will convert Celsius into Fahrenheit. Print your result.
# 9. Function all caps
# Create a function that will take in a parameter named str.
# This function will capitalize all the letters in the string. Print your result.
# 10. Function one cap
# Create a function that will take in a parameter named str.
# The function will capitalize only the first letter in the string. Print your result.
# 11. Use the extend method to combine the following lists together. Print your result.
east_side = ['Biggie', 'Nas', 'Wu-Tang Clan']
west_side = ['Tupac', 'Dre', 'Snoop']
# 12. Use the clear method to remove all items from the following list. If you are using Python 2 or 3.2, use the del operator instead. Print your result.
haters = ['Keyshia Cole', 'Wendy Williams', '50 Cent', 'Lil Kim']
# 13. Create a function that will print that last digit of an integer.