Program to find the Nth term of the series 0 , 3 / 1 , 8 / 3 , 15 / 5. . ... ... | C ++ implementation of the approach ; Function to return the nth term of the given series ; nth term ; Driver code
#include <bits/stdc++.h> NEW_LINE using namespace std ; void Nthterm ( int n ) { int numerator = pow ( n , 2 ) - 1 ; int denomenator = 2 * n - 3 ; cout << numerator << " / " << denomenator ; } int main ( ) { int n = 3 ; Nthterm ( n ) ; return 0 ; }