Advertisement
srjchoubey2

associative_num_anal

Aug 27th, 2021
1,715
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.29 KB | None | 0 0
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. int main() {
  5.    
  6.     float a = 1.234;
  7.     float b = 7.896;
  8.     float c = 9.297;
  9.    
  10.     float d = (float)a*b;
  11.     float e = (float)b*c;
  12.  
  13.     if((float)d * c == (float)e * c)
  14.     cout << "Yes";
  15.     else cout << "No";
  16.  
  17.    
  18.     return 0;
  19. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement