#include <iostream>

using namespace std;

int main() {
    double h;
    cin >> h;
    cout << h * 767 / 256 << '\n' << h / 1024;
    return 0;
}