Example 1 if your balance is 1000 then your function

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: > max_trans2(126, 238, 326, 413, 515) [should return 413] >>> max_trans2(222, 110, 411, 54, 73) [should return 110] >>> max_trans2(227, 337, 135, 56, 73) [should return 135] (1) (CS Circles) (5 pts.) A credit card company computes a customer's "minimum payment" according to the following rule. The minimum payment is equal to either $10 or 2.1% of the customer's balance (.021 * balance), whichever is greater; but if this exceeds the balance, then the minimum payment is the balance. Write a function, minimum_payment, to return the minimum payment using min and max. Balance should be an input (parameter) to your function. Test your function on the following input values. Example 1: if your balance is 1000, then your function should return 21.0. Example 2: if your balance is 600, then your function should return 12.6. Example 3: if your bala...
View Full Document

This note was uploaded on 02/12/2014 for the course CIS 122 taught by Professor Staff during the Spring '08 term at University of Oregon.

Ask a homework question - tutors are online