In PHP 8, an empty string is less than any number, an English letter is always bigger than any number.
More interesting are the punctuation marks and non-word characters, some bigger than numbers, some smaller than numbers
$string = '`~!@#$%^&*()-_=+[]{};:\'"\\|,.<>/?';
$number = 999999999999;
$str_len = strlen($string);
$bigger = $smaller = $equal = [];
for ( $i = 0; $i < $str_len; ++$i ) {
if ( $string[$i] > $number ) {
$bigger[] = $string[$i];
} elseif ( $string[$i] < $number ) {
$smaller[] = $string[$i];
} else {
$equal[] = $string[$i];
}
}
var_dump( $bigger ); //['`', '~', '@', '^', '_', '=', '[', ']', '{', '}', ';', ':', '\', '|', '<', '>', '?']
var_dump( $smaller); //['!', '#', '$', '%', '&', '*', '(', ')', '-', '+', ''', '"', ',', '.', '/']
var_dump( $equal); //[]