**fig2_12.txt** /* 1*/ void /* 2*/ Pair( const unsigned int N ) /* 3*/ { /* 4*/ int Rel = 0, Tot = 0; /* 5*/ for( int i = 1; i <= N; i++ ) /* 6*/ for( int j = i + 1; j <= N; j++ ) /* 7*/ { /* 8*/ Tot++; /* 9*/ if( Gcd( i, j ) == 1 ) /*10*/ Rel++; /*11*/ } /*12*/ cout << "Fraction of relatively prime pairs is " /*13*/ << double( Rel ) / double( Tot ) << endl; /*14*/ }