Gate CS-2015-2 Question Paper With Solutions

Q. 9

If p, q, r, s are distinct integers such that:
f(p, q, r, s) = max (p, q, r, s)
g(p, q, r, s) = min (p, q, r, s)
h(p, q, r, s) = remainder of (p × q) / (r × s)  if (p × q) > (r × s) OR 
                remainder of (r × s) / (p × q) if (r × s) > (p × q)
Also a function fgh (p, q, r, s) =
                f(p, q, r, s) × g(p, q, r, s) × h(p, q, r, s).
Also the same operation are valid with two variable functions 
of the form f(p, q).

What is the value of fg(h(2, 5, 7, 3), 4, 6, 8)?

(A) 6

(B) 7

(C) 8

(D) 9

Answer: (C)

Explanation:

Gate CS-2015-2 Question Paper With Solutions

Learn More:   Gate EC-2016 - 1 Question Paper With Solutions

LEAVE A REPLY

Please enter your comment!
Please enter your name here