Perl supports integers (decimal, octal, hexadecimal), floating point numbers, scientific notation, Booleans, and null.
$year = 2006; # integer
$mode = 0775; # octal number in base 8
$product_price = 29.95; # floating point number in base 10
$favorite_color = 0x33CC99; # integer in base 16 (hexadecimal)
$distance_to_moon=3.844e+5; # floating point in scientific notation
$bits = 0b10110110; # binary number
Related examples in the same category