fork download
  1. #include <iostream>
  2. #include<bits/stdc++.h>
  3. using namespace std;
  4.  
  5. int main() {
  6. // your code goes here
  7. int a =56;
  8. int b=5;
  9. int c=3;
  10. int d =6;
  11. float ans=0;
  12. ans = log2(a) - log2(b);
  13. cout<<ans<<endl;
  14. float ad =log2(c) - log2(d);
  15.  
  16. cout<<ad;
  17.  
  18.  
  19. return 0;
  20. }
Success #stdin #stdout 0.01s 5500KB
stdin
Standard input is empty
stdout
3.48543
-1