Advertisements
Advertisements
प्रश्न
Given: double k = Math.rint(−9.4) + Math.sqrt(9.0);
पर्याय
−5.0
−6.0
−6.4
−5.4
MCQ
उत्तर
−6.0
Explanation:
Math.rint(−9.4) will return −9.0, which is the nearest integer to −9.4. Math.sqrt(9.0) yields 3.0. Therefore, the expression is solved as follows:
k = Math.rint(−9.4) + Math.sqrt(9.0);
k = −9.0 + 3.0
k = −6.0
shaalaa.com
या प्रश्नात किंवा उत्तरात काही त्रुटी आहे का?