fork download
  1. #include <iostream>
  2. #include <cmath>
  3. #include <iomanip>
  4. using namespace std;
  5.  
  6. int main() {
  7. int S;
  8. double V;
  9. double g = 10;
  10. double R;
  11.  
  12. cin >> S;
  13. cin >> V;
  14.  
  15. R = (V * V * sin(2 * S * 3.141592653589793 / 180)) / g;
  16.  
  17. cout << fixed << setprecision(1) << R << endl;
  18.  
  19. return 0;
  20. }
Success #stdin #stdout 0s 544KB
stdin
37
10
stdout
9.6