• Post category:Caractères
  • Commentaires de la publication :0 commentaire
  • Dernière modification de la publication :mars 11, 2022
  • Temps de lecture :2 min de lecture

isHexadecimalDigit()

Description :

Analysez si un caractère est un chiffre hexadécimal (AF, 0-9). Renvoie true si thisChar contient un chiffre hexadécimal.

Syntaxe :

isHexadecimalDigit(thisChar)

Paramètres :

thisChar : variable. Types de données autorisés : char .

Retour :

true : si thisChar est un chiffre hexadécimal.

Exemple de code :

if (isHexadecimalDigit(myChar)) { // teste si myChar est un chiffre hexadécimal
Serial.println("Le caractère est un chiffre hexadécimal");
}
else {
Serial.println("Le caractère n'est pas un chiffre hexadécimal");
}

 


 

Source : https://www.arduino.cc/reference/en/language/functions/characters/ishexadecimaldigit/

 

Laisser un commentaire