Home / Questions / What will be the output of the following program segment? int a[] = {1, 2, 3, 4, 5, 6, 7, 9, 13, 16}; x = Math.pow(a[4], a[2]); y = Math.sqrt(a[6] + a[7]);
Explanatory Question

What will be the output of the following program segment?

int a[] = {1, 2, 3, 4, 5, 6, 7, 9, 13, 16};

x = Math.pow(a[4], a[2]);


y = Math.sqrt(a[6] + a[7]);

👁 78 Views
📘 Detailed Answer
🕒 Easy to Read
Read the answer carefully and go through the related questions on the right side to improve your understanding of this topic.

Answer with Explanation


Values of x and y:
x=125.0
y=4.0