#include <bits/stdc++.h>
using namespace std;
int main() {
  vector<int> s1;
  s1.push_back(0);
  s1.push_back(1);
  int n, a, b, c;
  bool f1 = 0;
  scanf("%d", &n);
  for (int i = 2; i < 100000; i++) {
    s1.push_back(s1[i - 1] + s1[i - 2]);
  }
  for (int i = 0; i < s1.size(); i++) {
    for (int j = 0; j < s1.size(); j++) {
      for (int k = 0; k < s1.size(); k++) {
        if (s1[i] + s1[j] + s1[k] == n) {
          a = s1[i];
          b = s1[j];
          c = s1[k];
          f1 = 1;
          break;
        }
      }
      if (f1 == 1) {
        break;
      }
    }
    if (f1 == 1) {
      break;
    }
  }
  if (f1 == 1) {
    cout << a << " " << b << " " << c << endl;
  } else {
    printf("I'm too stupid to solve this problem\n");
  }
  return 0;
}
