The sum of the ages of 5 children born at the interval of 3 years each is 50 years. What is the age of the youngest child?
Answer: 4 years.
Explanation: Let the ages of the children be x, (x + 3), (x + 6), (x + 9) and (x + 12)years. Then, x + (x + 3) + (x + 6) + (x + 9) + (x + 12) = 50 =>5x = 20 =>x = 4. Therefore, Age of the youngest child = x = 4 years.
A copper sphere of diameter 9 cm is melted and drawn into a wire of 2 mm diameter. The length of the wire is???
Answer: 1093.5 mm or 1.1m (approx) Explanation: Volume of Sphere = Volume of wire(cylinder)
4(pi*R^3)/3 = pi*r^2*h
R=4.5 & r=1mm
h=1093.5 mm or 1.1m(approx)
main()
{
static int var = 5;
printf("%d ",var--);
if(var)
main();
}
Answer: 5 4 3 2 1 Explanation: When static storage class is given, it is initialized once. The change in the value of a static variable is retained even between the function calls. Main is also treated like any other ordinary function, which can be called recursively.
A man is three times as old as his son. Five years later he will be two and a half times as old as his son.What's the man's age?
Answer: Age of the man = 45 Explanation: Let the age of son & father be x & 3x. After 5 yrs
son=x+5
father=3x+5
Also given,
2.5(x+5)=3x+5,
solving gives x=15.
fathers age=3x=45
Rohit was 4 times as old as his son 8 years ago. After 8 years, Rohit will be twice as old as his son. What are their present ages?
Answer: Son's present age = 16 years Rohit's present age = 40 years
Explanation: Let son's age 8 years ago be x years. Then, Rohit's age 8 years ago = 4x years. Son's age after 8 years = (x+8)+8 = (x+16) years. Rohit's age after 8 years = (4x+8)+8 = (4x+16) years. 2(x+16) = (4x+16) <=> 2x = 16 <=> x = 8. Hence, son's present age = (x+8) = 16 years. Rohit's present age = (4x+8) = 40 years.