+ 1
Please solve this problem in c++ language...
5 Respuestas
+ 1
Please solve...
#include <iostream>
using namespace std;
int main() {
int houses;
cin>>houses;
//your code goes here
float t;
t=((2.0/houses)*100.0);
float i= (t+0.50);
cout<<(int)i;
return 0;
}
+ 1
To round up the result. Use ceil function included in <cmath>. To access <cmath>, use #include <cmath>.
Then you can do cout << ceil(t); and t will be round up.
+ 1
Thank you....carrieforle
0
We help you debug, not code it for you. Please provide your attempt.
0
Nope. BTW, you've got your answers, so I hope you can mark it as best answer to let others know you got it and delete this duplicate question linked below because many members are not pleased to see duplicate questions.
This post can still be remained. Just delete the duplicate one.
https://www.sololearn.com/discuss/2627220/?ref=app