编程介的小学生 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条)

报告相同问题?

悬赏问题

  • ¥20 西门子S7-Graph,S7-300,梯形图
  • ¥50 用易语言http 访问不了网页
  • ¥50 safari浏览器fetch提交数据后数据丢失问题
  • ¥15 matlab不知道怎么改,求解答!!
  • ¥15 永磁直线电机的电流环pi调不出来
  • ¥15 用stata实现聚类的代码
  • ¥15 请问paddlehub能支持移动端开发吗?在Android studio上该如何部署?
  • ¥20 docker里部署springboot项目,访问不到扬声器
  • ¥15 netty整合springboot之后自动重连失效
  • ¥15 悬赏!微信开发者工具报错,求帮改