10754 - Fantastic Sequence

All about problems in Volume 107. If there is a thread about your problem, please use it. If not, create one with its number in the subject.

Moderator: Board moderators

Experienced poster
Posts: 147
Joined: Mon Jun 07, 2010 11:43 am
Location: University Of Dhaka,Bangladesh

Re: 10754 - Fantastic Sequence

Post by Shafaet_du » Wed Jul 06, 2011 10:49 pm

Nice problem (it was a tougher one for me).

I used this mod function for handling negative numbers:

Code: Select all

i64 mod(i64 a,i64 m)
	if(a>0) return a%m;
	if(a==0) return 0;
	i64 M=a%m;
	if(M==0) return 0;
	return m-M;

New poster
Posts: 48
Joined: Sun Jun 22, 2014 6:14 am

Re: 10754 - Fantastic Sequence

Post by red_apricot » Mon Jan 11, 2016 5:20 am

I do so wonder whether the formula in the problem statement is wrong? Should it be a_n = \sum_{i=1}^{k}c_i\times{a_{n-i}}+c_{k+1}\times(n\geq k)?

Post Reply

Return to “Volume 107 (10700-10799)”