TCS
Company
In a sequence of integers,A(n)=A(n-1)-A(n-2) where A(n) is the nth term in the sequence,n is an integer and n>=3,A(1)=1,A(2)=1,calculate S(1000) where S(1000) is the sum of first 1000 words?
options are 2,3 ,4 and 0.
Read Solution (Total 1)
-
- series looks like
1,1,0,-1,-1,0,1,1,0,-1,-1,0,0....
for every six terms sum will be zero and sequence repeats for every six terms.
s(1000)=?
1000/6 remainder=4
last 4 terms must be 1,1,0,-1
sum becomes the sum of last 4 terms=1
but option is not there
- 11 years agoHelpfull: Yes(2) No(4)
TCS Other Question