#include <bits/stdc++.h>
using namespace std;
const int nn = 115;
const double PI = 2 * acos(0);
int main() {
  int n;
  double r;
  double ans;
  cin >> n >> r;
  double x = (PI * (180 - (360.0 / n)) / 2.0) / 180.0;
  ans = r * cos(x) / (1 - cos(x));
  printf("%.6f\n", ans);
}
