Problem1468--等差数列末项计算

1468: 等差数列末项计算

[Creator : ]
Time Limit : 1.000 sec  Memory Limit : 128 MiB

Description

给出一个等差数列的前两项a1,a2,求第n项是多少。

Input

一行,包含三个整数a1,a2,n−100≤a1,a2≤100,0<n≤1000

Output

一个整数,即第n项的值。

Sample Input Copy

1 4 100

Sample Output Copy

298

Source/Category

 一本通