#include using namespace std; #define rep(i, n) for (int i = 0; i < (int)(n); i++) #define llong long long int main() { int n; cin >> n; string s = "142857"; if(n == 0) { cout << 0 << "\n"; } else { cout << "0."; rep(i, n / 6) cout << s; rep(i, n % 6) cout << s[i]; cout << "\n"; } }