+ 2
Help please!!! Tests 3 and 4 failed
#include <iostream> using namespace std; int main() { int cost; int paint; cin>>paint; cost=(paint*5+40)+((paint*5+40)/10); cout<<cost; return 0; }
4 odpowiedzi
+ 1
Thank
+ 1
// Paint costs in c++
#include <iostream>
#include <cmath>
using namespace std;
int main() {
int numberOfcolor,total_cost;
double cost,tax;
cin>>numberOfcolor;
cost=(numberOfcolor*5)+40;
tax=cost/10;
total_cost=round(tax)+cost;
cout<<total_cost;
}
0