Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
86835 殷老师 22第n项的数 Python3 Wrong Answer 32 MS 3784 KB 268 2024-07-28 13:58:20

Tests(1/5):


Code:

n = int(input()) list1 = list(map(int, input().split())) a, b, c, d = list1[0],list1[1],list1[2],list1[3] if b - a == c - b and d - c == c - b: d = b - a print(a + (n - 1)* d ) if b / a == c / b and d / c == c / b: q = b / a print(a * q**(n-1))


Run Info:

------Input------
5 1 2 4 8
------Answer-----
16
------Your output-----
16.0