You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
canIBuy(vehicle:"2020 Indian FTR 1200", price:12_500, monthlyBudget:200),
"I'll have to be frugal if I want a 2020 Indian FTR 1200")
But the instructions say:
The function should return the following message based on the following conditions:
If the price of the vehicle is less than or equal to the monthly budget, return the message "Yes! I'm getting a <vehicle>".
If the price of the vehicle is 10% above your monthly budget, return the message "I'll have to be frugal if I want a <vehicle>".
If the price of the vehicle is more than 10% above your monthly budget, return the message "Darn! No <vehicle> for me".
516.32 is more than 10% above the monthly budget (100), so it shouldn't say yes. Likewise, 12,500 is quite a bit more than 10% over the monthly budget of 200, so it shouldn't say you have to be frugal.
The text was updated successfully, but these errors were encountered:
Going over the conditionals exercise (vehicle-purchase), it has these two tests:
swift/exercises/concept/vehicle-purchase/Tests/VehiclePurchaseTests/VehiclePurchaseTests.swift
Lines 9 to 11 in 4dea7e2
swift/exercises/concept/vehicle-purchase/Tests/VehiclePurchaseTests/VehiclePurchaseTests.swift
Lines 23 to 25 in 4dea7e2
But the instructions say:
516.32 is more than 10% above the monthly budget (100), so it shouldn't say yes. Likewise, 12,500 is quite a bit more than 10% over the monthly budget of 200, so it shouldn't say you have to be frugal.
The text was updated successfully, but these errors were encountered: