Junior — Middle
Can you explain what the Integer data type is in PHP?
sobes.tech AI
Answer from AI
In PHP, the Integer data type represents a whole number without a fractional part. It can be either positive or negative, including zero. The size and range of integer values depend on the platform (usually 32-bit or 64-bit). For example:
$number = 42; // integer type
$negative = -15;
Integer is used to store numeric values without decimal points and supports arithmetic operations.