Fonction round() WMLScript

La fonction round() arrondit un nombre à l'entier le plus proche.

Syntaxe

n = Float.round(x)
Composant Description
n L'entier retourné par cette fonction.
x Numérique.

Exemple

var a = Float.round(3.5);
var b = Float.round(3.4);

Résultat

a = 4
b = 3