Java - Numbers Class-min() Method - Java

Description

The method gives the smaller of the two arguments. The argument can be int, float, long, double.

Syntax

This method has the following variants −

Parameters

Here is the detail of parameters −

  • This method accepts any primitive data type as a parameter.

Return Value

This method returns the smaller of the two arguments.

Example

This will produce the following result −

Output

All rights reserved © 2018 Wisdom IT Services India Pvt. Ltd DMCA.com Protection Status

Java Topics