What value would the following function return for the input x=95 ? function…

1998

What value would the following function return for the input x=95 ?

function fun (x:integer):integer;

Begin

  If x >100 then fun = x-10

  Else fun = fun(fun( x+11))

End;

  1. A.

    89

  2. B.

    90

  3. C.

    91

  4. D.

    92

Attempted by 18 students.

Show answer & explanation

Correct answer: C

image.png

Explore the full course: Gate Guidance By Sanchit Sir