Question: write A c++ programme Task 2 (45 pts] A quadratic series is generated using the following equation In = an+ bn + c where in
![write A c++ programme Task 2 (45 pts] A quadratic series](https://s3.amazonaws.com/si.experts.images/answers/2024/09/66df1f94945f9_64366df1f93dd4e9.jpg)
write A c++ programme
Task 2 (45 pts] A quadratic series is generated using the following equation In = an+ bn + c where in represents the nth term in the series and a, b and care fixed for a given series. For example if a = 1, b = 2 and c = 3 the series generated would be 3.6.11, 18, 27, 38.... Write a program that does the following: reads in four numbers, a, b, c and N from a file named input2.txt see the format shown in the example below). determines the sum of the first N (using N from the file) quadratic terms in the sequence specified by the parameters a, b and c above. The sum must be written to a file named output2.txt. The sum is computed using the following equation ST (2) For example if we read in a = 1, b = 2. c = 3 and N = 5 we would have S= T,= (n? + 2n + 3) = 3 + 6 + 11 +18+27 + 38 = 103 Example 1 Listing 3: input2.txt 1 2 3 5 Listing 4: output2.txt 103
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
