Advertisement
Guest User

Untitled

a guest
Oct 27th, 2016
60
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.25 KB | None | 0 0
  1. #include <iostream>
  2. #include <cmath>
  3.  
  4. using namespace std;
  5.  
  6. int main() {
  7.     int h, v;
  8.    
  9.     cin >> h >> v;
  10.    
  11.     v = 180 - (90 + v);
  12.    
  13.     h = (int) ceil(h/sin(v*M_PI/180));
  14.    
  15.     cout << h << endl;
  16.        
  17.     return 0;
  18. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement