Legacy Documentation: Version 4.6(go to latest)
Language: English
  • C#
  • JS
  • Boo

Script language

Select your preferred scripting language. All code snippets will be displayed in this language.

Mathf.Min

public static function Min(a: float, b: float): float;
public static function Min(params values: float[]): float;

Description

Returns the smallest of two or more values.

	// prints 1.2
	print(Mathf.Min(1.2, 2.4));
public static function Min(a: int, b: int): int;
public static function Min(params values: int[]): int;

Description

Returns the smallest of two or more values.

	// prints 1
	print(Mathf.Min(1, 2));