TCS Ninja aptitude Questions - 7

1. Dinalal divides his property among his four sons after donating Rs.20,000 and 10% of his remaining property. The amounts received by the last three sons are in arithmetic progression and the amount received by the fourth son is equal to the total amount donated. The first son receives as his share RS.20,000 more than the share of the second son. The last son received RS.1 lakh less than the eldest son. 10. Find the share of the third son. 
a) Rs.80,000
b) Rs.1,00,000
c) Rs.1,20,000 
d) Rs.1,50,000
Ans: Assume the amounts received by the 2nd, 3rd, and 4th sons are a+d, a, a-d (as they are in AP)
Now Eldest son received Rs.20,000 more than the 2nd son.  So He gets a+d+20,000
Last son received 1 lakh less than the eldest son. So (a+d+20,000) - (a-d) = 1,00,000 $ \Rightarrow $ 2d = 80,000 $ \Rightarrow $ d = 40,000
So Amounts received by the 4 sons are a + 60,000, a+40,000, a, a - 40,000.
Assume His property = K rupees.
It was given that the youngest son's share is equal to 20,000 + $\displaystyle\frac{1}{{10}}\left( {K - 20,000} \right)$
Then 20,000 +  $\displaystyle\frac{1}{{10}}\left( {K - 20,000} \right)$ = a - 40,000  ...........(1)
and the Remaining property = Sum of the properties received by all the four son's together.
Remaining property = $\displaystyle\frac{9}{{10}}$(K-20,000)
$ \Rightarrow \displaystyle\frac{9}{{10}}$(K-20,000) = ( a + 60,000 ) + (a+40,000) + a +( a - 40,000) ..(2)
Solving We get K = 40,000 and a = 1,20,000
So third son got Rs.1,20,000

In a quadratic equation, (whose coefficients are not necessarily real) the constant term is not 0. The cube of the sum of the squares of its roots is equal to the square of the sum of the cubes of its roots. Which of the following is true?
a)Both roots are real 
b) Neither of the roots is real 
c) At least one root is non-real 
d)At least one root is real
Ans:  Assume the given quadratic equation is $a{x^2} + bx + c = 0$ whose roots are p, q.
Now given that ${\left( {{\alpha ^2} + {\beta ^2}} \right)^3} = {\left( {{\alpha ^3} + {\beta ^3}} \right)^2}$
By expanding we get, ${\alpha ^6} + 3.{\alpha ^4}.{\beta ^2} + 3.{\alpha ^2}.{\beta ^4} + {\beta ^6} = {\alpha ^6} + {\beta ^6} + 2.{\alpha ^3}.{\beta ^3}$
$3.{\alpha ^2}.{\beta ^2}({\alpha ^2} + {\beta ^2}) = 2.{\alpha ^3}.{\beta ^3}$
$3.({\alpha ^2} + {\beta ^2}) = 2.\alpha .\beta $
$3.({\alpha ^2} + {\beta ^2}) + 6.\alpha .\beta  - 6.\alpha .\beta  = 2.\alpha .\beta $
$3.{\left( {\alpha  + \beta } \right)^2} = 8.\alpha .\beta $ ...(1)
We know that sum of the roots = $\alpha  + \beta  = \displaystyle\frac{{ - b}}{a}$
product of the roots = $\alpha .\beta  = \displaystyle\frac{c}{a}$
Substituting in the equation (1) we get $3.{\left( {\displaystyle\frac{{ - b}}{a}} \right)^2} = 8.\displaystyle\frac{c}{a} \Rightarrow 3.{b^2} = 8.a.c$
The nature of the roots can be determined by finding the magnitude of the determinant = ${b^2} - 4ac$
But we know that ac = $\displaystyle\frac{{3{b^2}}}{8}$
So ${b^2} - 4ac$ = ${b^2} - 4.\displaystyle\frac{{3{b^2}}}{8} =  - \frac{{{b^8}}}{8} < 0$
So the roots are imaginary.

3. A man sold 12 candies in $10 had loss of b% then again sold 12 candies at \$12 had profit of b% find the value of b.
Ans: Here 12 candies is immaterial.
Loss % = $\displaystyle\frac{{CP - SP}}{{CP}} \times 100$
So Here SP = 10 and loss% = b%
$\displaystyle\frac{{CP - 10}}{{CP}} \times 100 = b \Rightarrow \frac{{CP - 10}}{{CP}} = \frac{b}{{100}}$
In the second case he got a profit of b%
So Profit % = $\displaystyle\frac{{SP - CP}}{{CP}} \times 100$
So Here SP = 12 and profit% = b%
$\displaystyle\frac{{12 - CP}}{{CP}} \times 100 = b \Rightarrow \frac{{12 - CP}}{{CP}} = \frac{b}{{100}}$
Solving 1 and 2 we get b = 1/11 or 9.09%

4. find the total number of combinations of 5 letters a,b,a,b,b taking some or all at a time?
Ans: 1 letter can be chosen in 2 ways. a or b
2 letters can be chosen in 3 way. aa, ab, bb
3 letters can be chosen in 3 ways. bbb, aab, bba
4 letters can be chosen in 2 ways. aabb, bbba
5 letters can be chosen in 1 way.
So total ways are 11

5. what is the sum of all the 4 digit numbers that can be formed using all of the digits 2,3,5 and 7?
Ans: use formula (n-1)! x (111..n times) x (Sum of the digits)
here n is number of different letters
So answer is  3 ! x 1111 x 17

6. 30^72^87 divided by 11 gives remainder
Ans: Fermat little theorem says, $\displaystyle\frac{{{a^{p - 1}}}}{p}$ remainder is 1.
ie., ${{{30}^{10}}}$  or ${{{8}^{10}}}$when divided by 11 remainder is 1.
The unit digit of ${{{72}^{87}}}$ is 8 (using cyclicity of unit digits) Click here
So ${{{72}^{87}}}$ = 10K + 8
$\displaystyle\frac{{{{30}^{(10K + 8)}}}}{{11}} = \frac{{{{\left( {{{30}^{10}}} \right)}^K}{{.30}^8}}}{{11}} = \frac{{{1^k}{{.30}^8}}}{{11}}$
$\displaystyle\frac{{{8^8}}}{{11}} = \frac{{{2^{24}}}}{{11}} = \frac{{{{\left( {{2^5}} \right)}^4}{{.2}^4}}}{{11}} = \frac{{16}}{{11}} = 5$

7.  1234567891011121314151617181920......424344 what is remainder when divided by 45?
Ans: Let N = 1234567891011121314151617181920......424344
Remainder when N is divided by 5 is 4.  So N = 5K + 4 .....(1)
Remainder when N is divided by 9 is Sum of the digits of N divided by 9. We know that 1+2+3+...44 = 990 Which gives digit sum as 9. So remainder when N is divided by 9 is 0.
So N = 9L .....(2)
Equation (1) and (2) we 9L = 5K + 4
For K = 1 this equation gets satisfied. So least possible number satisfies the condition is 9
So The general format of N = w(LCM of (9, 5)) + Least number satisfies the condition.
So N = w.45 + 9
When N is divided by 45, we get 9 as remainder.