Int Data Type

Holds signed integer values sure to be a minimum of 32 bits (4 bytes) and gives good performance. On 32-bit platforms, values are in the range −2,147,483,648 – +2,147,483,647.

Instructions

Int is short for “integer”.

Default value
If you declare a variable of type Int and do not initialize it,, then its default value is zero (0).
Automatic conversions
Int widens to Int64, Int128, Real32, Real64, Real, or Real128 without risk of overflow.
Type characters
If you add the character “%” to the end of a variable name, then the variable has the type Int.

Shared methods and properties

Int.Default As Int
Returns the default value, 0.
Int.Max As Int
Returns the maximum positive value.
Int.Min As Int
Returns the minimum negative value.
Int.Parse(str As String, Optional #format As Format) As Int
Tries to parse a string that shows as an integer.
If #format is not given or is #Null, then it tries to parse str as a decimal (base-10) integer. Or you can make it clear with Format.Base10.
Int.Size As Int
Returns the number of available bytes. Typical values are 4 or 8.

Examples

Dim foo As Int
Dim bar%

See also