#include <iostream>
#include <fstream>
using namespace std;
int main()
{
    ifstream f1("snton.inp");
    int n;
    f1>>n;
    f1.close();
    int sa=0,dem=0,sb=0,dem1=0,dem2=0,sc=0;
    float tbca,tbcb,tbcc;
    for(int i=1;i<n;i++){
        if(i%2==0){
            sa=sa+i;
            dem=dem+1;
        }
        tbca=sa/float(dem);
    }
    for(int j=1;j<n;j++){
        if(j%2!=0){
            sb=sb+j;
            dem1=dem1+1;
        }
        tbcb=sb/float(dem1);
    }
    for(int k=1;k<n;k++){
            sc=sc+k;
            dem2=dem2+1;
        tbcc=sc/float(dem2);
    }
    ofstream f2("snton.out");
    f2.setf(ios::fixed);
    f2.setf(ios::showpoint);
    f2.precision(2);
    f2<<sa<<" "<<tbca<<endl;
    f2<<sb<<" "<<tbcb<<endl;
    f2<<sc<<" "<<tbcc;
    f2.close();
    return 0;
}
