1. Home
  2. Reasoning & Aptitude
  3. Number Series and Coding-Decoding
  4. A function is defined by f(n) = n + (sum of the digits of…

Added 30 Nov -0001

A function is defined by f(n) = n + (sum of the digits of n). What is the value of f(f(15))?

  1. 27
  2. 23
  3. 24 Correct answer
  4. 26

Correct answer

C. 24

25 views

MCQSEXAM

Explanation

The rule adds the digit sum to the number itself, and the nested call means it must be applied twice: f(15) = 15 + (1 + 5) = 21, then f(21) = 21 + (2 + 1) = 24. Stopping after the inner step leaves 21, while adding the digit sum of 15 twice produces the trap 27. Numbers reachable this way are called generated numbers, and those that no such rule produces are the self numbers.

Reference

Asked in: NTS, ETEA, ISSB, PPSC

Preparing for an exam?

Doubts & discussion

Not sure why the answer is C? Ask here and get an explanation.

Ask a doubt about this MCQ

Shown after review. No links please.

More Number Series and Coding-Decoding MCQs

Practise all Number Series and Coding-Decoding MCQs

Similar MCQs