0

How do I write a JAVA code to find the nth term of an Arithmetic Progression series?

How do I write a JAVA code to find the nth term of an Arithmetic Progression series which I can input variables a, d and n?

14th Feb 2020, 8:17 PM
Misan Etchie
Misan Etchie - avatar
2 Respostas
+ 1
Just like you write the mathematical expression to solve for any Arithmetic progression series. Put the same formula in code.
14th Feb 2020, 8:41 PM
Avinesh
Avinesh - avatar
0
I don't know if this will help, but I actually created a program in Python for this. You can take a look at the comments and try converting the code to Java. https://code.sololearn.com/cXoAjRBcR0IW/?ref=app
14th Feb 2020, 8:47 PM
Jianmin Chen
Jianmin Chen - avatar