- Trending Categories
- Data Structure
- Networking
- RDBMS
- Operating System
- Java
- iOS
- HTML
- CSS
- Android
- Python
- C Programming
- C++
- C#
- MongoDB
- MySQL
- Javascript
- PHP

- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who

In this problem, we are given a number N. Our task is to create a Program to find N-th term of series 3 , 5 , 21 , 51 , 95 , … in C++.

**Problem Description** − To find the Nth terms of the series −

3, 5, 21, 51, 95, 153, … N-Terms

We need to find the general formula of the series, which is a quadratic equation (based increase in the series).

**Input** − N = 6

**Output** − 153

To solve the problem, we will find the general formula for the nth term of the series which is given by −

**T _{n} = 7*(n^2) - 19*n + 15**

#include <iostream> using namespace std; int findNTerm(int N) { int nthTerm = ( (7*(N*N)) - (19*N) + 15 ); return nthTerm; } int main() { int N = 7; cout<<N<<"th term of the series is "<<findNTerm(N); return 0; }

7th term of the series is 225

- Related Questions & Answers
- C++ program to find n-th term of series 3, 9, 21, 41, 71…
- C++ program to find n-th term of series 1, 3, 6, 10, 15, 21…
- Program to find N-th term of series 3, 5, 33, 35, 53… in C++
- Program to find N-th term of series 7, 21, 49, 91, 147, 217, …… in C++
- Program to find N-th term of series 1, 2, 11, 12, 21… in C++
- Program to find N-th term of series 3, 6, 18, 24, … in C++
- Program to find N-th term of series 2, 4, 3, 4, 15… in C++
- Program to find N-th term of series 3, 12, 29, 54, 87, … in C++
- Program to find N-th term of series 0, 2,1, 3, 1, 5, 2, 7, 3...in C++
- Program to find N-th term of series 0, 11, 28, 51, 79, 115, 156, 203, …In C++
- Program to find N-th term of series 3, 12, 29, 54, 86, 128, 177, 234, ….. in C++
- C++ program to find n-th term in the series 7, 15, 32, …
- C++ program to find n-th term in the series 9, 33, 73,129 …
- C++ program to find n-th term of series 2, 10, 30, 68, 130 …
- n-th term of series 1, 17, 98, 354…… in C++

Advertisements