TCS
Company
f(f(n))+f(n)=2n+3, f(0)=1,
find f(2012)?
Read Solution (Total 3)
-
- n=0
f(f(0)+f(0)=2*0+3
f(1)+1=3
f(1)=2
n=1
f(f(1))+f(1)=2*1+3
f(2)+2=5
f(2)=3
n=2
f(f(2))+f(2)=2*2+3
f(3)+3=7
f(3)=4
similarly
f(2012)=2013 - 12 years agoHelpfull: Yes(37) No(3)
- f (f(0)) + f(0) = 2(0) + 3, f(1) = 3-1 = 2, f(1) = 2
f(f(1)) + f(1) = 2(1) + 3, f(2) = 5-2 = 3, f(2) = 3
f(f(2)) + f(2) = 2(2) + 3, f(3) = 7-3 = 4, f(3) = 4
That is, f(n)=n+1
So, f(2012) = 2013 - 7 years agoHelpfull: Yes(2) No(0)
- f[f(n))+f(n)=2n+3
as they mention f[0]=1,
apply in the question-> f(f(0))+f(0)=2(0)+3
-> f(1)+1=3 (sincef[0]=1)
therfore f[1]=2
similarly f[1] ,
f[f[1]]+f[1]=2(1)+3
f(2)+2=2(1)+3
f(2)=5-2
f(2)=3
like that for every f, one value is increased
f[2012]=2013 - 7 years agoHelpfull: Yes(1) No(0)
TCS Other Question