pranjal1805

Untitled

Apr 2nd, 2021
152
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.40 KB | None | 0 0
  1. #include <bits/stdc++.h>
  2. using namespace std;
  3.  
  4. float f(float x)
  5. {
  6.     float a=(int)(x*100+0.5);
  7.     return (float)a / 100;
  8. }
  9.  
  10.  
  11. int main() {
  12.     // your code goes here
  13.     int t;
  14.     cin>>t;
  15.  
  16.     while(t--){
  17.     float k1,k2,k3,v;
  18.     cin>>k1>>k2>>k3>>v;
  19.     v*=k1;
  20.     v*=k2;
  21.     v*=k3;
  22.     v= 100/v;
  23.    
  24.     float y=f(v);
  25.     int c=y*100;
  26.    
  27.    
  28.  
  29.     if(c<958){
  30.         cout<<"YES\n";
  31.     }
  32.     else{
  33.         cout<<"NO\n";
  34.     }
  35. }
  36.     return 0;  
  37. }
  38.  
Advertisement
Add Comment
Please, Sign In to add comment