Menu
Question Index
...

What will be the output of the following program?

public class FindMin {
    public static void main(String[] args) {
        int x = 10;
        int y = 20;
        double z = 19.5;
        System.out.print(Math.min(x, z) + " " + Math.min(y, z));
    }
}


10 19
10 19.5
10.0 19.5
Compilation Error
Runtime Error

Doubts

Problems

Topic: Java Math Class - java.lang.Math

Read this topic
Take test on this topic

0
Wrong
Score more than 2 points

© meritcampus 2019

All Rights Reserved.

Open In App