Is it just me? I'm having some serious difficulty with this course. I'm only on problem set 1, and the hints for the assignment are of absolutely no help. Then, question 2 of the assignment makes no sense to me. It seems like it's asking us to do things we haven't even been taught yet. I've been going through the suggested readings systematically but I still have no idea what the problem set is asking. Is this because my math skill is too low (only basic algebra), or am I missing something? Any advice is appreciated, getting *really* frustrated at this point. Thanks!
Servante, I think it's a little difficult to get going if you haven't had any programming experience before but once you pick up the basis it should start to fall in place quite quickly. Some of the problems would perhaps need easier with more math-knowledge; fairly comfortable with algebra, differentiation/integration should get you through with a little help from Google.
Break down the problem in to manageable steps. What information do you need? Assign a variable for each input. Ask the user for their response, add that to the variable named for it. What calculations need to be done? Create variable to hold the answers to those calculations. Output the calculations to the user. Is that helpful?
Going further into what astonecipher said. First you need the outstanding balance, the annual interest rate, and the minimum monthly payment rate. This can be accomplished with raw_input and setting each to a variable. Example: balance = raw_input('What is the outstanding balance: ') interest = raw_input('What is the annual interest rate: ') monthly = raw_input('What is the monthly payment rate: ') Next would be to calculate the minimum monthly payment rate, the principle paid, and the remaining balance. This can be done through loops Make a loop that iterates 12 times one for each month of the year and recalculate the balance, etc. during each iteration Example: for i in range(1,12): print 'Month ' + i ## displays the month balance = balance + balance * interest minimumPayment = balance * monthly print = 'Minimum monthly payment: ' + minimumPayment ## displays the minimum Hopefully this can get you started
Some of my syntax is off in the examples above, but you should be able to get the idea.
NixonInnes - Thanks for taking the time to respond and your words of encouragement, it helped. Endemize - Not sure which problem set you're referring too... I'm on set 1, and dealing with prime numbers. Your reply was insightful though, and I did glean value out of it, so thank you! astonecipher - Thanks for the template, it does help to break things down into simple steps as you've shown.
Join our real-time social learning platform and learn together with your friends!