Questo sito non è ne attivo ne aggiornato, specialmente la pagina del download รจ ferma a 5 vesioni fa , utilizzate il sito in inglese finchè questo sito non sarà annunciato ufficialmente

Reference   Language (extended) | Libraries | Comparison | Board

max(x, y)

Description

Calculates the maximum of two numbers.

Parameters

x: the first number, any data type

y: the second number, any data type

Returns

The larger of the two parameter values.

Example

sensVal = max(senVal, 20); // assigns sensVal to the larger of sensVal or 20
                           // (effectively ensuring that it is at least 20)

Note

Perhaps counter-intuitively, max() is often used to constrain the lower end of a variable's range, while min() is used to constrain the upper end of the range.

See also

Torna alla pagina principale

Puoi postare correzioni, suggerimenti, e nuova documentazione nel Forum.

I contenuti della guida di riferimento sono distribiuti con licenza Creative Commons Attribution-ShareAlike 3.0 License. Gli esempi di codice nella guida di riferimento sono di pubblico dominio.