File tree Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change 4
4
// - Functions
5
5
6
6
// Mary is buying apples. One apple usually costs 2 dollars, but if you buy
7
- // 40 or more at once, each apple only costs 1! Write a function that calculates
7
+ // more than 40 at once, each apple only costs 1! Write a function that calculates
8
8
// the price of an order of apples given the order amount. No hints this time!
9
9
10
10
// Put your function here!
13
13
// Don't modify this function!
14
14
#[ test]
15
15
fn verify_test ( ) {
16
- let price1 = calculate_price ( 55 ) ;
17
- let price2 = calculate_price ( 40 ) ;
16
+ let price1 = calculate_apple_price ( 35 ) ;
17
+ let price2 = calculate_apple_price ( 65 ) ;
18
18
19
- assert_eq ! ( 55 , price1) ;
20
- assert_eq ! ( 80 , price2) ;
19
+ assert_eq ! ( 70 , price1) ;
20
+ assert_eq ! ( 65 , price2) ;
21
21
}
You can’t perform that action at this time.
0 commit comments