// Collection of code snippets by Arne Vajhøj 
// (likely posted to comp.os.vms/INFO-VAX, INFO-TPU, MACRO32, eksperten.dk, newz.dk, LinkedIn or other place sometime between 1990 and now) 
#include <iostream>
#include <iomanip>

using namespace std;

int main(int argc, char *argv[])
{
    double x = 123.456789;
    cout << x << " " << x << endl;
    cout << x << " " << setprecision(8) << x << endl;
    cout.precision(9);
    cout << x << " " << x << endl;
    return EXIT_SUCCESS;
}
