Explanatory Question
Give output of the following program segment:
double x = 2.9, y = 2.5;
System.out.println(Math.min(Math.floor(x), y));
System.out.println(Math.max(Math.ceil(x), y));
Read the answer carefully and go through the related questions on the right side to improve your understanding of this topic.