#include <bits/stdc++.h>
using namespace std;
const int maxn = 1e6;
const int INF = 1e9;
const long long linf = 0x3f3f3f3f3f3f3f3f;
const double PI = acos(-1.0);
long long mod = 1e9 + 7;
int main() {
  int n, a;
  cin >> n >> a;
  cout << 2 << " " << 1 << " " << max(3, min(n, ((n * a + 90) / 180 + 2)))
       << endl;
}
