-->
当前位置:首页 > 题库

PROGRAMMING:Calculation of the last term of arithmetic sequence

Luz5年前 (2021-05-10)题库388
###Task description
Given the first two terms A1, A2 of an arithmetic sequence, find the number of the nth term.
###Input format:
One line, containing three integers A1, A2, n- 100 <= a1,a2 <= 100,0 < n <= 1000。
###Output format:
An integer, the value of the nth term.
###Input example:
```in
1 4 100
```
###Output example:
```out
two hundred and ninety-eight
```
###Tips
Note: this topic is selected from openjudge website http://noi.openjudge.cn/ch0103/18/ .







answer:If there is no answer, please comment