编程介的小学生 2017-03-06 14:54 采纳率: 20.5%
浏览 962
已采纳

Being a Predictor

问题描述 :

Let A(x) = Sigma(Ai * x^i) (0<=i<=N-1). Given A(1), A(2),…, A(N), You are asked to calculate A(N+1) mod 112233.
It is guaranteed that A(1), A(2), …, A(N), A(N+1) are all integers.
输入:

There are multiple test cases, ended with an EOF.
For each case:
Line 1 contains a positive integer N (N <= 10^6).
Line 2 to Line N+1: each contains a non-negative integer less than 65536. The integer in Line i is A(i-1).
输出:

There are multiple test cases, ended with an EOF.
For each case:
Line 1 contains a positive integer N (N <= 10^6).
Line 2 to Line N+1: each contains a non-negative integer less than 65536. The integer in Line i is A(i-1).
样例输入:

1
18605
5
19543
19998
12266
27854
2103
样例输出:

18605
110887

  • 写回答

2条回答 默认 最新

  • threenewbee 2017-03-12 23:59
    关注
    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论
查看更多回答(1条)

报告相同问题?

悬赏问题

  • ¥15 这是哪个作者做的宝宝起名网站
  • ¥60 版本过低apk如何修改可以兼容新的安卓系统
  • ¥25 由IPR导致的DRIVER_POWER_STATE_FAILURE蓝屏
  • ¥50 有数据,怎么建立模型求影响全要素生产率的因素
  • ¥50 有数据,怎么用matlab求全要素生产率
  • ¥15 TI的insta-spin例程
  • ¥15 完成下列问题完成下列问题
  • ¥15 C#算法问题, 不知道怎么处理这个数据的转换
  • ¥15 YoloV5 第三方库的版本对照问题
  • ¥15 请完成下列相关问题!